mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-01-30 22:55:24 +08:00
Import from collections.abc wherever possible (#7635)
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import sys
|
||||
from typing import Any, AnyStr, Callable, Generic, Mapping, NamedTuple, Sequence, overload
|
||||
from collections.abc import Callable, Mapping, Sequence
|
||||
from typing import Any, AnyStr, Generic, NamedTuple, overload
|
||||
from typing_extensions import TypeAlias
|
||||
|
||||
if sys.version_info >= (3, 9):
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import ssl
|
||||
import sys
|
||||
from _typeshed import StrOrBytesPath, SupportsRead
|
||||
from collections.abc import Callable, Iterable, Mapping, MutableMapping, Sequence
|
||||
from email.message import Message
|
||||
from http.client import HTTPMessage, HTTPResponse, _HTTPConnectionProtocol
|
||||
from http.cookiejar import CookieJar
|
||||
from typing import IO, Any, Callable, ClassVar, Iterable, Mapping, MutableMapping, NoReturn, Pattern, Sequence, TypeVar, overload
|
||||
from typing import IO, Any, ClassVar, NoReturn, Pattern, TypeVar, overload
|
||||
from typing_extensions import TypeAlias
|
||||
from urllib.error import HTTPError
|
||||
from urllib.response import addclosehook, addinfourl
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
import sys
|
||||
from _typeshed import Self
|
||||
from collections.abc import Callable, Iterable
|
||||
from email.message import Message
|
||||
from types import TracebackType
|
||||
from typing import IO, Any, BinaryIO, Callable, Iterable
|
||||
from typing import IO, Any, BinaryIO
|
||||
|
||||
__all__ = ["addbase", "addclosehook", "addinfo", "addinfourl"]
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import sys
|
||||
from typing import Iterable, NamedTuple
|
||||
from collections.abc import Iterable
|
||||
from typing import NamedTuple
|
||||
|
||||
__all__ = ["RobotFileParser"]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user