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,8 @@
from array import array
from typing import Any, Union, overload
from typing_extensions import Literal
from _typeshed import FileDescriptorLike
FASYNC: int
@@ -75,40 +77,20 @@ LOCK_RW: int
LOCK_SH: int
LOCK_UN: int
LOCK_WRITE: int
@overload
def fcntl(__fd: FileDescriptorLike, __cmd: int, __arg: int = ...) -> int: ...
@overload
def fcntl(__fd: FileDescriptorLike, __cmd: int, __arg: bytes) -> bytes: ...
@overload
def fcntl(__fd: FileDescriptorLike,
__cmd: int,
__arg: int = ...) -> int: ...
@overload
def fcntl(__fd: FileDescriptorLike,
__cmd: int,
__arg: bytes) -> bytes: ...
_ReadOnlyBuffer = bytes
_WritableBuffer = Union[bytearray, memoryview, array]
@overload
def ioctl(__fd: FileDescriptorLike,
__request: int,
__arg: int = ...,
__mutate_flag: bool = ...) -> int: ...
def ioctl(__fd: FileDescriptorLike, __request: int, __arg: int = ..., __mutate_flag: bool = ...) -> int: ...
@overload
def ioctl(__fd: FileDescriptorLike,
__request: int,
__arg: _WritableBuffer,
__mutate_flag: Literal[True] = ...) -> int: ...
def ioctl(__fd: FileDescriptorLike, __request: int, __arg: _WritableBuffer, __mutate_flag: Literal[True] = ...) -> int: ...
@overload
def ioctl(__fd: FileDescriptorLike,
__request: int,
__arg: _WritableBuffer,
__mutate_flag: Literal[False]) -> bytes: ...
def ioctl(__fd: FileDescriptorLike, __request: int, __arg: _WritableBuffer, __mutate_flag: Literal[False]) -> bytes: ...
@overload
def ioctl(__fd: FileDescriptorLike,
__request: int,
__arg: _ReadOnlyBuffer,
__mutate_flag: bool = ...) -> bytes: ...
def ioctl(__fd: FileDescriptorLike, __request: int, __arg: _ReadOnlyBuffer, __mutate_flag: bool = ...) -> bytes: ...
def flock(__fd: FileDescriptorLike, __operation: int) -> None: ...
def lockf(__fd: FileDescriptorLike,
__cmd: int,
__len: int = ...,
__start: int = ...,
__whence: int = ...) -> Any: ...
def lockf(__fd: FileDescriptorLike, __cmd: int, __len: int = ..., __start: int = ..., __whence: int = ...) -> Any: ...