Big diff: use lower-case list and dict (#5888)

This commit is contained in:
Akuli
2021-08-08 19:26:35 +03:00
committed by GitHub
parent 11f54c3407
commit ce11072dbe
325 changed files with 2196 additions and 2334 deletions

View File

@@ -5,23 +5,7 @@ import sys
import types
from _typeshed import Self, WriteableBuffer
from socket import socket
from typing import (
IO,
Any,
BinaryIO,
Callable,
Dict,
Iterable,
Iterator,
List,
Mapping,
Protocol,
Tuple,
Type,
TypeVar,
Union,
overload,
)
from typing import IO, Any, BinaryIO, Callable, Iterable, Iterator, Mapping, Protocol, Tuple, Type, TypeVar, Union, overload
_DataType = Union[bytes, IO[Any], Iterable[bytes], str]
_T = TypeVar("_T")
@@ -87,7 +71,7 @@ INSUFFICIENT_STORAGE: int
NOT_EXTENDED: int
NETWORK_AUTHENTICATION_REQUIRED: int
responses: Dict[int, str]
responses: dict[int, str]
class HTTPMessage(email.message.Message):
def getallmatchingheaders(self, name: str) -> list[str]: ... # undocumented
@@ -112,7 +96,7 @@ class HTTPResponse(io.BufferedIOBase, BinaryIO):
def getheader(self, name: str) -> str | None: ...
@overload
def getheader(self, name: str, default: _T) -> str | _T: ...
def getheaders(self) -> List[Tuple[str, str]]: ...
def getheaders(self) -> list[Tuple[str, str]]: ...
def fileno(self) -> int: ...
def isclosed(self) -> bool: ...
def __iter__(self) -> Iterator[bytes]: ...