* sre_parse: NIC is stub implementation detail
* sre_parse: add missing arg to Tokenizer.getuntil
* sre_parse: fix types for parse
* sre_parse: fix types for SubPattern.__init__
* sre_parse: fix arg name for fix_flags
* sre_parse: update whitelists
* sre_parse: fix some availability for py35
* json: mark keyword-only args
Technically only true for Python 3.6+, but I didn't feel like copying
over the whole file just for Python 3.5. Let me know and I can.
* json: remove encoding from loads
This has been ignored and deprecated since 3.1 and will be removed in 3.9
It no longer even shows up in inspect.signature (in 3.8 it emits the
deprecation warning based on kwargs)
* json: update whitelists
* sys: simplify _getframe
* sys: mark positional-only args
* sys: fix platform availability
* sys: remove settscdump
This function is no longer documented in 3.6 and above (and doesn't
exist on master, was removed in 4fd64b9a6aba9e6e1a5d).
In 3.5 documentation it's mentioned that it's only available if Python
was compiled with a special flag:
https://docs.python.org/3.5/library/sys.html#sys.settscdump
* sys: update whitelists
* resource: mark positional-only args
* resource: alias error to OSError
* resource: no longer seems incomplete
At least for Linux and Mac. Might be some things missing for FreeBSD
* resource: fix platform availability
* resource: update whitelist
* README.md: refactor "Running the tests"
This organises the section a little better. Previously some tests were
unmentioned; it read as if mypy_test and pytype_test were the only
tests. The section is now organised by test, making it easy to keep
track of the requirements and details of each. This also makes it
easier to add documentation for stubtest.
Also mention turning on Travis CI on your fork, since that is very
useful.
* README.md: document stubtest_test.py
* stubtest_test: add it
* travis: add stubtest_test to CI
* stubtest_test: add whitelists
This is a small cosmetic change. I want to encourage use of the
nicer-lookng pytype.config.Options.create() rather than
direct construction of the command-line args, so I'm changing
over all occurrences of the latter that I can find.
This runs mypy both with Python 3.7 and 3.8. In Python 3.8,
mypy switched from using typed-ast to using Python's built-in ast.
This patch ensures that both are tested.
This also makes the flask stubs that depend on click parseable.
* In pytype_test, only parse files with the .pyi extension.
(There's a README in third_party/2and3/click/.)
* Annotate with ContextManager rather than using the
contextmanager decorator. This is shorter, removes a
dependency, and gets rid of the slight weirdness of a
decorator needing to be evaluated in a stub.
* Fix non-stub things.
During the PyCon sprints, I'm planning to bash the pytype pyi
parser into shape so we can handle all of third_party. As a first
step, create an explicit blacklist of everything pytype chokes on.
With today's release, pytype is able to fully load
stdlib/3/collections/__init__.pyi, so the test no longer needs the
ability to partially parse stubs using the pytd tool. Removing this
functionality allows the test code to be simplified considerably.
Speeds up pytype considerably by directly calling pytype.io.parse_pyi
rather than running `pytype --parse-pyi` in a subprocess.
The subprocess logic is still required to handle the one pyi file
marked `# parse only` in the pytype blacklist. Once
https://github.com/google/pytype/issues/242 is fixed, the test code
can be cleaned up considerably.
All Python 3 versions supported by typeshed (3.4+) have enum as part
of the standard library.
Make the third-party Python 2 version consistent with the Python 3 version.
* Moves the pytype installation to requirements-tests-py3.txt, now
that pytype can run under Python 3.5+.
* Changes tests/pytype_test.py to not require a --python{version}-exe
argument when it can automatically find the Python interpreter, and
cleans up a few typos and out-of-date things.
* Updates the appropriate documentation.
* Updates .travis.yml.