apply black and isort (#4287)

* apply black and isort

* move some type ignores
This commit is contained in:
Jelle Zijlstra
2020-06-28 13:31:00 -07:00
committed by GitHub
parent fe58699ca5
commit 5d553c9584
800 changed files with 13875 additions and 10332 deletions

View File

@@ -1,6 +1,7 @@
from typing import Iterable, Callable, IO, AnyStr, Generic, Any, Union, Iterator, Optional
from _typeshed import AnyPath
import sys
from typing import IO, Any, AnyStr, Callable, Generic, Iterable, Iterator, Optional, Union
from _typeshed import AnyPath
if sys.version_info >= (3, 8):
def input(
@@ -11,6 +12,7 @@ if sys.version_info >= (3, 8):
mode: str = ...,
openhook: Callable[[AnyPath, str], IO[AnyStr]] = ...,
) -> FileInput[AnyStr]: ...
else:
def input(
files: Union[AnyPath, Iterable[AnyPath], None] = ...,
@@ -39,7 +41,7 @@ class FileInput(Iterable[AnyStr], Generic[AnyStr]):
backup: str = ...,
*,
mode: str = ...,
openhook: Callable[[AnyPath, str], IO[AnyStr]] = ...
openhook: Callable[[AnyPath, str], IO[AnyStr]] = ...,
) -> None: ...
else:
def __init__(
@@ -49,9 +51,8 @@ class FileInput(Iterable[AnyStr], Generic[AnyStr]):
backup: str = ...,
bufsize: int = ...,
mode: str = ...,
openhook: Callable[[AnyPath, str], IO[AnyStr]] = ...
openhook: Callable[[AnyPath, str], IO[AnyStr]] = ...,
) -> None: ...
def __del__(self) -> None: ...
def close(self) -> None: ...
if sys.version_info >= (3, 2):
@@ -70,7 +71,9 @@ class FileInput(Iterable[AnyStr], Generic[AnyStr]):
def isstdin(self) -> bool: ...
def hook_compressed(filename: AnyPath, mode: str) -> IO[Any]: ...
if sys.version_info >= (3, 6):
def hook_encoded(encoding: str, errors: Optional[str] = ...) -> Callable[[AnyPath, str], IO[Any]]: ...
else:
def hook_encoded(encoding: str) -> Callable[[AnyPath, str], IO[Any]]: ...