Use variable annotations everywhere (#2909)

This commit is contained in:
Michael Lee
2019-04-13 01:40:52 -07:00
committed by Sebastian Rittau
parent b3c76aab49
commit efb67946f8
458 changed files with 9135 additions and 9135 deletions

View File

@@ -9,26 +9,26 @@ import ssl
class HTTPMessage(mimetools.Message):
def addcontinue(self, key: str, more: str) -> None: ...
dict = ... # type: Dict[str, str]
dict: Dict[str, str]
def addheader(self, key: str, value: str) -> None: ...
unixfrom = ... # type: str
headers = ... # type: Any
status = ... # type: str
seekable = ... # type: bool
unixfrom: str
headers: Any
status: str
seekable: bool
def readheaders(self) -> None: ...
class HTTPResponse:
fp = ... # type: Any
debuglevel = ... # type: Any
strict = ... # type: Any
msg = ... # type: Any
version = ... # type: Any
status = ... # type: Any
reason = ... # type: Any
chunked = ... # type: Any
chunk_left = ... # type: Any
length = ... # type: Any
will_close = ... # type: Any
fp: Any
debuglevel: Any
strict: Any
msg: Any
version: Any
status: Any
reason: Any
chunked: Any
chunk_left: Any
length: Any
will_close: Any
def __init__(self, sock, debuglevel: int = ..., strict: int = ..., method: Optional[Any] = ...,
buffering: bool = ...) -> None: ...
def begin(self): ...
@@ -49,14 +49,14 @@ class HTTPConnectionProtocol(Protocol):
def __call__(self, host: str, timeout: int = ..., **http_con_args: Any) -> HTTPConnection: ...
class HTTPConnection:
response_class = ... # type: Any
default_port = ... # type: Any
auto_open = ... # type: Any
debuglevel = ... # type: Any
strict = ... # type: Any
timeout = ... # type: Any
source_address = ... # type: Any
sock = ... # type: Any
response_class: Any
default_port: Any
auto_open: Any
debuglevel: Any
strict: Any
timeout: Any
source_address: Any
sock: Any
host: str = ...
port: int = ...
def __init__(self, host, port: Optional[Any] = ..., strict: Optional[Any] = ..., timeout=...,
@@ -73,28 +73,28 @@ class HTTPConnection:
def getresponse(self, buffering: bool = ...): ...
class HTTP:
debuglevel = ... # type: Any
debuglevel: Any
def __init__(self, host: str = ..., port: Optional[Any] = ..., strict: Optional[Any] = ...) -> None: ...
def connect(self, host: Optional[Any] = ..., port: Optional[Any] = ...): ...
def getfile(self): ...
file = ... # type: Any
headers = ... # type: Any
file: Any
headers: Any
def getreply(self, buffering: bool = ...): ...
def close(self): ...
class HTTPSConnection(HTTPConnection):
default_port = ... # type: Any
key_file = ... # type: Any
cert_file = ... # type: Any
default_port: Any
key_file: Any
cert_file: Any
def __init__(self, host, port: Optional[Any] = ..., key_file: Optional[Any] = ..., cert_file: Optional[Any] = ...,
strict: Optional[Any] = ..., timeout=..., source_address: Optional[Any] = ...,
context: Optional[Any] = ...) -> None: ...
sock = ... # type: Any
sock: Any
def connect(self): ...
class HTTPS(HTTP):
key_file = ... # type: Any
cert_file = ... # type: Any
key_file: Any
cert_file: Any
def __init__(self, host: str = ..., port: Optional[Any] = ..., key_file: Optional[Any] = ..., cert_file: Optional[Any] = ..., strict: Optional[Any] = ..., context: Optional[Any] = ...) -> None: ...
class HTTPException(Exception): ...
@@ -102,17 +102,17 @@ class NotConnected(HTTPException): ...
class InvalidURL(HTTPException): ...
class UnknownProtocol(HTTPException):
args = ... # type: Any
version = ... # type: Any
args: Any
version: Any
def __init__(self, version) -> None: ...
class UnknownTransferEncoding(HTTPException): ...
class UnimplementedFileMode(HTTPException): ...
class IncompleteRead(HTTPException):
args = ... # type: Any
partial = ... # type: Any
expected = ... # type: Any
args: Any
partial: Any
expected: Any
def __init__(self, partial, expected: Optional[Any] = ...) -> None: ...
class ImproperConnectionState(HTTPException): ...
@@ -121,14 +121,14 @@ class CannotSendHeader(ImproperConnectionState): ...
class ResponseNotReady(ImproperConnectionState): ...
class BadStatusLine(HTTPException):
args = ... # type: Any
line = ... # type: Any
args: Any
line: Any
def __init__(self, line) -> None: ...
class LineTooLong(HTTPException):
def __init__(self, line_type) -> None: ...
error = ... # type: Any
error: Any
class LineAndFileWrapper:
def __init__(self, line, file) -> None: ...
@@ -139,67 +139,67 @@ class LineAndFileWrapper:
# Constants
responses = ... # type: Dict[int, str]
responses: Dict[int, str]
HTTP_PORT = ... # type: int
HTTPS_PORT = ... # type: int
HTTP_PORT: int
HTTPS_PORT: int
# status codes
# informational
CONTINUE = ... # type: int
SWITCHING_PROTOCOLS = ... # type: int
PROCESSING = ... # type: int
CONTINUE: int
SWITCHING_PROTOCOLS: int
PROCESSING: int
# successful
OK = ... # type: int
CREATED = ... # type: int
ACCEPTED = ... # type: int
NON_AUTHORITATIVE_INFORMATION = ... # type: int
NO_CONTENT = ... # type: int
RESET_CONTENT = ... # type: int
PARTIAL_CONTENT = ... # type: int
MULTI_STATUS = ... # type: int
IM_USED = ... # type: int
OK: int
CREATED: int
ACCEPTED: int
NON_AUTHORITATIVE_INFORMATION: int
NO_CONTENT: int
RESET_CONTENT: int
PARTIAL_CONTENT: int
MULTI_STATUS: int
IM_USED: int
# redirection
MULTIPLE_CHOICES = ... # type: int
MOVED_PERMANENTLY = ... # type: int
FOUND = ... # type: int
SEE_OTHER = ... # type: int
NOT_MODIFIED = ... # type: int
USE_PROXY = ... # type: int
TEMPORARY_REDIRECT = ... # type: int
MULTIPLE_CHOICES: int
MOVED_PERMANENTLY: int
FOUND: int
SEE_OTHER: int
NOT_MODIFIED: int
USE_PROXY: int
TEMPORARY_REDIRECT: int
# client error
BAD_REQUEST = ... # type: int
UNAUTHORIZED = ... # type: int
PAYMENT_REQUIRED = ... # type: int
FORBIDDEN = ... # type: int
NOT_FOUND = ... # type: int
METHOD_NOT_ALLOWED = ... # type: int
NOT_ACCEPTABLE = ... # type: int
PROXY_AUTHENTICATION_REQUIRED = ... # type: int
REQUEST_TIMEOUT = ... # type: int
CONFLICT = ... # type: int
GONE = ... # type: int
LENGTH_REQUIRED = ... # type: int
PRECONDITION_FAILED = ... # type: int
REQUEST_ENTITY_TOO_LARGE = ... # type: int
REQUEST_URI_TOO_LONG = ... # type: int
UNSUPPORTED_MEDIA_TYPE = ... # type: int
REQUESTED_RANGE_NOT_SATISFIABLE = ... # type: int
EXPECTATION_FAILED = ... # type: int
UNPROCESSABLE_ENTITY = ... # type: int
LOCKED = ... # type: int
FAILED_DEPENDENCY = ... # type: int
UPGRADE_REQUIRED = ... # type: int
BAD_REQUEST: int
UNAUTHORIZED: int
PAYMENT_REQUIRED: int
FORBIDDEN: int
NOT_FOUND: int
METHOD_NOT_ALLOWED: int
NOT_ACCEPTABLE: int
PROXY_AUTHENTICATION_REQUIRED: int
REQUEST_TIMEOUT: int
CONFLICT: int
GONE: int
LENGTH_REQUIRED: int
PRECONDITION_FAILED: int
REQUEST_ENTITY_TOO_LARGE: int
REQUEST_URI_TOO_LONG: int
UNSUPPORTED_MEDIA_TYPE: int
REQUESTED_RANGE_NOT_SATISFIABLE: int
EXPECTATION_FAILED: int
UNPROCESSABLE_ENTITY: int
LOCKED: int
FAILED_DEPENDENCY: int
UPGRADE_REQUIRED: int
# server error
INTERNAL_SERVER_ERROR = ... # type: int
NOT_IMPLEMENTED = ... # type: int
BAD_GATEWAY = ... # type: int
SERVICE_UNAVAILABLE = ... # type: int
GATEWAY_TIMEOUT = ... # type: int
HTTP_VERSION_NOT_SUPPORTED = ... # type: int
INSUFFICIENT_STORAGE = ... # type: int
NOT_EXTENDED = ... # type: int
INTERNAL_SERVER_ERROR: int
NOT_IMPLEMENTED: int
BAD_GATEWAY: int
SERVICE_UNAVAILABLE: int
GATEWAY_TIMEOUT: int
HTTP_VERSION_NOT_SUPPORTED: int
INSUFFICIENT_STORAGE: int
NOT_EXTENDED: int