mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-03-25 07:28:01 +08:00
upgrade black version (#4486)
Manually removed a number of trailing commas to prevent black from unnecessarily exploding some collections.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
git+https://github.com/python/mypy.git@master
|
||||
typed-ast>=1.0.4
|
||||
black==19.10b0
|
||||
black==20.8b1
|
||||
flake8==3.8.3
|
||||
flake8-bugbear==20.1.4
|
||||
flake8-pyi==20.5.0
|
||||
|
||||
@@ -93,5 +93,5 @@ class SafeConfigParser(ConfigParser):
|
||||
_interpvar_re: Any
|
||||
def _interpolate(self, section: str, option: str, rawval: Any, vars: Any) -> str: ...
|
||||
def _interpolate_some(
|
||||
self, option: str, accum: List[Any], rest: str, section: str, map: Dict[Any, Any], depth: int,
|
||||
self, option: str, accum: List[Any], rest: str, section: str, map: Dict[Any, Any], depth: int
|
||||
) -> None: ...
|
||||
|
||||
@@ -641,7 +641,7 @@ if sys.version_info >= (3,):
|
||||
def split(self, sep: Optional[bytes] = ..., maxsplit: int = ...) -> List[bytes]: ...
|
||||
def splitlines(self, keepends: bool = ...) -> List[bytes]: ...
|
||||
def startswith(
|
||||
self, prefix: Union[bytes, Tuple[bytes, ...]], start: Optional[int] = ..., end: Optional[int] = ...,
|
||||
self, prefix: Union[bytes, Tuple[bytes, ...]], start: Optional[int] = ..., end: Optional[int] = ...
|
||||
) -> bool: ...
|
||||
def strip(self, __bytes: Optional[bytes] = ...) -> bytes: ...
|
||||
def swapcase(self) -> bytes: ...
|
||||
@@ -759,7 +759,7 @@ class bytearray(MutableSequence[int], ByteString):
|
||||
def split(self, sep: Optional[bytes] = ..., maxsplit: int = ...) -> List[bytearray]: ...
|
||||
def splitlines(self, keepends: bool = ...) -> List[bytearray]: ...
|
||||
def startswith(
|
||||
self, __prefix: Union[bytes, Tuple[bytes, ...]], __start: Optional[int] = ..., __end: Optional[int] = ...,
|
||||
self, __prefix: Union[bytes, Tuple[bytes, ...]], __start: Optional[int] = ..., __end: Optional[int] = ...
|
||||
) -> bool: ...
|
||||
def strip(self, __bytes: Optional[bytes] = ...) -> bytearray: ...
|
||||
def swapcase(self) -> bytearray: ...
|
||||
|
||||
@@ -11,6 +11,6 @@ def compile_dir(
|
||||
quiet: int = ...,
|
||||
) -> int: ...
|
||||
def compile_file(
|
||||
fullname: AnyPath, ddir: Optional[AnyPath] = ..., force: bool = ..., rx: Optional[Pattern[Any]] = ..., quiet: int = ...,
|
||||
fullname: AnyPath, ddir: Optional[AnyPath] = ..., force: bool = ..., rx: Optional[Pattern[Any]] = ..., quiet: int = ...
|
||||
) -> int: ...
|
||||
def compile_path(skip_curdir: bool = ..., maxlevels: int = ..., force: bool = ..., quiet: int = ...) -> int: ...
|
||||
|
||||
@@ -456,7 +456,7 @@ class Pattern(Generic[AnyStr]):
|
||||
# Functions
|
||||
|
||||
def get_type_hints(
|
||||
obj: Callable[..., Any], globalns: Optional[Dict[Text, Any]] = ..., localns: Optional[Dict[Text, Any]] = ...,
|
||||
obj: Callable[..., Any], globalns: Optional[Dict[Text, Any]] = ..., localns: Optional[Dict[Text, Any]] = ...
|
||||
) -> None: ...
|
||||
@overload
|
||||
def cast(tp: Type[_T], obj: Any) -> _T: ...
|
||||
|
||||
@@ -34,9 +34,7 @@ _FT = TypeVar("_FT")
|
||||
_ExceptionType = Union[Type[BaseException], Tuple[Type[BaseException], ...]]
|
||||
_Regexp = Union[Text, Pattern[Text]]
|
||||
|
||||
_SysExcInfoType = Union[
|
||||
Tuple[Type[BaseException], BaseException, types.TracebackType], Tuple[None, None, None],
|
||||
]
|
||||
_SysExcInfoType = Union[Tuple[Type[BaseException], BaseException, types.TracebackType], Tuple[None, None, None]]
|
||||
|
||||
class Testable(metaclass=ABCMeta):
|
||||
@abstractmethod
|
||||
|
||||
@@ -121,7 +121,7 @@ class Marshaller:
|
||||
Mapping[Any, Any],
|
||||
datetime,
|
||||
InstanceType,
|
||||
],
|
||||
]
|
||||
],
|
||||
Fault,
|
||||
],
|
||||
|
||||
@@ -136,12 +136,8 @@ OpenBinaryModeUpdating = Literal[
|
||||
"b+x",
|
||||
"+bx",
|
||||
]
|
||||
OpenBinaryModeWriting = Literal[
|
||||
"wb", "bw", "ab", "ba", "xb", "bx",
|
||||
]
|
||||
OpenBinaryModeReading = Literal[
|
||||
"rb", "br", "rbU", "rUb", "Urb", "brU", "bUr", "Ubr",
|
||||
]
|
||||
OpenBinaryModeWriting = Literal["wb", "bw", "ab", "ba", "xb", "bx"]
|
||||
OpenBinaryModeReading = Literal["rb", "br", "rbU", "rUb", "Urb", "brU", "bUr", "Ubr"]
|
||||
OpenBinaryMode = Union[OpenBinaryModeUpdating, OpenBinaryModeReading, OpenBinaryModeWriting]
|
||||
|
||||
class HasFileno(Protocol):
|
||||
|
||||
@@ -641,7 +641,7 @@ if sys.version_info >= (3,):
|
||||
def split(self, sep: Optional[bytes] = ..., maxsplit: int = ...) -> List[bytes]: ...
|
||||
def splitlines(self, keepends: bool = ...) -> List[bytes]: ...
|
||||
def startswith(
|
||||
self, prefix: Union[bytes, Tuple[bytes, ...]], start: Optional[int] = ..., end: Optional[int] = ...,
|
||||
self, prefix: Union[bytes, Tuple[bytes, ...]], start: Optional[int] = ..., end: Optional[int] = ...
|
||||
) -> bool: ...
|
||||
def strip(self, __bytes: Optional[bytes] = ...) -> bytes: ...
|
||||
def swapcase(self) -> bytes: ...
|
||||
@@ -759,7 +759,7 @@ class bytearray(MutableSequence[int], ByteString):
|
||||
def split(self, sep: Optional[bytes] = ..., maxsplit: int = ...) -> List[bytearray]: ...
|
||||
def splitlines(self, keepends: bool = ...) -> List[bytearray]: ...
|
||||
def startswith(
|
||||
self, __prefix: Union[bytes, Tuple[bytes, ...]], __start: Optional[int] = ..., __end: Optional[int] = ...,
|
||||
self, __prefix: Union[bytes, Tuple[bytes, ...]], __start: Optional[int] = ..., __end: Optional[int] = ...
|
||||
) -> bool: ...
|
||||
def strip(self, __bytes: Optional[bytes] = ...) -> bytearray: ...
|
||||
def swapcase(self) -> bytearray: ...
|
||||
|
||||
@@ -57,7 +57,7 @@ class SequenceMatcher(Generic[_T]):
|
||||
# mypy thinks the signatures of the overloads overlap, but the types still work fine
|
||||
@overload
|
||||
def get_close_matches( # type: ignore
|
||||
word: AnyStr, possibilities: Iterable[AnyStr], n: int = ..., cutoff: float = ...,
|
||||
word: AnyStr, possibilities: Iterable[AnyStr], n: int = ..., cutoff: float = ...
|
||||
) -> List[AnyStr]: ...
|
||||
@overload
|
||||
def get_close_matches(
|
||||
|
||||
@@ -49,7 +49,7 @@ def wrap_socket(
|
||||
ciphers: Optional[str] = ...,
|
||||
) -> SSLSocket: ...
|
||||
def create_default_context(
|
||||
purpose: Any = ..., *, cafile: Optional[str] = ..., capath: Optional[str] = ..., cadata: Union[Text, bytes, None] = ...,
|
||||
purpose: Any = ..., *, cafile: Optional[str] = ..., capath: Optional[str] = ..., cadata: Union[Text, bytes, None] = ...
|
||||
) -> SSLContext: ...
|
||||
|
||||
if sys.version_info >= (3, 7):
|
||||
@@ -300,7 +300,7 @@ class SSLContext:
|
||||
) -> None: ...
|
||||
def load_default_certs(self, purpose: Purpose = ...) -> None: ...
|
||||
def load_verify_locations(
|
||||
self, cafile: Optional[StrPath] = ..., capath: Optional[StrPath] = ..., cadata: Union[Text, bytes, None] = ...,
|
||||
self, cafile: Optional[StrPath] = ..., capath: Optional[StrPath] = ..., cadata: Union[Text, bytes, None] = ...
|
||||
) -> None: ...
|
||||
def get_ca_certs(self, binary_form: bool = ...) -> Union[List[_PeerCertRetDictType], List[bytes]]: ...
|
||||
def set_default_verify_paths(self) -> None: ...
|
||||
|
||||
@@ -28,6 +28,6 @@ if sys.version_info >= (3, 8):
|
||||
else:
|
||||
def make_parser(parser_list: List[str] = ...) -> XMLReader: ...
|
||||
|
||||
def parse(source: Union[str, IO[str], IO[bytes]], handler: ContentHandler, errorHandler: ErrorHandler = ...,) -> None: ...
|
||||
def parseString(string: Union[bytes, Text], handler: ContentHandler, errorHandler: Optional[ErrorHandler] = ...,) -> None: ...
|
||||
def parse(source: Union[str, IO[str], IO[bytes]], handler: ContentHandler, errorHandler: ErrorHandler = ...) -> None: ...
|
||||
def parseString(string: Union[bytes, Text], handler: ContentHandler, errorHandler: Optional[ErrorHandler] = ...) -> None: ...
|
||||
def _create_parser(parser_name: str) -> XMLReader: ...
|
||||
|
||||
@@ -48,7 +48,7 @@ class ZipExtFile(io.BufferedIOBase):
|
||||
name: str
|
||||
if sys.version_info >= (3, 7):
|
||||
def __init__(
|
||||
self, fileobj: IO[bytes], mode: str, zipinfo: ZipInfo, pwd: Optional[bytes] = ..., close_fileobj: bool = ...,
|
||||
self, fileobj: IO[bytes], mode: str, zipinfo: ZipInfo, pwd: Optional[bytes] = ..., close_fileobj: bool = ...
|
||||
) -> None: ...
|
||||
else:
|
||||
def __init__(
|
||||
|
||||
@@ -17,7 +17,7 @@ class LockType:
|
||||
def locked(self) -> bool: ...
|
||||
def __enter__(self) -> bool: ...
|
||||
def __exit__(
|
||||
self, type: Optional[Type[BaseException]], value: Optional[BaseException], traceback: Optional[TracebackType],
|
||||
self, type: Optional[Type[BaseException]], value: Optional[BaseException], traceback: Optional[TracebackType]
|
||||
) -> None: ...
|
||||
|
||||
def start_new_thread(function: Callable[..., Any], args: Tuple[Any, ...], kwargs: Dict[str, Any] = ...) -> int: ...
|
||||
|
||||
@@ -40,10 +40,10 @@ class BaseEventLoop(AbstractEventLoop, metaclass=ABCMeta):
|
||||
if sys.version_info >= (3, 7):
|
||||
def call_soon(self, callback: Callable[..., Any], *args: Any, context: Optional[Context] = ...) -> Handle: ...
|
||||
def call_later(
|
||||
self, delay: float, callback: Callable[..., Any], *args: Any, context: Optional[Context] = ...,
|
||||
self, delay: float, callback: Callable[..., Any], *args: Any, context: Optional[Context] = ...
|
||||
) -> TimerHandle: ...
|
||||
def call_at(
|
||||
self, when: float, callback: Callable[..., Any], *args: Any, context: Optional[Context] = ...,
|
||||
self, when: float, callback: Callable[..., Any], *args: Any, context: Optional[Context] = ...
|
||||
) -> TimerHandle: ...
|
||||
else:
|
||||
def call_soon(self, callback: Callable[..., Any], *args: Any) -> Handle: ...
|
||||
@@ -54,9 +54,7 @@ class BaseEventLoop(AbstractEventLoop, metaclass=ABCMeta):
|
||||
def create_future(self) -> Future[Any]: ...
|
||||
# Tasks methods
|
||||
if sys.version_info >= (3, 8):
|
||||
def create_task(
|
||||
self, coro: Union[Awaitable[_T], Generator[Any, None, _T]], *, name: Optional[str] = ...,
|
||||
) -> Task[_T]: ...
|
||||
def create_task(self, coro: Union[Awaitable[_T], Generator[Any, None, _T]], *, name: Optional[str] = ...) -> Task[_T]: ...
|
||||
else:
|
||||
def create_task(self, coro: Union[Awaitable[_T], Generator[Any, None, _T]]) -> Task[_T]: ...
|
||||
def set_task_factory(
|
||||
@@ -68,7 +66,7 @@ class BaseEventLoop(AbstractEventLoop, metaclass=ABCMeta):
|
||||
def call_soon_threadsafe(self, callback: Callable[..., Any], *args: Any, context: Optional[Context] = ...) -> Handle: ...
|
||||
else:
|
||||
def call_soon_threadsafe(self, callback: Callable[..., Any], *args: Any) -> Handle: ...
|
||||
def run_in_executor(self, executor: Any, func: Callable[..., _T], *args: Any,) -> Future[_T]: ...
|
||||
def run_in_executor(self, executor: Any, func: Callable[..., _T], *args: Any) -> Future[_T]: ...
|
||||
def set_default_executor(self, executor: Any) -> None: ...
|
||||
# Network I/O methods returning Futures.
|
||||
async def getaddrinfo(
|
||||
|
||||
@@ -100,9 +100,7 @@ class AbstractEventLoop(metaclass=ABCMeta):
|
||||
# Tasks methods
|
||||
if sys.version_info >= (3, 8):
|
||||
@abstractmethod
|
||||
def create_task(
|
||||
self, coro: Union[Awaitable[_T], Generator[Any, None, _T]], *, name: Optional[str] = ...,
|
||||
) -> Task[_T]: ...
|
||||
def create_task(self, coro: Union[Awaitable[_T], Generator[Any, None, _T]], *, name: Optional[str] = ...) -> Task[_T]: ...
|
||||
else:
|
||||
@abstractmethod
|
||||
def create_task(self, coro: Union[Awaitable[_T], Generator[Any, None, _T]]) -> Task[_T]: ...
|
||||
|
||||
@@ -192,7 +192,7 @@ class Task(Future[_T], Generic[_T]):
|
||||
if sys.version_info >= (3, 7):
|
||||
def all_tasks(loop: Optional[AbstractEventLoop] = ...) -> Set[Task[Any]]: ...
|
||||
if sys.version_info >= (3, 8):
|
||||
def create_task(coro: Union[Generator[Any, None, _T], Awaitable[_T]], *, name: Optional[str] = ...,) -> Task[_T]: ...
|
||||
def create_task(coro: Union[Generator[Any, None, _T], Awaitable[_T]], *, name: Optional[str] = ...) -> Task[_T]: ...
|
||||
else:
|
||||
def create_task(coro: Union[Generator[Any, None, _T], Awaitable[_T]]) -> Task[_T]: ...
|
||||
def current_task(loop: Optional[AbstractEventLoop] = ...) -> Optional[Task[Any]]: ...
|
||||
|
||||
@@ -67,7 +67,7 @@ elif sys.version_info >= (3, 6):
|
||||
|
||||
else:
|
||||
def namedtuple(
|
||||
typename: str, field_names: Union[str, Iterable[str]], verbose: bool = ..., rename: bool = ...,
|
||||
typename: str, field_names: Union[str, Iterable[str]], verbose: bool = ..., rename: bool = ...
|
||||
) -> Type[Tuple[Any, ...]]: ...
|
||||
|
||||
class UserDict(MutableMapping[_KT, _VT]):
|
||||
|
||||
@@ -52,7 +52,7 @@ class Executor:
|
||||
self, func: Callable[..., _T], *iterables: Iterable[Any], timeout: Optional[float] = ..., chunksize: int = ...
|
||||
) -> Iterator[_T]: ...
|
||||
else:
|
||||
def map(self, func: Callable[..., _T], *iterables: Iterable[Any], timeout: Optional[float] = ...,) -> Iterator[_T]: ...
|
||||
def map(self, func: Callable[..., _T], *iterables: Iterable[Any], timeout: Optional[float] = ...) -> Iterator[_T]: ...
|
||||
def shutdown(self, wait: bool = ...) -> None: ...
|
||||
def __enter__(self: _T) -> _T: ...
|
||||
def __exit__(self, exc_type: Any, exc_val: Any, exc_tb: Any) -> Optional[bool]: ...
|
||||
|
||||
@@ -131,7 +131,7 @@ class _HTTPConnectionProtocol(Protocol):
|
||||
) -> HTTPConnection: ...
|
||||
else:
|
||||
def __call__(
|
||||
self, host: str, port: Optional[int] = ..., timeout: float = ..., source_address: Optional[Tuple[str, int]] = ...,
|
||||
self, host: str, port: Optional[int] = ..., timeout: float = ..., source_address: Optional[Tuple[str, int]] = ...
|
||||
) -> HTTPConnection: ...
|
||||
|
||||
class HTTPConnection:
|
||||
|
||||
@@ -56,7 +56,7 @@ if sys.version_info < (3, 6):
|
||||
module_type: int
|
||||
def getmoduleinfo(path: str) -> Optional[ModuleInfo]: ...
|
||||
|
||||
def getmembers(object: object, predicate: Optional[Callable[[Any], bool]] = ...,) -> List[Tuple[str, Any]]: ...
|
||||
def getmembers(object: object, predicate: Optional[Callable[[Any], bool]] = ...) -> List[Tuple[str, Any]]: ...
|
||||
def getmodulename(path: str) -> Optional[str]: ...
|
||||
def ismodule(object: object) -> bool: ...
|
||||
def isclass(object: object) -> bool: ...
|
||||
|
||||
@@ -546,7 +546,7 @@ if sys.platform != "win32":
|
||||
|
||||
def write(__fd: int, __data: bytes) -> int: ...
|
||||
def access(
|
||||
path: _FdOrAnyPath, mode: int, *, dir_fd: Optional[int] = ..., effective_ids: bool = ..., follow_symlinks: bool = ...,
|
||||
path: _FdOrAnyPath, mode: int, *, dir_fd: Optional[int] = ..., effective_ids: bool = ..., follow_symlinks: bool = ...
|
||||
) -> bool: ...
|
||||
def chdir(path: _FdOrAnyPath) -> None: ...
|
||||
|
||||
@@ -571,7 +571,7 @@ if sys.platform != "win32":
|
||||
def lchown(path: AnyPath, uid: int, gid: int) -> None: ...
|
||||
|
||||
def link(
|
||||
src: AnyPath, dst: AnyPath, *, src_dir_fd: Optional[int] = ..., dst_dir_fd: Optional[int] = ..., follow_symlinks: bool = ...,
|
||||
src: AnyPath, dst: AnyPath, *, src_dir_fd: Optional[int] = ..., dst_dir_fd: Optional[int] = ..., follow_symlinks: bool = ...
|
||||
) -> None: ...
|
||||
def lstat(path: AnyPath, *, dir_fd: Optional[int] = ...) -> stat_result: ...
|
||||
def mkdir(path: AnyPath, mode: int = ..., *, dir_fd: Optional[int] = ...) -> None: ...
|
||||
@@ -638,7 +638,7 @@ if sys.version_info < (3, 7):
|
||||
if sys.platform != "win32":
|
||||
def statvfs(path: _FdOrAnyPath) -> statvfs_result: ... # Unix only
|
||||
|
||||
def symlink(src: AnyPath, dst: AnyPath, target_is_directory: bool = ..., *, dir_fd: Optional[int] = ...,) -> None: ...
|
||||
def symlink(src: AnyPath, dst: AnyPath, target_is_directory: bool = ..., *, dir_fd: Optional[int] = ...) -> None: ...
|
||||
|
||||
if sys.platform != "win32":
|
||||
def sync() -> None: ... # Unix only
|
||||
|
||||
@@ -100,7 +100,7 @@ class Path(PurePath):
|
||||
# Unbuffered binary mode: returns a FileIO
|
||||
@overload
|
||||
def open(
|
||||
self, mode: OpenBinaryMode, buffering: Literal[0], encoding: None = ..., errors: None = ..., newline: None = ...,
|
||||
self, mode: OpenBinaryMode, buffering: Literal[0], encoding: None = ..., errors: None = ..., newline: None = ...
|
||||
) -> FileIO: ...
|
||||
# Buffering is on: return BufferedRandom, BufferedReader, or BufferedWriter
|
||||
@overload
|
||||
@@ -133,7 +133,7 @@ class Path(PurePath):
|
||||
# Buffering cannot be determined: fall back to BinaryIO
|
||||
@overload
|
||||
def open(
|
||||
self, mode: OpenBinaryMode, buffering: int, encoding: None = ..., errors: None = ..., newline: None = ...,
|
||||
self, mode: OpenBinaryMode, buffering: int, encoding: None = ..., errors: None = ..., newline: None = ...
|
||||
) -> BinaryIO: ...
|
||||
# Fallback if mode is not specified
|
||||
@overload
|
||||
|
||||
@@ -11,9 +11,7 @@ def nametofont(name: str) -> Font: ...
|
||||
|
||||
# See 'FONT DESCRIPTIONS' in font man page. This uses str because Literal
|
||||
# inside Tuple doesn't work.
|
||||
_FontDescription = Union[
|
||||
str, Font, Tuple[str, int], Tuple[str, int, str], Tuple[str, int, tkinter._TkinterSequence[str]],
|
||||
]
|
||||
_FontDescription = Union[str, Font, Tuple[str, int], Tuple[str, int, str], Tuple[str, int, tkinter._TkinterSequence[str]]]
|
||||
|
||||
class _FontDict(TypedDict):
|
||||
family: str
|
||||
|
||||
@@ -416,7 +416,7 @@ class ContextManager(Protocol[_T_co]):
|
||||
class AsyncContextManager(Protocol[_T_co]):
|
||||
def __aenter__(self) -> Awaitable[_T_co]: ...
|
||||
def __aexit__(
|
||||
self, exc_type: Optional[Type[BaseException]], exc_value: Optional[BaseException], traceback: Optional[TracebackType],
|
||||
self, exc_type: Optional[Type[BaseException]], exc_value: Optional[BaseException], traceback: Optional[TracebackType]
|
||||
) -> Awaitable[Optional[bool]]: ...
|
||||
|
||||
class Mapping(_Collection[_KT], Generic[_KT, _VT_co]):
|
||||
@@ -558,7 +558,7 @@ class Match(Generic[AnyStr]):
|
||||
@overload
|
||||
def group(self, __group: Union[str, int] = ...) -> AnyStr: ...
|
||||
@overload
|
||||
def group(self, __group1: Union[str, int], __group2: Union[str, int], *groups: Union[str, int],) -> Tuple[AnyStr, ...]: ...
|
||||
def group(self, __group1: Union[str, int], __group2: Union[str, int], *groups: Union[str, int]) -> Tuple[AnyStr, ...]: ...
|
||||
def groups(self, default: AnyStr = ...) -> Sequence[AnyStr]: ...
|
||||
def groupdict(self, default: AnyStr = ...) -> dict[str, AnyStr]: ...
|
||||
def start(self, __group: Union[int, str] = ...) -> int: ...
|
||||
@@ -602,7 +602,7 @@ if sys.version_info >= (3, 9):
|
||||
|
||||
else:
|
||||
def get_type_hints(
|
||||
obj: Callable[..., Any], globalns: Optional[Dict[str, Any]] = ..., localns: Optional[Dict[str, Any]] = ...,
|
||||
obj: Callable[..., Any], globalns: Optional[Dict[str, Any]] = ..., localns: Optional[Dict[str, Any]] = ...
|
||||
) -> Dict[str, Any]: ...
|
||||
|
||||
if sys.version_info >= (3, 8):
|
||||
|
||||
@@ -2,9 +2,7 @@ import unittest.case
|
||||
from types import TracebackType
|
||||
from typing import Any, Callable, List, Optional, TextIO, Tuple, Type, TypeVar, Union
|
||||
|
||||
_SysExcInfoType = Union[
|
||||
Tuple[Type[BaseException], BaseException, TracebackType], Tuple[None, None, None],
|
||||
]
|
||||
_SysExcInfoType = Union[Tuple[Type[BaseException], BaseException, TracebackType], Tuple[None, None, None]]
|
||||
|
||||
_F = TypeVar("_F", bound=Callable[..., Any])
|
||||
|
||||
|
||||
@@ -95,10 +95,10 @@ if sys.version_info >= (3, 8):
|
||||
|
||||
else:
|
||||
def parse_qs(
|
||||
qs: Optional[AnyStr], keep_blank_values: bool = ..., strict_parsing: bool = ..., encoding: str = ..., errors: str = ...,
|
||||
qs: Optional[AnyStr], keep_blank_values: bool = ..., strict_parsing: bool = ..., encoding: str = ..., errors: str = ...
|
||||
) -> Dict[AnyStr, List[AnyStr]]: ...
|
||||
def parse_qsl(
|
||||
qs: Optional[AnyStr], keep_blank_values: bool = ..., strict_parsing: bool = ..., encoding: str = ..., errors: str = ...,
|
||||
qs: Optional[AnyStr], keep_blank_values: bool = ..., strict_parsing: bool = ..., encoding: str = ..., errors: str = ...
|
||||
) -> List[Tuple[AnyStr, AnyStr]]: ...
|
||||
|
||||
@overload
|
||||
|
||||
@@ -118,7 +118,7 @@ class HTTPPasswordMgrWithDefaultRealm(HTTPPasswordMgr):
|
||||
|
||||
class HTTPPasswordMgrWithPriorAuth(HTTPPasswordMgrWithDefaultRealm):
|
||||
def add_password(
|
||||
self, realm: Optional[str], uri: Union[str, Sequence[str]], user: str, passwd: str, is_authenticated: bool = ...,
|
||||
self, realm: Optional[str], uri: Union[str, Sequence[str]], user: str, passwd: str, is_authenticated: bool = ...
|
||||
) -> None: ...
|
||||
def update_authenticated(self, uri: Union[str, Sequence[str]], is_authenticated: bool = ...) -> None: ...
|
||||
def is_authenticated(self, authuri: str) -> bool: ...
|
||||
|
||||
2
third_party/2/concurrent/futures/_base.pyi
vendored
2
third_party/2/concurrent/futures/_base.pyi
vendored
@@ -52,7 +52,7 @@ class Executor:
|
||||
self, func: Callable[..., _T], *iterables: Iterable[Any], timeout: Optional[float] = ..., chunksize: int = ...
|
||||
) -> Iterator[_T]: ...
|
||||
else:
|
||||
def map(self, func: Callable[..., _T], *iterables: Iterable[Any], timeout: Optional[float] = ...,) -> Iterator[_T]: ...
|
||||
def map(self, func: Callable[..., _T], *iterables: Iterable[Any], timeout: Optional[float] = ...) -> Iterator[_T]: ...
|
||||
def shutdown(self, wait: bool = ...) -> None: ...
|
||||
def __enter__(self: _T) -> _T: ...
|
||||
def __exit__(self, exc_type: Any, exc_val: Any, exc_tb: Any) -> Optional[bool]: ...
|
||||
|
||||
4
third_party/2/pathlib2.pyi
vendored
4
third_party/2/pathlib2.pyi
vendored
@@ -100,7 +100,7 @@ class Path(PurePath):
|
||||
# Unbuffered binary mode: returns a FileIO
|
||||
@overload
|
||||
def open(
|
||||
self, mode: OpenBinaryMode, buffering: Literal[0], encoding: None = ..., errors: None = ..., newline: None = ...,
|
||||
self, mode: OpenBinaryMode, buffering: Literal[0], encoding: None = ..., errors: None = ..., newline: None = ...
|
||||
) -> FileIO: ...
|
||||
# Buffering is on: return BufferedRandom, BufferedReader, or BufferedWriter
|
||||
@overload
|
||||
@@ -133,7 +133,7 @@ class Path(PurePath):
|
||||
# Buffering cannot be determined: fall back to BinaryIO
|
||||
@overload
|
||||
def open(
|
||||
self, mode: OpenBinaryMode, buffering: int, encoding: None = ..., errors: None = ..., newline: None = ...,
|
||||
self, mode: OpenBinaryMode, buffering: int, encoding: None = ..., errors: None = ..., newline: None = ...
|
||||
) -> BinaryIO: ...
|
||||
# Fallback if mode is not specified
|
||||
@overload
|
||||
|
||||
2
third_party/2and3/atomicwrites/__init__.pyi
vendored
2
third_party/2and3/atomicwrites/__init__.pyi
vendored
@@ -13,4 +13,4 @@ class AtomicWriter(object):
|
||||
def commit(self, f: IO[Any]) -> None: ...
|
||||
def rollback(self, f: IO[Any]) -> None: ...
|
||||
|
||||
def atomic_write(path: AnyPath, writer_cls: Type[AtomicWriter] = ..., **cls_kwargs: object,) -> ContextManager[IO[Any]]: ...
|
||||
def atomic_write(path: AnyPath, writer_cls: Type[AtomicWriter] = ..., **cls_kwargs: object) -> ContextManager[IO[Any]]: ...
|
||||
|
||||
2
third_party/2and3/attr/__init__.pyi
vendored
2
third_party/2and3/attr/__init__.pyi
vendored
@@ -37,7 +37,7 @@ NOTHING: object
|
||||
@overload
|
||||
def Factory(factory: Callable[[], _T]) -> _T: ...
|
||||
@overload
|
||||
def Factory(factory: Union[Callable[[Any], _T], Callable[[], _T]], takes_self: bool = ...,) -> _T: ...
|
||||
def Factory(factory: Union[Callable[[Any], _T], Callable[[], _T]], takes_self: bool = ...) -> _T: ...
|
||||
|
||||
class Attribute(Generic[_T]):
|
||||
name: str
|
||||
|
||||
6
third_party/2and3/attr/validators.pyi
vendored
6
third_party/2and3/attr/validators.pyi
vendored
@@ -43,12 +43,12 @@ def optional(validator: Union[_ValidatorType[_T], List[_ValidatorType[_T]]]) ->
|
||||
def in_(options: Container[_T]) -> _ValidatorType[_T]: ...
|
||||
def and_(*validators: _ValidatorType[_T]) -> _ValidatorType[_T]: ...
|
||||
def matches_re(
|
||||
regex: AnyStr, flags: int = ..., func: Optional[Callable[[AnyStr, AnyStr, int], Optional[Match[AnyStr]]]] = ...,
|
||||
regex: AnyStr, flags: int = ..., func: Optional[Callable[[AnyStr, AnyStr, int], Optional[Match[AnyStr]]]] = ...
|
||||
) -> _ValidatorType[AnyStr]: ...
|
||||
def deep_iterable(
|
||||
member_validator: _ValidatorType[_T], iterable_validator: Optional[_ValidatorType[_I]] = ...,
|
||||
member_validator: _ValidatorType[_T], iterable_validator: Optional[_ValidatorType[_I]] = ...
|
||||
) -> _ValidatorType[_I]: ...
|
||||
def deep_mapping(
|
||||
key_validator: _ValidatorType[_K], value_validator: _ValidatorType[_V], mapping_validator: Optional[_ValidatorType[_M]] = ...,
|
||||
key_validator: _ValidatorType[_K], value_validator: _ValidatorType[_V], mapping_validator: Optional[_ValidatorType[_M]] = ...
|
||||
) -> _ValidatorType[_M]: ...
|
||||
def is_callable() -> _ValidatorType[_T]: ...
|
||||
|
||||
2
third_party/2and3/bleach/__init__.pyi
vendored
2
third_party/2and3/bleach/__init__.pyi
vendored
@@ -23,5 +23,5 @@ def clean(
|
||||
strip_comments: bool = ...,
|
||||
) -> Text: ...
|
||||
def linkify(
|
||||
text: Text, callbacks: Iterable[_Callback] = ..., skip_tags: Optional[Container[Text]] = ..., parse_email: bool = ...,
|
||||
text: Text, callbacks: Iterable[_Callback] = ..., skip_tags: Optional[Container[Text]] = ..., parse_email: bool = ...
|
||||
) -> Text: ...
|
||||
|
||||
30
third_party/2and3/boto/utils.pyi
vendored
30
third_party/2and3/boto/utils.pyi
vendored
@@ -64,22 +64,22 @@ def canonical_string(
|
||||
provider: Optional[_Provider] = ...,
|
||||
) -> str: ...
|
||||
def merge_meta(
|
||||
headers: Mapping[str, str], metadata: Mapping[str, str], provider: Optional[_Provider] = ...,
|
||||
headers: Mapping[str, str], metadata: Mapping[str, str], provider: Optional[_Provider] = ...
|
||||
) -> Mapping[str, str]: ...
|
||||
def get_aws_metadata(headers: Mapping[str, str], provider: Optional[_Provider] = ...,) -> Mapping[str, str]: ...
|
||||
def retry_url(url: str, retry_on_404: bool = ..., num_retries: int = ..., timeout: Optional[int] = ...,) -> str: ...
|
||||
def get_aws_metadata(headers: Mapping[str, str], provider: Optional[_Provider] = ...) -> Mapping[str, str]: ...
|
||||
def retry_url(url: str, retry_on_404: bool = ..., num_retries: int = ..., timeout: Optional[int] = ...) -> str: ...
|
||||
|
||||
class LazyLoadMetadata(Dict[_KT, _VT]):
|
||||
def __init__(self, url: str, num_retries: int, timeout: Optional[int] = ...,) -> None: ...
|
||||
def __init__(self, url: str, num_retries: int, timeout: Optional[int] = ...) -> None: ...
|
||||
|
||||
def get_instance_metadata(
|
||||
version: str = ..., url: str = ..., data: str = ..., timeout: Optional[int] = ..., num_retries: int = ...,
|
||||
version: str = ..., url: str = ..., data: str = ..., timeout: Optional[int] = ..., num_retries: int = ...
|
||||
) -> Optional[LazyLoadMetadata[Any, Any]]: ...
|
||||
def get_instance_identity(
|
||||
version: str = ..., url: str = ..., timeout: Optional[int] = ..., num_retries: int = ...,
|
||||
version: str = ..., url: str = ..., timeout: Optional[int] = ..., num_retries: int = ...
|
||||
) -> Optional[Mapping[str, Any]]: ...
|
||||
def get_instance_userdata(
|
||||
version: str = ..., sep: Optional[str] = ..., url: str = ..., timeout: Optional[int] = ..., num_retries: int = ...,
|
||||
version: str = ..., sep: Optional[str] = ..., url: str = ..., timeout: Optional[int] = ..., num_retries: int = ...
|
||||
) -> Mapping[str, str]: ...
|
||||
|
||||
ISO8601: str
|
||||
@@ -93,7 +93,7 @@ def parse_ts(ts: str) -> datetime.datetime: ...
|
||||
def find_class(module_name: str, class_name: Optional[str] = ...) -> Optional[Type[Any]]: ...
|
||||
def update_dme(username: str, password: str, dme_id: str, ip_address: str) -> str: ...
|
||||
def fetch_file(
|
||||
uri: str, file: Optional[IO[str]] = ..., username: Optional[str] = ..., password: Optional[str] = ...,
|
||||
uri: str, file: Optional[IO[str]] = ..., username: Optional[str] = ..., password: Optional[str] = ...
|
||||
) -> Optional[IO[str]]: ...
|
||||
|
||||
class ShellCommand:
|
||||
@@ -103,7 +103,7 @@ class ShellCommand:
|
||||
wait: bool
|
||||
fail_fast: bool
|
||||
def __init__(
|
||||
self, command: subprocess._CMD, wait: bool = ..., fail_fast: bool = ..., cwd: Optional[subprocess._TXT] = ...,
|
||||
self, command: subprocess._CMD, wait: bool = ..., fail_fast: bool = ..., cwd: Optional[subprocess._TXT] = ...
|
||||
) -> None: ...
|
||||
process: subprocess.Popen[Any]
|
||||
def run(self, cwd: Optional[subprocess._CMD] = ...) -> Optional[int]: ...
|
||||
@@ -117,7 +117,7 @@ class AuthSMTPHandler(logging.handlers.SMTPHandler):
|
||||
username: str
|
||||
password: str
|
||||
def __init__(
|
||||
self, mailhost: str, username: str, password: str, fromaddr: str, toaddrs: Sequence[str], subject: str,
|
||||
self, mailhost: str, username: str, password: str, fromaddr: str, toaddrs: Sequence[str], subject: str
|
||||
) -> None: ...
|
||||
|
||||
class LRUCache(Dict[_KT, _VT]):
|
||||
@@ -139,7 +139,7 @@ _str = str
|
||||
class Password:
|
||||
hashfunc: Callable[[bytes], _HashType]
|
||||
str: Optional[_str]
|
||||
def __init__(self, str: Optional[_str] = ..., hashfunc: Optional[Callable[[bytes], _HashType]] = ...,) -> None: ...
|
||||
def __init__(self, str: Optional[_str] = ..., hashfunc: Optional[Callable[[bytes], _HashType]] = ...) -> None: ...
|
||||
def set(self, value: Union[bytes, _str]) -> None: ...
|
||||
def __eq__(self, other: Any) -> bool: ...
|
||||
def __len__(self) -> int: ...
|
||||
@@ -156,19 +156,19 @@ def get_utf8_value(value: str) -> bytes: ...
|
||||
def mklist(value: Any) -> List[Any]: ...
|
||||
def pythonize_name(name: str) -> str: ...
|
||||
def write_mime_multipart(
|
||||
content: List[Tuple[str, str]], compress: bool = ..., deftype: str = ..., delimiter: str = ...,
|
||||
content: List[Tuple[str, str]], compress: bool = ..., deftype: str = ..., delimiter: str = ...
|
||||
) -> str: ...
|
||||
def guess_mime_type(content: str, deftype: str) -> str: ...
|
||||
def compute_md5(fp: IO[Any], buf_size: int = ..., size: Optional[int] = ...,) -> Tuple[str, str, int]: ...
|
||||
def compute_md5(fp: IO[Any], buf_size: int = ..., size: Optional[int] = ...) -> Tuple[str, str, int]: ...
|
||||
def compute_hash(
|
||||
fp: IO[Any], buf_size: int = ..., size: Optional[int] = ..., hash_algorithm: Any = ...,
|
||||
fp: IO[Any], buf_size: int = ..., size: Optional[int] = ..., hash_algorithm: Any = ...
|
||||
) -> Tuple[str, str, int]: ...
|
||||
def find_matching_headers(name: str, headers: Mapping[str, Optional[str]]) -> List[str]: ...
|
||||
def merge_headers_by_name(name: str, headers: Mapping[str, Optional[str]]) -> str: ...
|
||||
|
||||
class RequestHook:
|
||||
def handle_request_data(
|
||||
self, request: boto.connection.HTTPRequest, response: boto.connection.HTTPResponse, error: bool = ...,
|
||||
self, request: boto.connection.HTTPRequest, response: boto.connection.HTTPResponse, error: bool = ...
|
||||
) -> Any: ...
|
||||
|
||||
def host_is_ipv6(hostname: str) -> bool: ...
|
||||
|
||||
6
third_party/2and3/click/core.pyi
vendored
6
third_party/2and3/click/core.pyi
vendored
@@ -25,7 +25,7 @@ def invoke_param_callback(
|
||||
) -> Any: ...
|
||||
def augment_usage_errors(ctx: Context, param: Optional[Parameter] = ...) -> ContextManager[None]: ...
|
||||
def iter_params_for_processing(
|
||||
invocation_order: Sequence[Parameter], declaration_order: Iterable[Parameter],
|
||||
invocation_order: Sequence[Parameter], declaration_order: Iterable[Parameter]
|
||||
) -> Iterable[Parameter]: ...
|
||||
|
||||
class Context:
|
||||
@@ -188,10 +188,10 @@ class _ParamType:
|
||||
name: str
|
||||
is_composite: bool
|
||||
envvar_list_splitter: Optional[str]
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...,) -> Any: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...) -> Any: ...
|
||||
def get_metavar(self, param: Parameter) -> str: ...
|
||||
def get_missing_message(self, param: Parameter) -> str: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context],) -> Any: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context]) -> Any: ...
|
||||
def split_envvar_value(self, rv: str) -> List[str]: ...
|
||||
def fail(self, message: str, param: Optional[Parameter] = ..., ctx: Optional[Context] = ...) -> NoReturn: ...
|
||||
|
||||
|
||||
11
third_party/2and3/click/formatting.pyi
vendored
11
third_party/2and3/click/formatting.pyi
vendored
@@ -13,15 +13,20 @@ class HelpFormatter:
|
||||
width: Optional[int]
|
||||
current_indent: int
|
||||
buffer: List[str]
|
||||
def __init__(self, indent_increment: int = ..., width: Optional[int] = ..., max_width: Optional[int] = ...,) -> None: ...
|
||||
def __init__(self, indent_increment: int = ..., width: Optional[int] = ..., max_width: Optional[int] = ...) -> None: ...
|
||||
def write(self, string: str) -> None: ...
|
||||
def indent(self) -> None: ...
|
||||
def dedent(self) -> None: ...
|
||||
def write_usage(self, prog: str, args: str = ..., prefix: str = ...,): ...
|
||||
def write_usage(
|
||||
self,
|
||||
prog: str,
|
||||
args: str = ...,
|
||||
prefix: str = ...,
|
||||
): ...
|
||||
def write_heading(self, heading: str) -> None: ...
|
||||
def write_paragraph(self) -> None: ...
|
||||
def write_text(self, text: str) -> None: ...
|
||||
def write_dl(self, rows: Iterable[Iterable[str]], col_max: int = ..., col_spacing: int = ...,) -> None: ...
|
||||
def write_dl(self, rows: Iterable[Iterable[str]], col_max: int = ..., col_spacing: int = ...) -> None: ...
|
||||
def section(self, name) -> ContextManager[None]: ...
|
||||
def indentation(self) -> ContextManager[None]: ...
|
||||
def getvalue(self) -> str: ...
|
||||
|
||||
6
third_party/2and3/click/termui.pyi
vendored
6
third_party/2and3/click/termui.pyi
vendored
@@ -4,7 +4,7 @@ from click._termui_impl import ProgressBar as _ProgressBar
|
||||
from click.core import _ConvertibleType
|
||||
|
||||
def hidden_prompt_func(prompt: str) -> str: ...
|
||||
def _build_prompt(text: str, suffix: str, show_default: bool = ..., default: Optional[str] = ...,) -> str: ...
|
||||
def _build_prompt(text: str, suffix: str, show_default: bool = ..., default: Optional[str] = ...) -> str: ...
|
||||
def prompt(
|
||||
text: str,
|
||||
default: Optional[str] = ...,
|
||||
@@ -18,11 +18,11 @@ def prompt(
|
||||
show_choices: bool = ...,
|
||||
) -> Any: ...
|
||||
def confirm(
|
||||
text: str, default: bool = ..., abort: bool = ..., prompt_suffix: str = ..., show_default: bool = ..., err: bool = ...,
|
||||
text: str, default: bool = ..., abort: bool = ..., prompt_suffix: str = ..., show_default: bool = ..., err: bool = ...
|
||||
) -> bool: ...
|
||||
def get_terminal_size() -> Tuple[int, int]: ...
|
||||
def echo_via_pager(
|
||||
text_or_generator: Union[str, Iterable[str], Callable[[], Generator[str, None, None]]], color: Optional[bool] = ...,
|
||||
text_or_generator: Union[str, Iterable[str], Callable[[], Generator[str, None, None]]], color: Optional[bool] = ...
|
||||
) -> None: ...
|
||||
|
||||
_T = TypeVar("_T")
|
||||
|
||||
2
third_party/2and3/click/testing.pyi
vendored
2
third_party/2and3/click/testing.pyi
vendored
@@ -52,7 +52,7 @@ class CliRunner:
|
||||
def get_default_prog_name(self, cli: BaseCommand) -> str: ...
|
||||
def make_env(self, overrides: Optional[Mapping[str, str]] = ...) -> Dict[str, str]: ...
|
||||
def isolation(
|
||||
self, input: Optional[Union[bytes, Text, IO[Any]]] = ..., env: Optional[Mapping[str, str]] = ..., color: bool = ...,
|
||||
self, input: Optional[Union[bytes, Text, IO[Any]]] = ..., env: Optional[Mapping[str, str]] = ..., color: bool = ...
|
||||
) -> ContextManager[BinaryIO]: ...
|
||||
def invoke(
|
||||
self,
|
||||
|
||||
40
third_party/2and3/click/types.pyi
vendored
40
third_party/2and3/click/types.pyi
vendored
@@ -5,26 +5,26 @@ from typing import IO, Any, Callable, Generic, Iterable, List, Optional, Tuple a
|
||||
from click.core import Context, Parameter, _ConvertibleType, _ParamType as ParamType
|
||||
|
||||
class BoolParamType(ParamType):
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...,) -> bool: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context],) -> bool: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...) -> bool: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context]) -> bool: ...
|
||||
|
||||
class CompositeParamType(ParamType):
|
||||
arity: int
|
||||
|
||||
class Choice(ParamType):
|
||||
choices: Iterable[str]
|
||||
def __init__(self, choices: Iterable[str], case_sensitive: bool = ...,) -> None: ...
|
||||
def __init__(self, choices: Iterable[str], case_sensitive: bool = ...) -> None: ...
|
||||
|
||||
class DateTime(ParamType):
|
||||
def __init__(self, formats: Optional[List[str]] = ...,) -> None: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context],) -> datetime.datetime: ...
|
||||
def __init__(self, formats: Optional[List[str]] = ...) -> None: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context]) -> datetime.datetime: ...
|
||||
|
||||
class FloatParamType(ParamType):
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...,) -> float: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context],) -> float: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...) -> float: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context]) -> float: ...
|
||||
|
||||
class FloatRange(FloatParamType):
|
||||
def __init__(self, min: Optional[float] = ..., max: Optional[float] = ..., clamp: bool = ...,) -> None: ...
|
||||
def __init__(self, min: Optional[float] = ..., max: Optional[float] = ..., clamp: bool = ...) -> None: ...
|
||||
|
||||
class File(ParamType):
|
||||
def __init__(
|
||||
@@ -45,12 +45,12 @@ _Func = Callable[[Optional[str]], _F]
|
||||
class FuncParamType(ParamType, Generic[_F]):
|
||||
func: _Func[_F]
|
||||
def __init__(self, func: _Func[_F]) -> None: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...,) -> _F: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context],) -> _F: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...) -> _F: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context]) -> _F: ...
|
||||
|
||||
class IntParamType(ParamType):
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...,) -> int: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context],) -> int: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...) -> int: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context]) -> int: ...
|
||||
|
||||
class IntRange(IntParamType):
|
||||
def __init__(self, min: Optional[int] = ..., max: Optional[int] = ..., clamp: bool = ...) -> None: ...
|
||||
@@ -70,24 +70,24 @@ class Path(ParamType):
|
||||
path_type: Optional[Type[_PathType]] = ...,
|
||||
) -> None: ...
|
||||
def coerce_path_result(self, rv: Union[str, bytes]) -> _PathType: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...,) -> _PathType: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context],) -> _PathType: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...) -> _PathType: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context]) -> _PathType: ...
|
||||
|
||||
class StringParamType(ParamType):
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...,) -> str: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context],) -> str: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...) -> str: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context]) -> str: ...
|
||||
|
||||
class Tuple(CompositeParamType):
|
||||
types: List[ParamType]
|
||||
def __init__(self, types: Iterable[Any]) -> None: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...,) -> Tuple: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context],) -> Tuple: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...) -> Tuple: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context]) -> Tuple: ...
|
||||
|
||||
class UnprocessedParamType(ParamType): ...
|
||||
|
||||
class UUIDParameterType(ParamType):
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...,) -> uuid.UUID: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context],) -> uuid.UUID: ...
|
||||
def __call__(self, value: Optional[str], param: Optional[Parameter] = ..., ctx: Optional[Context] = ...) -> uuid.UUID: ...
|
||||
def convert(self, value: str, param: Optional[Parameter], ctx: Optional[Context]) -> uuid.UUID: ...
|
||||
|
||||
def convert_type(ty: Optional[_ConvertibleType], default: Optional[Any] = ...) -> ParamType: ...
|
||||
|
||||
|
||||
2
third_party/2and3/click/utils.pyi
vendored
2
third_party/2and3/click/utils.pyi
vendored
@@ -31,7 +31,7 @@ class KeepOpenFile(Generic[AnyStr]):
|
||||
def __iter__(self) -> Iterator[AnyStr]: ...
|
||||
|
||||
def echo(
|
||||
message: object = ..., file: Optional[IO[Text]] = ..., nl: bool = ..., err: bool = ..., color: Optional[bool] = ...,
|
||||
message: object = ..., file: Optional[IO[Text]] = ..., nl: bool = ..., err: bool = ..., color: Optional[bool] = ...
|
||||
) -> None: ...
|
||||
def get_binary_stream(name: str) -> IO[bytes]: ...
|
||||
def get_text_stream(name: str, encoding: Optional[str] = ..., errors: str = ...) -> IO[str]: ...
|
||||
|
||||
4
third_party/2and3/deprecated/classic.pyi
vendored
4
third_party/2and3/deprecated/classic.pyi
vendored
@@ -8,7 +8,7 @@ class ClassicAdapter:
|
||||
action: Optional[str]
|
||||
category: Type[DeprecationWarning]
|
||||
def __init__(
|
||||
self, reason: str = ..., version: str = ..., action: Optional[str] = ..., category: Type[DeprecationWarning] = ...,
|
||||
self, reason: str = ..., version: str = ..., action: Optional[str] = ..., category: Type[DeprecationWarning] = ...
|
||||
) -> None: ...
|
||||
def get_deprecated_msg(self, wrapped: Callable[..., Any], instance: object) -> str: ...
|
||||
def __call__(self, wrapped: _F) -> Callable[[_F], _F]: ...
|
||||
@@ -17,5 +17,5 @@ class ClassicAdapter:
|
||||
def deprecated(__wrapped: _F) -> _F: ...
|
||||
@overload
|
||||
def deprecated(
|
||||
reason: str = ..., *, version: str = ..., action: Optional[str] = ..., category: Optional[Type[DeprecationWarning]] = ...,
|
||||
reason: str = ..., *, version: str = ..., action: Optional[str] = ..., category: Optional[Type[DeprecationWarning]] = ...
|
||||
) -> Callable[[_F], _F]: ...
|
||||
|
||||
2
third_party/2and3/deprecated/sphinx.pyi
vendored
2
third_party/2and3/deprecated/sphinx.pyi
vendored
@@ -27,5 +27,5 @@ def versionchanged(reason: str = ..., version: str = ...) -> Callable[[_F], _F]:
|
||||
def deprecated(__wrapped: _F) -> _F: ...
|
||||
@overload
|
||||
def deprecated(
|
||||
reason: str = ..., *, version: str = ..., action: Optional[str] = ..., category: Optional[Type[DeprecationWarning]] = ...,
|
||||
reason: str = ..., *, version: str = ..., action: Optional[str] = ..., category: Optional[Type[DeprecationWarning]] = ...
|
||||
) -> Callable[[_F], _F]: ...
|
||||
|
||||
8
third_party/2and3/flask/app.pyi
vendored
8
third_party/2and3/flask/app.pyi
vendored
@@ -39,13 +39,9 @@ _WSGICallable = Callable[[Dict[Text, Any], _StartResponse], Iterable[bytes]]
|
||||
_Status = Union[str, int]
|
||||
_Headers = Union[Dict[Any, Any], List[Tuple[Any, Any]]]
|
||||
_Body = Union[Text, ByteString, Dict[Text, Any], Response, _WSGICallable]
|
||||
_ViewFuncReturnType = Union[
|
||||
_Body, Tuple[_Body, _Status, _Headers], Tuple[_Body, _Status], Tuple[_Body, _Headers],
|
||||
]
|
||||
_ViewFuncReturnType = Union[_Body, Tuple[_Body, _Status, _Headers], Tuple[_Body, _Status], Tuple[_Body, _Headers]]
|
||||
|
||||
_ViewFunc = Union[
|
||||
Callable[..., NoReturn], Callable[..., _ViewFuncReturnType],
|
||||
]
|
||||
_ViewFunc = Union[Callable[..., NoReturn], Callable[..., _ViewFuncReturnType]]
|
||||
_VT = TypeVar("_VT", bound=_ViewFunc)
|
||||
|
||||
class Flask(_PackageBoundObject):
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
from google.protobuf.message import Message
|
||||
|
||||
class Empty(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
@@ -123,7 +123,7 @@ class TestAllTypesProto2(Message):
|
||||
group_uint32: int
|
||||
def __init__(self, group_int32: Optional[int] = ..., group_uint32: Optional[int] = ...) -> None: ...
|
||||
class MessageSetCorrect(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
class MessageSetCorrectExtension1(Message):
|
||||
bytes: Text
|
||||
def __init__(self, bytes: Optional[Text] = ...) -> None: ...
|
||||
|
||||
@@ -52,16 +52,16 @@ class TestMessageWithCustomOptions(Message):
|
||||
def __init__(self, field1: Optional[Text] = ..., oneof_field: Optional[int] = ...) -> None: ...
|
||||
|
||||
class CustomOptionFooRequest(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class CustomOptionFooResponse(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class CustomOptionFooClientMessage(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class CustomOptionFooServerMessage(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class DummyMessageContainingEnum(Message):
|
||||
class TestEnumType(int):
|
||||
@@ -77,25 +77,25 @@ class DummyMessageContainingEnum(Message):
|
||||
def items(cls) -> List[Tuple[bytes, DummyMessageContainingEnum.TestEnumType]]: ...
|
||||
TEST_OPTION_ENUM_TYPE1: DummyMessageContainingEnum.TestEnumType
|
||||
TEST_OPTION_ENUM_TYPE2: DummyMessageContainingEnum.TestEnumType
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class DummyMessageInvalidAsOptionType(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class CustomOptionMinIntegerValues(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class CustomOptionMaxIntegerValues(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class CustomOptionOtherValues(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class SettingRealsFromPositiveInts(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class SettingRealsFromNegativeInts(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class ComplexOptionType1(Message):
|
||||
foo: int
|
||||
@@ -141,10 +141,10 @@ class ComplexOpt6(Message):
|
||||
def __init__(self, xyzzy: Optional[int] = ...) -> None: ...
|
||||
|
||||
class VariousComplexOptions(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class AggregateMessageSet(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class AggregateMessageSetElement(Message):
|
||||
s: Text
|
||||
@@ -188,7 +188,7 @@ class NestedOptionType(Message):
|
||||
class NestedMessage(Message):
|
||||
nested_field: int
|
||||
def __init__(self, nested_field: Optional[int] = ...) -> None: ...
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class OldOptionType(Message):
|
||||
class TestEnum(int):
|
||||
@@ -224,4 +224,4 @@ class NewOptionType(Message):
|
||||
def __init__(self, value: NewOptionType.TestEnum) -> None: ...
|
||||
|
||||
class TestMessageWithRequiredEnumOption(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
@@ -3,7 +3,7 @@ from typing import Optional
|
||||
from google.protobuf.message import Message
|
||||
|
||||
class TestMessageSet(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class TestMessageSetWireFormatContainer(Message):
|
||||
@property
|
||||
|
||||
@@ -270,7 +270,7 @@ class TestDeprecatedFields(Message):
|
||||
def __init__(self, deprecated_int32: Optional[int] = ..., deprecated_int32_in_oneof: Optional[int] = ...) -> None: ...
|
||||
|
||||
class TestDeprecatedMessage(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class ForeignMessage(Message):
|
||||
c: int
|
||||
@@ -278,10 +278,10 @@ class ForeignMessage(Message):
|
||||
def __init__(self, c: Optional[int] = ..., d: Optional[int] = ...) -> None: ...
|
||||
|
||||
class TestReservedFields(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class TestAllExtensions(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class OptionalGroup_extension(Message):
|
||||
a: int
|
||||
@@ -303,13 +303,13 @@ class TestGroup(Message):
|
||||
) -> None: ...
|
||||
|
||||
class TestGroupExtension(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class TestNestedExtension(Message):
|
||||
class OptionalGroup_extension(Message):
|
||||
a: int
|
||||
def __init__(self, a: Optional[int] = ...) -> None: ...
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class TestRequired(Message):
|
||||
a: int
|
||||
@@ -415,13 +415,13 @@ class TestForeignNested(Message):
|
||||
def __init__(self, foreign_nested: Optional[TestAllTypes.NestedMessage] = ...) -> None: ...
|
||||
|
||||
class TestEmptyMessage(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class TestEmptyMessageWithExtensions(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class TestMultipleExtensionRanges(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class TestReallyLargeTagNumber(Message):
|
||||
a: int
|
||||
@@ -856,10 +856,10 @@ class TestUnpackedTypes(Message):
|
||||
) -> None: ...
|
||||
|
||||
class TestPackedExtensions(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class TestUnpackedExtensions(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class TestDynamicExtensions(Message):
|
||||
class DynamicEnumType(int):
|
||||
@@ -982,22 +982,22 @@ class TestCommentInjectionMessage(Message):
|
||||
def __init__(self, a: Optional[Text] = ...) -> None: ...
|
||||
|
||||
class FooRequest(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class FooResponse(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class FooClientMessage(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class FooServerMessage(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class BarRequest(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class BarResponse(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
class TestJsonName(Message):
|
||||
field_name1: int
|
||||
|
||||
@@ -246,4 +246,4 @@ class ForeignMessage(Message):
|
||||
def __init__(self, c: Optional[int] = ...) -> None: ...
|
||||
|
||||
class TestEmptyMessage(Message):
|
||||
def __init__(self,) -> None: ...
|
||||
def __init__(self) -> None: ...
|
||||
|
||||
2
third_party/2and3/jinja2/loaders.pyi
vendored
2
third_party/2and3/jinja2/loaders.pyi
vendored
@@ -47,7 +47,7 @@ class FunctionLoader(BaseLoader):
|
||||
load_func: Any
|
||||
def __init__(self, load_func) -> None: ...
|
||||
def get_source(
|
||||
self, environment: Environment, template: Text,
|
||||
self, environment: Environment, template: Text
|
||||
) -> Tuple[Text, Optional[Text], Optional[Callable[..., Any]]]: ...
|
||||
|
||||
class PrefixLoader(BaseLoader):
|
||||
|
||||
4
third_party/2and3/termcolor.pyi
vendored
4
third_party/2and3/termcolor.pyi
vendored
@@ -2,8 +2,8 @@
|
||||
from typing import Any, Iterable, Optional, Text
|
||||
|
||||
def colored(
|
||||
text: Text, color: Optional[Text] = ..., on_color: Optional[Text] = ..., attrs: Optional[Iterable[Text]] = ...,
|
||||
text: Text, color: Optional[Text] = ..., on_color: Optional[Text] = ..., attrs: Optional[Iterable[Text]] = ...
|
||||
) -> Text: ...
|
||||
def cprint(
|
||||
text: Text, color: Optional[Text] = ..., on_color: Optional[Text] = ..., attrs: Optional[Iterable[Text]] = ..., **kwargs: Any,
|
||||
text: Text, color: Optional[Text] = ..., on_color: Optional[Text] = ..., attrs: Optional[Iterable[Text]] = ..., **kwargs: Any
|
||||
) -> None: ...
|
||||
|
||||
6
third_party/2and3/ujson.pyi
vendored
6
third_party/2and3/ujson.pyi
vendored
@@ -32,6 +32,6 @@ def dump(
|
||||
sort_keys: bool = ...,
|
||||
indent: int = ...,
|
||||
) -> None: ...
|
||||
def decode(s: AnyStr, precise_float: bool = ...,) -> Any: ...
|
||||
def loads(s: AnyStr, precise_float: bool = ...,) -> Any: ...
|
||||
def load(fp: IO[AnyStr], precise_float: bool = ...,) -> Any: ...
|
||||
def decode(s: AnyStr, precise_float: bool = ...) -> Any: ...
|
||||
def loads(s: AnyStr, precise_float: bool = ...) -> Any: ...
|
||||
def load(fp: IO[AnyStr], precise_float: bool = ...) -> Any: ...
|
||||
|
||||
@@ -21,7 +21,7 @@ class HeaderRewriterFix(object):
|
||||
remove_headers: Set[Text]
|
||||
add_headers: List[Text]
|
||||
def __init__(
|
||||
self, app: WSGIApplication, remove_headers: Optional[Iterable[Text]] = ..., add_headers: Optional[Iterable[Text]] = ...,
|
||||
self, app: WSGIApplication, remove_headers: Optional[Iterable[Text]] = ..., add_headers: Optional[Iterable[Text]] = ...
|
||||
) -> None: ...
|
||||
def __call__(self, environ: WSGIEnvironment, start_response: StartResponse) -> Iterable[bytes]: ...
|
||||
|
||||
|
||||
5
third_party/2and3/werkzeug/exceptions.pyi
vendored
5
third_party/2and3/werkzeug/exceptions.pyi
vendored
@@ -148,10 +148,7 @@ class UnavailableForLegalReasons(HTTPException):
|
||||
|
||||
class InternalServerError(HTTPException):
|
||||
def __init__(
|
||||
self,
|
||||
description: Optional[Text] = ...,
|
||||
response: Optional[Response] = ...,
|
||||
original_exception: Optional[Exception] = ...,
|
||||
self, description: Optional[Text] = ..., response: Optional[Response] = ..., original_exception: Optional[Exception] = ...
|
||||
) -> None: ...
|
||||
code: int
|
||||
description: Text
|
||||
|
||||
10
third_party/2and3/werkzeug/formparser.pyi
vendored
10
third_party/2and3/werkzeug/formparser.pyi
vendored
@@ -25,11 +25,11 @@ _F = TypeVar("_F", bound=Callable[..., Any])
|
||||
|
||||
class _StreamFactory(Protocol):
|
||||
def __call__(
|
||||
self, total_content_length: Optional[int], filename: str, content_type: str, content_length: Optional[int] = ...,
|
||||
self, total_content_length: Optional[int], filename: str, content_type: str, content_length: Optional[int] = ...
|
||||
) -> IO[bytes]: ...
|
||||
|
||||
def default_stream_factory(
|
||||
total_content_length: Optional[int], filename: str, content_type: str, content_length: Optional[int] = ...,
|
||||
total_content_length: Optional[int], filename: str, content_type: str, content_length: Optional[int] = ...
|
||||
) -> IO[bytes]: ...
|
||||
def parse_form_data(
|
||||
environ: WSGIEnvironment,
|
||||
@@ -64,7 +64,7 @@ class FormDataParser(object):
|
||||
def get_parse_func(self, mimetype: str, options: Any) -> Optional[_ParseFunc]: ...
|
||||
def parse_from_environ(self, environ: WSGIEnvironment) -> Tuple[IO[bytes], _Dict, _Dict]: ...
|
||||
def parse(
|
||||
self, stream: IO[bytes], mimetype: Text, content_length: Optional[int], options: Optional[Mapping[str, str]] = ...,
|
||||
self, stream: IO[bytes], mimetype: Text, content_length: Optional[int], options: Optional[Mapping[str, str]] = ...
|
||||
) -> Tuple[IO[bytes], _Dict, _Dict]: ...
|
||||
parse_functions: Dict[Text, _ParseFunc]
|
||||
|
||||
@@ -91,12 +91,12 @@ class MultiPartParser(object):
|
||||
def get_part_encoding(self, headers: Mapping[str, str]) -> Optional[str]: ...
|
||||
def get_part_charset(self, headers: Mapping[str, str]) -> Text: ...
|
||||
def start_file_streaming(
|
||||
self, filename: Union[Text, bytes], headers: Mapping[str, str], total_content_length: Optional[int],
|
||||
self, filename: Union[Text, bytes], headers: Mapping[str, str], total_content_length: Optional[int]
|
||||
) -> Tuple[Text, IO[bytes]]: ...
|
||||
def in_memory_threshold_reached(self, bytes: Any) -> NoReturn: ...
|
||||
def validate_boundary(self, boundary: Optional[str]) -> None: ...
|
||||
def parse_lines(
|
||||
self, file: Any, boundary: bytes, content_length: int, cap_at_buffer: bool = ...,
|
||||
self, file: Any, boundary: bytes, content_length: int, cap_at_buffer: bool = ...
|
||||
) -> Generator[Tuple[str, Any], None, None]: ...
|
||||
def parse_parts(self, file: Any, boundary: bytes, content_length: int) -> Generator[Tuple[str, Any], None, None]: ...
|
||||
def parse(self, file: Any, boundary: bytes, content_length: int) -> Tuple[_Dict, _Dict]: ...
|
||||
|
||||
@@ -8,7 +8,7 @@ class ProxyMiddleware(object):
|
||||
app: WSGIApplication
|
||||
targets: Dict[Text, _MutableOpts]
|
||||
def __init__(
|
||||
self, app: WSGIApplication, targets: Mapping[Text, _MutableOpts], chunk_size: int = ..., timeout: int = ...,
|
||||
self, app: WSGIApplication, targets: Mapping[Text, _MutableOpts], chunk_size: int = ..., timeout: int = ...
|
||||
) -> None: ...
|
||||
def proxy_to(self, opts: _Opts, path: Text, prefix: Text) -> WSGIApplication: ...
|
||||
def __call__(self, environ: WSGIEnvironment, start_response: StartResponse) -> Iterable[bytes]: ...
|
||||
|
||||
@@ -55,7 +55,7 @@ class LintMiddleware(object):
|
||||
def __init__(self, app: WSGIApplication) -> None: ...
|
||||
def check_environ(self, environ: WSGIEnvironment) -> None: ...
|
||||
def check_start_response(
|
||||
self, status: str, headers: List[Tuple[str, str]], exc_info: Optional[Tuple[Any, ...]],
|
||||
self, status: str, headers: List[Tuple[str, str]], exc_info: Optional[Tuple[Any, ...]]
|
||||
) -> Tuple[int, Headers]: ...
|
||||
def check_headers(self, headers: Mapping[str, str]) -> None: ...
|
||||
def check_iterator(self, app_iter: Iterable[bytes]) -> None: ...
|
||||
|
||||
4
third_party/3/aiofiles/base.pyi
vendored
4
third_party/3/aiofiles/base.pyi
vendored
@@ -14,7 +14,7 @@ class AiofilesContextManager(Generic[_V_co, _T_co, _T_contra]):
|
||||
def __init__(self, __coro: Coroutine[_V_co, _T_co, _T_contra]) -> None: ...
|
||||
def send(self, __value: _T_contra) -> _T_co: ...
|
||||
def throw(
|
||||
self, __typ: Type[BaseException], __val: Union[BaseException, object] = ..., tb: Optional[TracebackType] = ...,
|
||||
self, __typ: Type[BaseException], __val: Union[BaseException, object] = ..., tb: Optional[TracebackType] = ...
|
||||
) -> _T_co: ...
|
||||
def close(self) -> None: ...
|
||||
@property
|
||||
@@ -30,5 +30,5 @@ class AiofilesContextManager(Generic[_V_co, _T_co, _T_contra]):
|
||||
async def __anext__(self) -> Coroutine[_V_co, _T_co, _T_contra]: ...
|
||||
async def __aenter__(self) -> Coroutine[_V_co, _T_co, _T_contra]: ...
|
||||
async def __aexit__(
|
||||
self, exc_type: Optional[Type[BaseException]], exc_val: Optional[BaseException], exc_tb: Optional[TracebackType],
|
||||
self, exc_type: Optional[Type[BaseException]], exc_val: Optional[BaseException], exc_tb: Optional[TracebackType]
|
||||
) -> None: ...
|
||||
|
||||
10
third_party/3/freezegun/api.pyi
vendored
10
third_party/3/freezegun/api.pyi
vendored
@@ -13,14 +13,14 @@ class FrozenDateTimeFactory(object):
|
||||
def __init__(self, time_to_freeze: datetime) -> None: ...
|
||||
def __call__(self) -> datetime: ...
|
||||
def tick(self, delta: Union[float, Real, timedelta] = ...) -> None: ...
|
||||
def move_to(self, target_datetime: Optional[_Freezable],) -> None: ...
|
||||
def move_to(self, target_datetime: Optional[_Freezable]) -> None: ...
|
||||
|
||||
class StepTickTimeFactory(object):
|
||||
def __init__(self, time_to_freeze: datetime, step_width: float) -> None: ...
|
||||
def __call__(self) -> datetime: ...
|
||||
def tick(self, delta: Optional[timedelta] = ...) -> None: ...
|
||||
def update_step_width(self, step_width: float) -> None: ...
|
||||
def move_to(self, target_datetime: Optional[_Freezable],) -> None: ...
|
||||
def move_to(self, target_datetime: Optional[_Freezable]) -> None: ...
|
||||
|
||||
class _freeze_time:
|
||||
def __init__(
|
||||
@@ -38,13 +38,13 @@ class _freeze_time:
|
||||
def __call__(self, func: Callable[..., Awaitable[_T]]) -> Callable[..., Awaitable[_T]]: ...
|
||||
@overload
|
||||
def __call__(self, func: Callable[..., _T]) -> Callable[..., _T]: ...
|
||||
def __enter__(self,) -> Union[StepTickTimeFactory, TickingDateTimeFactory, FrozenDateTimeFactory]: ...
|
||||
def __enter__(self) -> Union[StepTickTimeFactory, TickingDateTimeFactory, FrozenDateTimeFactory]: ...
|
||||
def __exit__(self) -> None: ...
|
||||
def start(self,) -> Union[StepTickTimeFactory, TickingDateTimeFactory, FrozenDateTimeFactory]: ...
|
||||
def start(self) -> Union[StepTickTimeFactory, TickingDateTimeFactory, FrozenDateTimeFactory]: ...
|
||||
def stop(self) -> None: ...
|
||||
def decorate_class(self, klass: Type[_T]) -> _T: ...
|
||||
def decorate_coroutine(self, coroutine: _T) -> _T: ...
|
||||
def decorate_callable(self, func: Callable[..., _T],) -> Callable[..., _T]: ...
|
||||
def decorate_callable(self, func: Callable[..., _T]) -> Callable[..., _T]: ...
|
||||
|
||||
def freeze_time(
|
||||
time_to_freeze: Optional[Union[_Freezable, Callable[..., _Freezable], Iterator[_Freezable]]] = ...,
|
||||
|
||||
2
third_party/3/orjson.pyi
vendored
2
third_party/3/orjson.pyi
vendored
@@ -2,7 +2,7 @@ from typing import Any, Callable, Optional, Union
|
||||
|
||||
__version__: str
|
||||
|
||||
def dumps(__obj: Any, default: Optional[Callable[[Any], Any]] = ..., option: Optional[int] = ...,) -> bytes: ...
|
||||
def dumps(__obj: Any, default: Optional[Callable[[Any], Any]] = ..., option: Optional[int] = ...) -> bytes: ...
|
||||
def loads(__obj: Union[bytes, bytearray, str]) -> Any: ...
|
||||
|
||||
class JSONDecodeError(ValueError): ...
|
||||
|
||||
Reference in New Issue
Block a user