mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-02-05 17:37:41 +08:00
Add missing '-> None' to all __init__ methods.
This commit is contained in:
@@ -14,7 +14,7 @@ REMAINDER = ... # type: Any
|
||||
class _AttributeHolder: ...
|
||||
|
||||
class HelpFormatter:
|
||||
def __init__(self, prog, indent_increment=2, max_help_position=24, width=None): ...
|
||||
def __init__(self, prog, indent_increment=2, max_help_position=24, width=None) -> None: ...
|
||||
def start_section(self, heading): ...
|
||||
def end_section(self): ...
|
||||
def add_text(self, text): ...
|
||||
@@ -31,7 +31,7 @@ class MetavarTypeHelpFormatter(HelpFormatter): ...
|
||||
class ArgumentError(Exception):
|
||||
argument_name = ... # type: Any
|
||||
message = ... # type: Any
|
||||
def __init__(self, argument, message): ...
|
||||
def __init__(self, argument, message) -> None: ...
|
||||
|
||||
class ArgumentTypeError(Exception): ...
|
||||
|
||||
@@ -61,10 +61,10 @@ class _StoreConstAction(Action):
|
||||
def __call__(self, parser, namespace, values, option_string=None): ...
|
||||
|
||||
class _StoreTrueAction(_StoreConstAction):
|
||||
def __init__(self, option_strings, dest, default=False, required=False, help=None): ...
|
||||
def __init__(self, option_strings, dest, default=False, required=False, help=None) -> None: ...
|
||||
|
||||
class _StoreFalseAction(_StoreConstAction):
|
||||
def __init__(self, option_strings, dest, default=True, required=False, help=None): ...
|
||||
def __init__(self, option_strings, dest, default=True, required=False, help=None) -> None: ...
|
||||
|
||||
class _AppendAction(Action):
|
||||
def __init__(self, option_strings, dest, nargs=None, const=None, default=None, type=None,
|
||||
@@ -77,11 +77,11 @@ class _AppendConstAction(Action):
|
||||
def __call__(self, parser, namespace, values, option_string=None): ...
|
||||
|
||||
class _CountAction(Action):
|
||||
def __init__(self, option_strings, dest, default=None, required=False, help=None): ...
|
||||
def __init__(self, option_strings, dest, default=None, required=False, help=None) -> None: ...
|
||||
def __call__(self, parser, namespace, values, option_string=None): ...
|
||||
|
||||
class _HelpAction(Action):
|
||||
def __init__(self, option_strings, dest=..., default=..., help=None): ...
|
||||
def __init__(self, option_strings, dest=..., default=..., help=None) -> None: ...
|
||||
def __call__(self, parser, namespace, values, option_string=None): ...
|
||||
|
||||
class _VersionAction(Action):
|
||||
@@ -97,11 +97,11 @@ class _SubParsersAction(Action):
|
||||
def __call__(self, parser, namespace, values, option_string=None): ...
|
||||
|
||||
class FileType:
|
||||
def __init__(self, mode='', bufsize=-1, encoding=None, errors=None): ...
|
||||
def __init__(self, mode='', bufsize=-1, encoding=None, errors=None) -> None: ...
|
||||
def __call__(self, string): ...
|
||||
|
||||
class Namespace(_AttributeHolder):
|
||||
def __init__(self, **kwargs): ...
|
||||
def __init__(self, **kwargs) -> None: ...
|
||||
def __eq__(self, other): ...
|
||||
def __ne__(self, other): ...
|
||||
def __contains__(self, key): ...
|
||||
@@ -111,7 +111,7 @@ class _ActionsContainer:
|
||||
argument_default = ... # type: Any
|
||||
prefix_chars = ... # type: Any
|
||||
conflict_handler = ... # type: Any
|
||||
def __init__(self, description, prefix_chars, argument_default, conflict_handler): ...
|
||||
def __init__(self, description, prefix_chars, argument_default, conflict_handler) -> None: ...
|
||||
def register(self, registry_name, value, object): ...
|
||||
def set_defaults(self, **kwargs): ...
|
||||
def get_default(self, dest): ...
|
||||
@@ -133,11 +133,11 @@ class _ActionsContainer:
|
||||
|
||||
class _ArgumentGroup(_ActionsContainer):
|
||||
title = ... # type: Any
|
||||
def __init__(self, container, title=None, description=None, **kwargs): ...
|
||||
def __init__(self, container, title=None, description=None, **kwargs) -> None: ...
|
||||
|
||||
class _MutuallyExclusiveGroup(_ArgumentGroup):
|
||||
required = ... # type: Any
|
||||
def __init__(self, container, required=False): ...
|
||||
def __init__(self, container, required=False) -> None: ...
|
||||
|
||||
class ArgumentParser(_AttributeHolder, _ActionsContainer):
|
||||
prog = ... # type: Any
|
||||
|
||||
@@ -27,7 +27,7 @@ class Dialect:
|
||||
skipinitialspace = ... # type: Any
|
||||
lineterminator = ... # type: Any
|
||||
quoting = ... # type: Any
|
||||
def __init__(self): ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class excel(Dialect):
|
||||
delimiter = ... # type: Any
|
||||
@@ -65,13 +65,13 @@ class DictWriter:
|
||||
restval = ... # type: Any
|
||||
extrasaction = ... # type: Any
|
||||
writer = ... # type: Any
|
||||
def __init__(self, f, fieldnames, restval='', extrasaction='', dialect='', *args, **kwds): ...
|
||||
def __init__(self, f, fieldnames, restval='', extrasaction='', dialect='', *args, **kwds) -> None: ...
|
||||
def writeheader(self): ...
|
||||
def writerow(self, rowdict): ...
|
||||
def writerows(self, rowdicts): ...
|
||||
|
||||
class Sniffer:
|
||||
preferred = ... # type: Any
|
||||
def __init__(self): ...
|
||||
def __init__(self) -> None: ...
|
||||
def sniff(self, sample, delimiters=None): ...
|
||||
def has_header(self, sample): ...
|
||||
|
||||
@@ -26,7 +26,7 @@ class _Folded:
|
||||
firstline = ... # type: Any
|
||||
done = ... # type: Any
|
||||
current = ... # type: Any
|
||||
def __init__(self, maxlen, policy): ...
|
||||
def __init__(self, maxlen, policy) -> None: ...
|
||||
def newline(self): ...
|
||||
def finalize(self): ...
|
||||
def append(self, stoken): ...
|
||||
@@ -35,7 +35,7 @@ class _Folded:
|
||||
class TokenList(list):
|
||||
token_type = ... # type: Any
|
||||
defects = ... # type: Any
|
||||
def __init__(self, *args, **kw): ...
|
||||
def __init__(self, *args, **kw) -> None: ...
|
||||
@property
|
||||
def value(self): ...
|
||||
@property
|
||||
|
||||
@@ -19,7 +19,7 @@ class AddrlistClass:
|
||||
phraseends = ... # type: Any
|
||||
field = ... # type: Any
|
||||
commentlist = ... # type: Any
|
||||
def __init__(self, field): ...
|
||||
def __init__(self, field) -> None: ...
|
||||
def gotonext(self): ...
|
||||
def getaddrlist(self): ...
|
||||
def getaddress(self): ...
|
||||
@@ -35,7 +35,7 @@ class AddrlistClass:
|
||||
|
||||
class AddressList(AddrlistClass):
|
||||
addresslist = ... # type: Any
|
||||
def __init__(self, field): ...
|
||||
def __init__(self, field) -> None: ...
|
||||
def __len__(self): ...
|
||||
def __add__(self, other): ...
|
||||
def __iadd__(self, other): ...
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
from typing import Any
|
||||
|
||||
class _PolicyBase:
|
||||
def __init__(self, **kw): ...
|
||||
def __init__(self, **kw) -> None: ...
|
||||
def clone(self, **kw): ...
|
||||
def __setattr__(self, name, value): ...
|
||||
def __add__(self, other): ...
|
||||
|
||||
@@ -15,7 +15,7 @@ class Charset:
|
||||
output_charset = ... # type: Any
|
||||
input_codec = ... # type: Any
|
||||
output_codec = ... # type: Any
|
||||
def __init__(self, input_charset=...): ...
|
||||
def __init__(self, input_charset=...) -> None: ...
|
||||
def __eq__(self, other): ...
|
||||
def __ne__(self, other): ...
|
||||
def get_body_encoding(self): ...
|
||||
|
||||
@@ -7,7 +7,7 @@ from typing import Any
|
||||
class ContentManager:
|
||||
get_handlers = ... # type: Any
|
||||
set_handlers = ... # type: Any
|
||||
def __init__(self): ...
|
||||
def __init__(self) -> None: ...
|
||||
def add_get_handler(self, key, handler): ...
|
||||
def get_content(self, msg, *args, **kw): ...
|
||||
def add_set_handler(self, typekey, handler): ...
|
||||
|
||||
@@ -13,7 +13,7 @@ class CharsetError(MessageError): ...
|
||||
|
||||
class MessageDefect(ValueError):
|
||||
line = ... # type: Any
|
||||
def __init__(self, line=None): ...
|
||||
def __init__(self, line=None) -> None: ...
|
||||
|
||||
class NoBoundaryInMultipartDefect(MessageDefect): ...
|
||||
class StartBoundaryNotFoundDefect(MessageDefect): ...
|
||||
@@ -31,14 +31,14 @@ class InvalidBase64PaddingDefect(MessageDefect): ...
|
||||
class InvalidBase64CharactersDefect(MessageDefect): ...
|
||||
|
||||
class HeaderDefect(MessageDefect):
|
||||
def __init__(self, *args, **kw): ...
|
||||
def __init__(self, *args, **kw) -> None: ...
|
||||
|
||||
class InvalidHeaderDefect(HeaderDefect): ...
|
||||
class HeaderMissingRequiredValue(HeaderDefect): ...
|
||||
|
||||
class NonPrintableDefect(HeaderDefect):
|
||||
non_printables = ... # type: Any
|
||||
def __init__(self, non_printables): ...
|
||||
def __init__(self, non_printables) -> None: ...
|
||||
|
||||
class ObsoleteHeaderDefect(HeaderDefect): ...
|
||||
class NonASCIILocalPartDefect(HeaderDefect): ...
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
from typing import Any
|
||||
|
||||
class BufferedSubFile:
|
||||
def __init__(self): ...
|
||||
def __init__(self) -> None: ...
|
||||
def push_eof_matcher(self, pred): ...
|
||||
def pop_eof_matcher(self): ...
|
||||
def close(self): ...
|
||||
@@ -18,7 +18,7 @@ class BufferedSubFile:
|
||||
|
||||
class FeedParser:
|
||||
policy = ... # type: Any
|
||||
def __init__(self, _factory=None, *, policy=...): ...
|
||||
def __init__(self, _factory=None, *, policy=...) -> None: ...
|
||||
def feed(self, data): ...
|
||||
def close(self): ...
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ from typing import Any
|
||||
class Generator:
|
||||
maxheaderlen = ... # type: Any
|
||||
policy = ... # type: Any
|
||||
def __init__(self, outfp, mangle_from_=True, maxheaderlen=None, *, policy=None): ...
|
||||
def __init__(self, outfp, mangle_from_=True, maxheaderlen=None, *, policy=None) -> None: ...
|
||||
def write(self, s): ...
|
||||
def flatten(self, msg, unixfrom=False, linesep=None): ...
|
||||
def clone(self, fp): ...
|
||||
@@ -16,4 +16,4 @@ class BytesGenerator(Generator):
|
||||
def write(self, s): ...
|
||||
|
||||
class DecodedGenerator(Generator):
|
||||
def __init__(self, outfp, mangle_from_=True, maxheaderlen=78, fmt=None): ...
|
||||
def __init__(self, outfp, mangle_from_=True, maxheaderlen=78, fmt=None) -> None: ...
|
||||
|
||||
@@ -14,13 +14,13 @@ class Header:
|
||||
def encode(self, splitchars='', maxlinelen=None, linesep=''): ...
|
||||
|
||||
class _ValueFormatter:
|
||||
def __init__(self, headerlen, maxlen, continuation_ws, splitchars): ...
|
||||
def __init__(self, headerlen, maxlen, continuation_ws, splitchars) -> None: ...
|
||||
def newline(self): ...
|
||||
def add_transition(self): ...
|
||||
def feed(self, fws, string, charset): ...
|
||||
|
||||
class _Accumulator(list):
|
||||
def __init__(self, initial_size=0): ...
|
||||
def __init__(self, initial_size=0) -> None: ...
|
||||
def push(self, fws, string): ...
|
||||
def pop_from(self, i=0): ...
|
||||
def __len__(self): ...
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
from typing import Any
|
||||
|
||||
class Address:
|
||||
def __init__(self, display_name='', username='', domain='', addr_spec=None): ...
|
||||
def __init__(self, display_name='', username='', domain='', addr_spec=None) -> None: ...
|
||||
@property
|
||||
def display_name(self): ...
|
||||
@property
|
||||
@@ -17,7 +17,7 @@ class Address:
|
||||
def __eq__(self, other): ...
|
||||
|
||||
class Group:
|
||||
def __init__(self, display_name=None, addresses=None): ...
|
||||
def __init__(self, display_name=None, addresses=None) -> None: ...
|
||||
@property
|
||||
def display_name(self): ...
|
||||
@property
|
||||
@@ -127,7 +127,7 @@ class HeaderRegistry:
|
||||
registry = ... # type: Any
|
||||
base_class = ... # type: Any
|
||||
default_class = ... # type: Any
|
||||
def __init__(self, base_class=..., default_class=..., use_default_map=True): ...
|
||||
def __init__(self, base_class=..., default_class=..., use_default_map=True) -> None: ...
|
||||
def map_to_type(self, name, cls): ...
|
||||
def __getitem__(self, name): ...
|
||||
def __call__(self, name, value): ...
|
||||
|
||||
@@ -8,7 +8,7 @@ class Message:
|
||||
policy = ... # type: Any
|
||||
preamble = ... # type: Any
|
||||
defects = ... # type: Any
|
||||
def __init__(self, policy=...): ...
|
||||
def __init__(self, policy=...) -> None: ...
|
||||
def as_string(self, unixfrom=False, maxheaderlen=0, policy=None): ...
|
||||
def __bytes__(self): ...
|
||||
def as_bytes(self, unixfrom=False, policy=None): ...
|
||||
@@ -53,7 +53,7 @@ class Message:
|
||||
def get_charsets(self, failobj=None): ...
|
||||
|
||||
class MIMEPart(Message):
|
||||
def __init__(self, policy=None): ...
|
||||
def __init__(self, policy=None) -> None: ...
|
||||
@property
|
||||
def is_attachment(self): ...
|
||||
def get_body(self, preferencelist=...): ...
|
||||
|
||||
@@ -5,4 +5,4 @@
|
||||
from email.mime.nonmultipart import MIMENonMultipart
|
||||
|
||||
class MIMEApplication(MIMENonMultipart):
|
||||
def __init__(self, _data, _subtype='', _encoder=..., **_params): ...
|
||||
def __init__(self, _data, _subtype='', _encoder=..., **_params) -> None: ...
|
||||
|
||||
@@ -5,4 +5,4 @@
|
||||
from email.mime.nonmultipart import MIMENonMultipart
|
||||
|
||||
class MIMEAudio(MIMENonMultipart):
|
||||
def __init__(self, _audiodata, _subtype=None, _encoder=..., **_params): ...
|
||||
def __init__(self, _audiodata, _subtype=None, _encoder=..., **_params) -> None: ...
|
||||
|
||||
@@ -5,4 +5,4 @@
|
||||
from email import message
|
||||
|
||||
class MIMEBase(message.Message):
|
||||
def __init__(self, _maintype, _subtype, **_params): ...
|
||||
def __init__(self, _maintype, _subtype, **_params) -> None: ...
|
||||
|
||||
@@ -5,4 +5,4 @@
|
||||
from email.mime.nonmultipart import MIMENonMultipart
|
||||
|
||||
class MIMEImage(MIMENonMultipart):
|
||||
def __init__(self, _imagedata, _subtype=None, _encoder=..., **_params): ...
|
||||
def __init__(self, _imagedata, _subtype=None, _encoder=..., **_params) -> None: ...
|
||||
|
||||
@@ -5,4 +5,4 @@
|
||||
from email.mime.nonmultipart import MIMENonMultipart
|
||||
|
||||
class MIMEMessage(MIMENonMultipart):
|
||||
def __init__(self, _msg, _subtype=''): ...
|
||||
def __init__(self, _msg, _subtype='') -> None: ...
|
||||
|
||||
@@ -5,4 +5,4 @@
|
||||
from email.mime.base import MIMEBase
|
||||
|
||||
class MIMEMultipart(MIMEBase):
|
||||
def __init__(self, _subtype='', boundary=None, _subparts=None, **_params): ...
|
||||
def __init__(self, _subtype='', boundary=None, _subparts=None, **_params) -> None: ...
|
||||
|
||||
@@ -5,4 +5,4 @@
|
||||
from email.mime.nonmultipart import MIMENonMultipart
|
||||
|
||||
class MIMEText(MIMENonMultipart):
|
||||
def __init__(self, _text, _subtype='', _charset=None): ...
|
||||
def __init__(self, _text, _subtype='', _charset=None) -> None: ...
|
||||
|
||||
@@ -10,7 +10,7 @@ BytesFeedParser = email.feedparser.BytesFeedParser
|
||||
|
||||
class Parser:
|
||||
policy = ... # type: Any
|
||||
def __init__(self, _class=None, *, policy=...): ...
|
||||
def __init__(self, _class=None, *, policy=...) -> None: ...
|
||||
def parse(self, fp, headersonly=False): ...
|
||||
def parsestr(self, text, headersonly=False): ...
|
||||
|
||||
@@ -20,7 +20,7 @@ class HeaderParser(Parser):
|
||||
|
||||
class BytesParser:
|
||||
parser = ... # type: Any
|
||||
def __init__(self, *args, **kw): ...
|
||||
def __init__(self, *args, **kw) -> None: ...
|
||||
def parse(self, fp, headersonly=False): ...
|
||||
def parsebytes(self, text, headersonly=False): ...
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ class EmailPolicy(Policy):
|
||||
refold_source = ... # type: Any
|
||||
header_factory = ... # type: Any
|
||||
content_manager = ... # type: Any
|
||||
def __init__(self, **kw): ...
|
||||
def __init__(self, **kw) -> None: ...
|
||||
def header_max_count(self, name): ...
|
||||
def header_source_parse(self, sourcelines): ...
|
||||
def header_store_parse(self, name, value): ...
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
from typing import Any
|
||||
|
||||
class NullTranslations:
|
||||
def __init__(self, fp=None): ...
|
||||
def __init__(self, fp=None) -> None: ...
|
||||
def add_fallback(self, fallback): ...
|
||||
def gettext(self, message): ...
|
||||
def lgettext(self, message): ...
|
||||
|
||||
@@ -20,7 +20,7 @@ class HTTPResponse(io.RawIOBase):
|
||||
chunk_left = ... # type: Any
|
||||
length = ... # type: Any
|
||||
will_close = ... # type: Any
|
||||
def __init__(self, sock, debuglevel=0, method=None, url=None): ...
|
||||
def __init__(self, sock, debuglevel=0, method=None, url=None) -> None: ...
|
||||
code = ... # type: Any
|
||||
def begin(self): ...
|
||||
def close(self): ...
|
||||
@@ -46,7 +46,7 @@ class HTTPConnection:
|
||||
timeout = ... # type: Any
|
||||
source_address = ... # type: Any
|
||||
sock = ... # type: Any
|
||||
def __init__(self, host, port=None, timeout=..., source_address=None): ...
|
||||
def __init__(self, host, port=None, timeout=..., source_address=None) -> None: ...
|
||||
def set_tunnel(self, host, port=None, headers=None): ...
|
||||
def set_debuglevel(self, level): ...
|
||||
def connect(self): ...
|
||||
@@ -74,7 +74,7 @@ class InvalidURL(HTTPException): ...
|
||||
class UnknownProtocol(HTTPException):
|
||||
args = ... # type: Any
|
||||
version = ... # type: Any
|
||||
def __init__(self, version): ...
|
||||
def __init__(self, version) -> None: ...
|
||||
|
||||
class UnknownTransferEncoding(HTTPException): ...
|
||||
class UnimplementedFileMode(HTTPException): ...
|
||||
@@ -83,7 +83,7 @@ class IncompleteRead(HTTPException):
|
||||
args = ... # type: Any
|
||||
partial = ... # type: Any
|
||||
expected = ... # type: Any
|
||||
def __init__(self, partial, expected=None): ...
|
||||
def __init__(self, partial, expected=None) -> None: ...
|
||||
|
||||
class ImproperConnectionState(HTTPException): ...
|
||||
class CannotSendRequest(ImproperConnectionState): ...
|
||||
@@ -93,9 +93,9 @@ class ResponseNotReady(ImproperConnectionState): ...
|
||||
class BadStatusLine(HTTPException):
|
||||
args = ... # type: Any
|
||||
line = ... # type: Any
|
||||
def __init__(self, line): ...
|
||||
def __init__(self, line) -> None: ...
|
||||
|
||||
class LineTooLong(HTTPException):
|
||||
def __init__(self, line_type): ...
|
||||
def __init__(self, line_type) -> None: ...
|
||||
|
||||
error = HTTPException
|
||||
|
||||
@@ -88,7 +88,7 @@ class CookieJar:
|
||||
domain_re = ... # type: Any
|
||||
dots_re = ... # type: Any
|
||||
magic_re = ... # type: Any
|
||||
def __init__(self, policy=None): ...
|
||||
def __init__(self, policy=None) -> None: ...
|
||||
def set_policy(self, policy): ...
|
||||
def add_cookie_header(self, request): ...
|
||||
def make_cookies(self, response, request): ...
|
||||
@@ -106,7 +106,7 @@ class LoadError(OSError): ...
|
||||
class FileCookieJar(CookieJar):
|
||||
filename = ... # type: Any
|
||||
delayload = ... # type: Any
|
||||
def __init__(self, filename=None, delayload=False, policy=None): ...
|
||||
def __init__(self, filename=None, delayload=False, policy=None) -> None: ...
|
||||
def save(self, filename=None, ignore_discard=False, ignore_expires=False): ...
|
||||
def load(self, filename=None, ignore_discard=False, ignore_expires=False): ...
|
||||
def revert(self, filename=None, ignore_discard=False, ignore_expires=False): ...
|
||||
|
||||
@@ -19,7 +19,7 @@ class UnsupportedOperation(ValueError, OSError): ...
|
||||
|
||||
class IncrementalNewlineDecoder(codecs.IncrementalDecoder):
|
||||
newlines = ... # type: Any
|
||||
def __init__(self, *args, **kwargs): ...
|
||||
def __init__(self, *args, **kwargs) -> None: ...
|
||||
def decode(self, input, final=False): ...
|
||||
def getstate(self): ...
|
||||
def reset(self): ...
|
||||
@@ -33,7 +33,7 @@ class TextIOBase(_io._TextIOBase, IOBase): ...
|
||||
class FileIO(_io._RawIOBase):
|
||||
closefd = ... # type: Any
|
||||
mode = ... # type: Any
|
||||
def __init__(self, name, mode=..., closefd=..., opener=...): ...
|
||||
def __init__(self, name, mode=..., closefd=..., opener=...) -> None: ...
|
||||
def readinto(self, b): ...
|
||||
def write(self, b): ...
|
||||
|
||||
@@ -41,24 +41,24 @@ class BufferedReader(_io._BufferedIOBase):
|
||||
mode = ... # type: Any
|
||||
name = ... # type: Any
|
||||
raw = ... # type: Any
|
||||
def __init__(self, raw, buffer_size=...): ...
|
||||
def __init__(self, raw, buffer_size=...) -> None: ...
|
||||
def peek(self, size: int = -1): ...
|
||||
|
||||
class BufferedWriter(_io._BufferedIOBase):
|
||||
mode = ... # type: Any
|
||||
name = ... # type: Any
|
||||
raw = ... # type: Any
|
||||
def __init__(self, raw, buffer_size=...): ...
|
||||
def __init__(self, raw, buffer_size=...) -> None: ...
|
||||
|
||||
class BufferedRWPair(_io._BufferedIOBase):
|
||||
def __init__(self, reader, writer, buffer_size=...): ...
|
||||
def __init__(self, reader, writer, buffer_size=...) -> None: ...
|
||||
def peek(self, size: int = -1): ...
|
||||
|
||||
class BufferedRandom(_io._BufferedIOBase):
|
||||
mode = ... # type: Any
|
||||
name = ... # type: Any
|
||||
raw = ... # type: Any
|
||||
def __init__(self, raw, buffer_size=...): ...
|
||||
def __init__(self, raw, buffer_size=...) -> None: ...
|
||||
def peek(self, size: int = -1): ...
|
||||
|
||||
class BytesIO(BinaryIO):
|
||||
|
||||
@@ -49,7 +49,7 @@ class PercentStyle:
|
||||
default_format = ... # type: Any
|
||||
asctime_format = ... # type: Any
|
||||
asctime_search = ... # type: Any
|
||||
def __init__(self, fmt): ...
|
||||
def __init__(self, fmt) -> None: ...
|
||||
def usesTime(self): ...
|
||||
def format(self, record): ...
|
||||
|
||||
@@ -63,7 +63,7 @@ class StringTemplateStyle(PercentStyle):
|
||||
default_format = ... # type: Any
|
||||
asctime_format = ... # type: Any
|
||||
asctime_search = ... # type: Any
|
||||
def __init__(self, fmt): ...
|
||||
def __init__(self, fmt) -> None: ...
|
||||
def usesTime(self): ...
|
||||
def format(self, record): ...
|
||||
|
||||
@@ -72,7 +72,7 @@ BASIC_FORMAT = ... # type: Any
|
||||
class Formatter:
|
||||
converter = ... # type: Any
|
||||
datefmt = ... # type: Any
|
||||
def __init__(self, fmt=None, datefmt=None, style=''): ...
|
||||
def __init__(self, fmt=None, datefmt=None, style='') -> None: ...
|
||||
default_time_format = ... # type: Any
|
||||
default_msec_format = ... # type: Any
|
||||
def formatTime(self, record, datefmt=None): ...
|
||||
@@ -84,7 +84,7 @@ class Formatter:
|
||||
|
||||
class BufferingFormatter:
|
||||
linefmt = ... # type: Any
|
||||
def __init__(self, linefmt=None): ...
|
||||
def __init__(self, linefmt=None) -> None: ...
|
||||
def formatHeader(self, records): ...
|
||||
def formatFooter(self, records): ...
|
||||
def format(self, records): ...
|
||||
@@ -92,12 +92,12 @@ class BufferingFormatter:
|
||||
class Filter:
|
||||
name = ... # type: Any
|
||||
nlen = ... # type: Any
|
||||
def __init__(self, name=''): ...
|
||||
def __init__(self, name='') -> None: ...
|
||||
def filter(self, record): ...
|
||||
|
||||
class Filterer:
|
||||
filters = ... # type: Any
|
||||
def __init__(self): ...
|
||||
def __init__(self) -> None: ...
|
||||
def addFilter(self, filter): ...
|
||||
def removeFilter(self, filter): ...
|
||||
def filter(self, record): ...
|
||||
@@ -105,7 +105,7 @@ class Filterer:
|
||||
class Handler(Filterer):
|
||||
level = ... # type: Any
|
||||
formatter = ... # type: Any
|
||||
def __init__(self, level=...): ...
|
||||
def __init__(self, level=...) -> None: ...
|
||||
def get_name(self): ...
|
||||
def set_name(self, name): ...
|
||||
name = ... # type: Any
|
||||
@@ -125,7 +125,7 @@ class Handler(Filterer):
|
||||
class StreamHandler(Handler):
|
||||
terminator = ... # type: Any
|
||||
stream = ... # type: Any
|
||||
def __init__(self, stream=None): ...
|
||||
def __init__(self, stream=None) -> None: ...
|
||||
def flush(self): ...
|
||||
def emit(self, record): ...
|
||||
|
||||
@@ -135,18 +135,18 @@ class FileHandler(StreamHandler):
|
||||
encoding = ... # type: Any
|
||||
delay = ... # type: Any
|
||||
stream = ... # type: Any
|
||||
def __init__(self, filename, mode='', encoding=None, delay=False): ...
|
||||
def __init__(self, filename, mode='', encoding=None, delay=False) -> None: ...
|
||||
def close(self): ...
|
||||
def emit(self, record): ...
|
||||
|
||||
class _StderrHandler(StreamHandler):
|
||||
def __init__(self, level=...): ...
|
||||
def __init__(self, level=...) -> None: ...
|
||||
|
||||
lastResort = ... # type: Any
|
||||
|
||||
class PlaceHolder:
|
||||
loggerMap = ... # type: Any
|
||||
def __init__(self, alogger): ...
|
||||
def __init__(self, alogger) -> None: ...
|
||||
def append(self, alogger): ...
|
||||
|
||||
def setLoggerClass(klass): ...
|
||||
@@ -159,7 +159,7 @@ class Manager:
|
||||
loggerDict = ... # type: Any
|
||||
loggerClass = ... # type: Any
|
||||
logRecordFactory = ... # type: Any
|
||||
def __init__(self, rootnode): ...
|
||||
def __init__(self, rootnode) -> None: ...
|
||||
def getLogger(self, name): ...
|
||||
def setLoggerClass(self, klass): ...
|
||||
def setLogRecordFactory(self, factory): ...
|
||||
@@ -171,7 +171,7 @@ class Logger(Filterer):
|
||||
propagate = ... # type: Any
|
||||
handlers = ... # type: Any
|
||||
disabled = ... # type: Any
|
||||
def __init__(self, name, level=...): ...
|
||||
def __init__(self, name, level=...) -> None: ...
|
||||
def setLevel(self, level): ...
|
||||
def debug(self, msg, *args, **kwargs): ...
|
||||
def info(self, msg, *args, **kwargs): ...
|
||||
@@ -195,12 +195,12 @@ class Logger(Filterer):
|
||||
def getChild(self, suffix): ...
|
||||
|
||||
class RootLogger(Logger):
|
||||
def __init__(self, level): ...
|
||||
def __init__(self, level) -> None: ...
|
||||
|
||||
class LoggerAdapter:
|
||||
logger = ... # type: Any
|
||||
extra = ... # type: Any
|
||||
def __init__(self, logger, extra): ...
|
||||
def __init__(self, logger, extra) -> None: ...
|
||||
def process(self, msg, kwargs): ...
|
||||
def debug(self, msg, *args, **kwargs): ...
|
||||
def info(self, msg, *args, **kwargs): ...
|
||||
|
||||
@@ -18,7 +18,7 @@ class BaseRotatingHandler(logging.FileHandler):
|
||||
encoding = ... # type: Any
|
||||
namer = ... # type: Any
|
||||
rotator = ... # type: Any
|
||||
def __init__(self, filename, mode, encoding=None, delay=False): ...
|
||||
def __init__(self, filename, mode, encoding=None, delay=False) -> None: ...
|
||||
def emit(self, record): ...
|
||||
def rotation_filename(self, default_name): ...
|
||||
def rotate(self, source, dest): ...
|
||||
@@ -51,7 +51,7 @@ class TimedRotatingFileHandler(BaseRotatingHandler):
|
||||
def doRollover(self): ...
|
||||
|
||||
class WatchedFileHandler(logging.FileHandler):
|
||||
def __init__(self, filename, mode='', encoding=None, delay=False): ...
|
||||
def __init__(self, filename, mode='', encoding=None, delay=False) -> None: ...
|
||||
stream = ... # type: Any
|
||||
def emit(self, record): ...
|
||||
|
||||
@@ -65,7 +65,7 @@ class SocketHandler(logging.Handler):
|
||||
retryStart = ... # type: Any
|
||||
retryMax = ... # type: Any
|
||||
retryFactor = ... # type: Any
|
||||
def __init__(self, host, port): ...
|
||||
def __init__(self, host, port) -> None: ...
|
||||
def makeSocket(self, timeout=1): ...
|
||||
retryPeriod = ... # type: Any
|
||||
def createSocket(self): ...
|
||||
@@ -77,7 +77,7 @@ class SocketHandler(logging.Handler):
|
||||
|
||||
class DatagramHandler(SocketHandler):
|
||||
closeOnError = ... # type: Any
|
||||
def __init__(self, host, port): ...
|
||||
def __init__(self, host, port) -> None: ...
|
||||
def makeSocket(self, timeout=1): ... # TODO: Actually does not have the timeout argument.
|
||||
def send(self, s): ...
|
||||
|
||||
@@ -119,7 +119,7 @@ class SysLogHandler(logging.Handler):
|
||||
unixsocket = ... # type: Any
|
||||
socket = ... # type: Any
|
||||
formatter = ... # type: Any
|
||||
def __init__(self, address=..., facility=..., socktype=None): ...
|
||||
def __init__(self, address=..., facility=..., socktype=None) -> None: ...
|
||||
def encodePriority(self, facility, priority): ...
|
||||
def close(self): ...
|
||||
def mapPriority(self, levelName): ...
|
||||
@@ -145,7 +145,7 @@ class NTEventLogHandler(logging.Handler):
|
||||
logtype = ... # type: Any
|
||||
deftype = ... # type: Any
|
||||
typemap = ... # type: Any
|
||||
def __init__(self, appname, dllname=None, logtype=''): ...
|
||||
def __init__(self, appname, dllname=None, logtype='') -> None: ...
|
||||
def getMessageID(self, record): ...
|
||||
def getEventCategory(self, record): ...
|
||||
def getEventType(self, record): ...
|
||||
@@ -158,14 +158,14 @@ class HTTPHandler(logging.Handler):
|
||||
method = ... # type: Any
|
||||
secure = ... # type: Any
|
||||
credentials = ... # type: Any
|
||||
def __init__(self, host, url, method='', secure=False, credentials=None): ...
|
||||
def __init__(self, host, url, method='', secure=False, credentials=None) -> None: ...
|
||||
def mapLogRecord(self, record): ...
|
||||
def emit(self, record): ...
|
||||
|
||||
class BufferingHandler(logging.Handler):
|
||||
capacity = ... # type: Any
|
||||
buffer = ... # type: Any
|
||||
def __init__(self, capacity): ...
|
||||
def __init__(self, capacity) -> None: ...
|
||||
def shouldFlush(self, record): ...
|
||||
def emit(self, record): ...
|
||||
def flush(self): ...
|
||||
@@ -174,7 +174,7 @@ class BufferingHandler(logging.Handler):
|
||||
class MemoryHandler(BufferingHandler):
|
||||
flushLevel = ... # type: Any
|
||||
target = ... # type: Any
|
||||
def __init__(self, capacity, flushLevel=..., target=None): ...
|
||||
def __init__(self, capacity, flushLevel=..., target=None) -> None: ...
|
||||
def shouldFlush(self, record): ...
|
||||
def setTarget(self, target): ...
|
||||
buffer = ... # type: Any
|
||||
@@ -183,7 +183,7 @@ class MemoryHandler(BufferingHandler):
|
||||
|
||||
class QueueHandler(logging.Handler):
|
||||
queue = ... # type: Any
|
||||
def __init__(self, queue): ...
|
||||
def __init__(self, queue) -> None: ...
|
||||
def enqueue(self, record): ...
|
||||
def prepare(self, record): ...
|
||||
def emit(self, record): ...
|
||||
@@ -191,7 +191,7 @@ class QueueHandler(logging.Handler):
|
||||
class QueueListener:
|
||||
queue = ... # type: Any
|
||||
handlers = ... # type: Any
|
||||
def __init__(self, queue, *handlers): ...
|
||||
def __init__(self, queue, *handlers) -> None: ...
|
||||
def dequeue(self, block): ...
|
||||
def start(self): ...
|
||||
def prepare(self, record): ...
|
||||
|
||||
@@ -11,19 +11,19 @@ class SMTPResponseException(SMTPException):
|
||||
smtp_code = ... # type: Any
|
||||
smtp_error = ... # type: Any
|
||||
args = ... # type: Any
|
||||
def __init__(self, code, msg): ...
|
||||
def __init__(self, code, msg) -> None: ...
|
||||
|
||||
class SMTPSenderRefused(SMTPResponseException):
|
||||
smtp_code = ... # type: Any
|
||||
smtp_error = ... # type: Any
|
||||
sender = ... # type: Any
|
||||
args = ... # type: Any
|
||||
def __init__(self, code, msg, sender): ...
|
||||
def __init__(self, code, msg, sender) -> None: ...
|
||||
|
||||
class SMTPRecipientsRefused(SMTPException):
|
||||
recipients = ... # type: Any
|
||||
args = ... # type: Any
|
||||
def __init__(self, recipients): ...
|
||||
def __init__(self, recipients) -> None: ...
|
||||
|
||||
class SMTPDataError(SMTPResponseException): ...
|
||||
class SMTPConnectError(SMTPResponseException): ...
|
||||
@@ -88,7 +88,7 @@ class SMTP_SSL(SMTP):
|
||||
|
||||
class LMTP(SMTP):
|
||||
ehlo_msg = ... # type: Any
|
||||
def __init__(self, host='', port=..., local_hostname=None, source_address=None): ...
|
||||
def __init__(self, host='', port=..., local_hostname=None, source_address=None) -> None: ...
|
||||
sock = ... # type: Any
|
||||
file = ... # type: Any
|
||||
def connect(self, host='', port=0, source_address=None): ...
|
||||
|
||||
@@ -120,7 +120,7 @@ class _SSLContext:
|
||||
options = ... # type: Any
|
||||
verify_flags = ... # type: Any
|
||||
verify_mode = ... # type: Any
|
||||
def __init__(self, *args, **kwargs): ...
|
||||
def __init__(self, *args, **kwargs) -> None: ...
|
||||
def _set_npn_protocols(self, *args, **kwargs): ...
|
||||
def _wrap_socket(self, *args, **kwargs): ...
|
||||
def cert_store_stats(self): ...
|
||||
@@ -137,7 +137,7 @@ class _SSLContext:
|
||||
class SSLContext(_SSLContext):
|
||||
def __new__(cls, protocol, *args, **kwargs): ...
|
||||
protocol = ... # type: Any
|
||||
def __init__(self, protocol): ...
|
||||
def __init__(self, protocol) -> None: ...
|
||||
def wrap_socket(self, sock, server_side=False, do_handshake_on_connect=True,
|
||||
suppress_ragged_eofs=True, server_hostname=None): ...
|
||||
def set_npn_protocols(self, npn_protocols): ...
|
||||
|
||||
@@ -21,7 +21,7 @@ no_type_check = object()
|
||||
|
||||
class TypeAlias:
|
||||
# Class for defining generic aliases for library types.
|
||||
def __init__(self, target_type): ...
|
||||
def __init__(self, target_type) -> None: ...
|
||||
def __getitem__(self, typeargs): ...
|
||||
|
||||
Union = TypeAlias(object)
|
||||
|
||||
@@ -16,7 +16,7 @@ class BaseBrowser:
|
||||
args = ... # type: Any
|
||||
name = ... # type: Any
|
||||
basename = ... # type: Any
|
||||
def __init__(self, name=''): ...
|
||||
def __init__(self, name='') -> None: ...
|
||||
def open(self, url, new=0, autoraise=True): ...
|
||||
def open_new(self, url): ...
|
||||
def open_new_tab(self, url): ...
|
||||
@@ -25,7 +25,7 @@ class GenericBrowser(BaseBrowser):
|
||||
name = ... # type: Any
|
||||
args = ... # type: Any
|
||||
basename = ... # type: Any
|
||||
def __init__(self, name): ...
|
||||
def __init__(self, name) -> None: ...
|
||||
def open(self, url, new=0, autoraise=True): ...
|
||||
|
||||
class BackgroundBrowser(GenericBrowser):
|
||||
@@ -90,9 +90,9 @@ class WindowsDefault(BaseBrowser):
|
||||
|
||||
class MacOSX(BaseBrowser):
|
||||
name = ... # type: Any
|
||||
def __init__(self, name): ...
|
||||
def __init__(self, name) -> None: ...
|
||||
def open(self, url, new=0, autoraise=True): ...
|
||||
|
||||
class MacOSXOSAScript(BaseBrowser):
|
||||
def __init__(self, name): ...
|
||||
def __init__(self, name) -> None: ...
|
||||
def open(self, url, new=0, autoraise=True): ...
|
||||
|
||||
@@ -20,7 +20,7 @@ ops = ... # type: Any
|
||||
class _SelectorContext:
|
||||
parent_map = ... # type: Any
|
||||
root = ... # type: Any
|
||||
def __init__(self, root): ...
|
||||
def __init__(self, root) -> None: ...
|
||||
|
||||
def iterfind(elem, path, namespaces=None): ...
|
||||
def find(elem, path, namespaces=None): ...
|
||||
|
||||
@@ -12,7 +12,7 @@ class ParseError(SyntaxError): ...
|
||||
def iselement(element): ...
|
||||
|
||||
class Element:
|
||||
def __init__(self, tag, attrib=..., **extra): ...
|
||||
def __init__(self, tag, attrib=..., **extra) -> None: ...
|
||||
def append(self, *args, **kwargs): ...
|
||||
def clear(self, *args, **kwargs): ...
|
||||
def extend(self, *args, **kwargs): ...
|
||||
@@ -51,7 +51,7 @@ PI = ... # type: Any
|
||||
|
||||
class QName:
|
||||
text = ... # type: Any
|
||||
def __init__(self, text_or_uri, tag=None): ...
|
||||
def __init__(self, text_or_uri, tag=None) -> None: ...
|
||||
def __hash__(self): ...
|
||||
def __le__(self, other): ...
|
||||
def __lt__(self, other): ...
|
||||
@@ -61,7 +61,7 @@ class QName:
|
||||
def __ne__(self, other): ...
|
||||
|
||||
class ElementTree:
|
||||
def __init__(self, element=None, file=None): ...
|
||||
def __init__(self, element=None, file=None) -> None: ...
|
||||
def getroot(self): ...
|
||||
def parse(self, source, parser=None): ...
|
||||
def iter(self, tag=None): ...
|
||||
@@ -78,7 +78,7 @@ def tostring(element, encoding=None, method=None, *, short_empty_elements=True):
|
||||
|
||||
class _ListDataStream(io.BufferedIOBase):
|
||||
lst = ... # type: Any
|
||||
def __init__(self, lst): ...
|
||||
def __init__(self, lst) -> None: ...
|
||||
def writable(self): ...
|
||||
def seekable(self): ...
|
||||
def write(self, b): ...
|
||||
@@ -90,14 +90,14 @@ def parse(source, parser=None): ...
|
||||
def iterparse(source, events=None, parser=None): ...
|
||||
|
||||
class XMLPullParser:
|
||||
def __init__(self, events=None, *, _parser=None): ...
|
||||
def __init__(self, events=None, *, _parser=None) -> None: ...
|
||||
def feed(self, data): ...
|
||||
def close(self): ...
|
||||
def read_events(self): ...
|
||||
|
||||
class _IterParseIterator:
|
||||
root = ... # type: Any
|
||||
def __init__(self, source, events, parser, close_source=False): ...
|
||||
def __init__(self, source, events, parser, close_source=False) -> None: ...
|
||||
def __next__(self): ...
|
||||
def __iter__(self): ...
|
||||
|
||||
@@ -109,7 +109,7 @@ fromstring = ... # type: Any
|
||||
def fromstringlist(sequence, parser=None): ...
|
||||
|
||||
class TreeBuilder:
|
||||
def __init__(self, element_factory=None): ...
|
||||
def __init__(self, element_factory=None) -> None: ...
|
||||
def close(self): ...
|
||||
def data(self, data): ...
|
||||
def start(self, tag, attrs): ...
|
||||
@@ -119,7 +119,7 @@ class XMLParser:
|
||||
target = ... # type: Any
|
||||
entity = ... # type: Any
|
||||
version = ... # type: Any
|
||||
def __init__(self, html=..., target=..., encoding=...): ...
|
||||
def __init__(self, html=..., target=..., encoding=...) -> None: ...
|
||||
def _parse_whole(self, *args, **kwargs): ...
|
||||
def _setevents(self, *args, **kwargs): ...
|
||||
def close(self, *args, **kwargs): ...
|
||||
|
||||
Reference in New Issue
Block a user