master
Commits on Mar 18, 2022
Commits on Mar 17, 2022
Commits on Mar 16, 2022
-
Add stubs for whatthepatch (#7492)
Co-authored-by: Akuli <akuviljanen17@gmail.com>
-
The issues that broke typeshed's CI have been fixed by jakebailey/pyright-action@e7c2cba
-
pyright: Don't report incompatible overrides (#7498)
These overrides are inherited from the implementation and are out of typeshed's control.
-
-
Use pyright 1.1.230 in CI, temporarily pin pyright-action to 1.0.4 (#…
…7495) * Upgrade pyright to 1.1.230 * Add `type: ignore`s for new pyright checks regarding multiple inheritance * Temporarily pin pyright-action to 1.0.4, as changes made in 1.0.5 break typeshed's CI Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
-
psycopg2: Accept Composable in place of query string (#7494)
https://www.psycopg.org/docs/sql.html#psycopg2.sql.Composable “Composable objects can be passed directly to execute(), executemany(), copy_expert() in place of the query string.” Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Commits on Mar 15, 2022
Commits on Mar 14, 2022
Commits on Mar 13, 2022
-
Further improve
mypy_test.py
(#7484)* Run mypy on the 3.11 stdlib in CI, as a regression test for python/mypy#12220 * Correct the docstring at the top of the file following the changes made in #7478 * Stop the test from crashing when run locally if there's an extra file/folder in the stubs directory.
-
* Fix `mypy_test.py` so that it actually tests the third-party stubs * Upgrade to mypy 0.940 * Skip running mypy on `SQLAlchemy` stubs for now, to workaround a mypy crash. Because we didn't set mypy's clean_exit parameter, it was exiting immediately after checking the stdlib, meaning `mypy_test.py` wasn't checking the third-party stubs at all. Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
-
dict.pop: Remove default for second argument (#7481)
The first overload takes care of the case where there is only one argument, so there should be no default in the second overload.
-
-
parsimonious:
re.Match
does not exist in Python 3.6 (#7482)It has to be imported from `typing` in <3.7. Refs #7478.
-
urllib3: stubs are not Python 2 compatible (#7480)
They use http.client, which is Python 3-only. Another catch from #7478.
-
Commits on Mar 11, 2022
-
Signed-off-by: Andrej Shadura <andrew.shadura@collabora.co.uk>
-
Fix overly precise
typing.NewType
signature (#7474)`type` is incorrect because `NewType` can also accept another `NewType`: https://peps.python.org/pep-0484/#newtype-helper-function The return type was also wrong; pre-3.10 `NewType()` doesn't return a type object.
Commits on Mar 10, 2022
-
Change TemporaryFileWrapper.__exit__ return type to None (#7470)
For context we found this from quora/pyanalyze#496, which makes pyanalyze stricter about context managers that may swallow exceptions. tempfile._TemporaryFileWrapper.__exit__ returns whatever its underlying file returns (https://github.com/python/cpython/blob/3.6/Lib/tempfile.py#L502), and file objects don't tend to return anything from __exit__.
Commits on Mar 9, 2022
-
Modernize syntax in various stubs (#7469)
Use `str` and `contextlib.AbstractContextManager` instead of `typing.Text` and `typing.ContextManager`.
-
-
Remove Python 2 support from some third-party distributions (#7466)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
-
-
Remove ClassVar from SSLContext.ssl{object,socket}_class (#7465)
These attributes have class-level defaults, but the docs explicitly state that it's OK to override them on instances. Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
-