8000 Re-organize directory structure by ilevkivskyi · Pull Request #4971 · python/typeshed · GitHub
[go: up one dir, main page]

Skip to content

Re-organize directory structure #4971

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 18 commits into from
Jan 27, 2021
Prev Previous commit
Next Next commit
Style tweaks
  • Loading branch information
Ivan Levkivskyi committed Jan 26, 2021
commit 35f27c21150b7c1e8edf6782600348a9f98565a2
8 changes: 5 additions & 3 deletions tests/mypy_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,9 @@ def parse_versions(fname):
data = f.read().splitlines()
result = {}
for line in data:
# Allow having some comments or empty lines.
if not line.strip() or line.startswith("#"):
continue
mod, ver_str = line.split(": ")
assert ver_str.count(".") == 1
major, minor = ver_str.split(".")
Expand All @@ -86,10 +89,9 @@ def is_supported(distribution, major):
data = dict(toml.loads(f.read()))
if major == 2:
# Python 2 is not supported by default.
return bool(data.get("python2"))
supported = data.get("python3")
return bool(data.get("python2", False))
# Python 3 is supported by default.
return supported is None or supported
return bool(data.get("python3", True))


def add_files(files, seen, root, name, args, exclude_list):
Expand Down
0