mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-08 04:54:47 +08:00
Upgrade mypy to 0.990 (#9123)
This commit is contained in:
@@ -5,7 +5,7 @@ flake8-bugbear==22.10.27 # must match .pre-commit-config.yaml
|
||||
flake8-noqa==1.2.9 # must match .pre-commit-config.yaml
|
||||
flake8-pyi==22.10.0 # must match .pre-commit-config.yaml
|
||||
isort==5.10.1 # must match .pre-commit-config.yaml
|
||||
mypy==0.982
|
||||
mypy==0.990
|
||||
packaging==21.3
|
||||
pathspec
|
||||
pycln==2.1.1 # must match .pre-commit-config.yaml
|
||||
|
||||
@@ -179,6 +179,7 @@ if sys.version_info >= (3, 9):
|
||||
self, mode: str, buffering: int = ..., encoding: str | None = ..., errors: str | None = ..., newline: str | None = ...
|
||||
) -> IO[Any]: ...
|
||||
@property
|
||||
@abstractmethod
|
||||
def name(self) -> str: ...
|
||||
@abstractmethod
|
||||
def __truediv__(self, child: str) -> Traversable: ...
|
||||
|
||||
@@ -15,7 +15,7 @@ class Waiter:
|
||||
|
||||
|
||||
async def foo() -> int:
|
||||
...
|
||||
return 42
|
||||
|
||||
|
||||
async def main() -> None:
|
||||
|
||||
@@ -16,11 +16,13 @@ _VT = TypeVar("_VT")
|
||||
|
||||
|
||||
class KeysAndGetItem(Generic[_KT, _VT]):
|
||||
data: Dict[_KT, _VT]
|
||||
|
||||
def keys(self) -> Iterable[_KT]:
|
||||
...
|
||||
return self.data.keys()
|
||||
|
||||
def __getitem__(self, __k: _KT) -> _VT:
|
||||
...
|
||||
return self.data[__k]
|
||||
|
||||
|
||||
kt1: KeysAndGetItem[int, str] = KeysAndGetItem()
|
||||
|
||||
@@ -438,6 +438,17 @@ types.WrapperDescriptorType.__get__
|
||||
typing.[A-Z]\w+
|
||||
typing_extensions\..*
|
||||
|
||||
# These are abstract properties at runtime,
|
||||
# but marking them as such in the stub breaks half the the typed-Python ecosystem (see #8726)
|
||||
typing.IO.closed
|
||||
typing.IO.mode
|
||||
typing.IO.name
|
||||
typing.TextIO.buffer
|
||||
typing.TextIO.encoding
|
||||
typing.TextIO.errors
|
||||
typing.TextIO.line_buffering
|
||||
typing.TextIO.newlines
|
||||
|
||||
# Typing-related weirdness
|
||||
_collections_abc.Callable
|
||||
_typeshed.* # Utility types for typeshed, doesn't exist at runtime
|
||||
|
||||
Reference in New Issue
Block a user