mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-01-29 06:12:13 +08:00
Flake8 fixes (#2549)
* Fix over-indented continuation lines * Fix under-indented continuation lines * Fix whitespace around default operator problems * Limit line lengths * Fix inconsistent files
This commit is contained in:
committed by
Jelle Zijlstra
parent
f362cf47fa
commit
006a79220f
@@ -7,67 +7,63 @@ class JSONDecodeError(ValueError):
|
||||
def load(self, fp: IO[str]) -> Any: ...
|
||||
|
||||
def dumps(obj: Any,
|
||||
skipkeys: bool = ...,
|
||||
ensure_ascii: bool = ...,
|
||||
check_circular: bool = ...,
|
||||
allow_nan: bool = ...,
|
||||
cls: Any = ...,
|
||||
indent: Optional[int] = ...,
|
||||
separators: Optional[Tuple[str, str]] = ...,
|
||||
encoding: str = ...,
|
||||
default: Optional[Callable[[Any], Any]] = ...,
|
||||
sort_keys: bool = ...,
|
||||
**kwds: Any) -> str: ...
|
||||
skipkeys: bool = ...,
|
||||
ensure_ascii: bool = ...,
|
||||
check_circular: bool = ...,
|
||||
allow_nan: bool = ...,
|
||||
cls: Any = ...,
|
||||
indent: Optional[int] = ...,
|
||||
separators: Optional[Tuple[str, str]] = ...,
|
||||
encoding: str = ...,
|
||||
default: Optional[Callable[[Any], Any]] = ...,
|
||||
sort_keys: bool = ...,
|
||||
**kwds: Any) -> str: ...
|
||||
|
||||
def dump(obj: Any,
|
||||
fp: Union[IO[str], IO[Text]],
|
||||
skipkeys: bool = ...,
|
||||
ensure_ascii: bool = ...,
|
||||
check_circular: bool = ...,
|
||||
allow_nan: bool = ...,
|
||||
cls: Any = ...,
|
||||
indent: Optional[int] = ...,
|
||||
separators: Optional[Tuple[str, str]] = ...,
|
||||
encoding: str = ...,
|
||||
default: Optional[Callable[[Any], Any]] = ...,
|
||||
sort_keys: bool = ...,
|
||||
**kwds: Any) -> None: ...
|
||||
fp: Union[IO[str], IO[Text]],
|
||||
skipkeys: bool = ...,
|
||||
ensure_ascii: bool = ...,
|
||||
check_circular: bool = ...,
|
||||
allow_nan: bool = ...,
|
||||
cls: Any = ...,
|
||||
indent: Optional[int] = ...,
|
||||
separators: Optional[Tuple[str, str]] = ...,
|
||||
encoding: str = ...,
|
||||
default: Optional[Callable[[Any], Any]] = ...,
|
||||
sort_keys: bool = ...,
|
||||
**kwds: Any) -> None: ...
|
||||
|
||||
def loads(s: Union[Text, bytes],
|
||||
encoding: Any = ...,
|
||||
cls: Any = ...,
|
||||
object_hook: Optional[Callable[[Dict], Any]] = ...,
|
||||
parse_float: Optional[Callable[[str], Any]] = ...,
|
||||
parse_int: Optional[Callable[[str], Any]] = ...,
|
||||
parse_constant: Optional[Callable[[str], Any]] = ...,
|
||||
object_pairs_hook: Optional[Callable[[List[Tuple[Any, Any]]], Any]] = ...,
|
||||
**kwds: Any) -> Any: ...
|
||||
encoding: Any = ...,
|
||||
cls: Any = ...,
|
||||
object_hook: Optional[Callable[[Dict], Any]] = ...,
|
||||
parse_float: Optional[Callable[[str], Any]] = ...,
|
||||
parse_int: Optional[Callable[[str], Any]] = ...,
|
||||
parse_constant: Optional[Callable[[str], Any]] = ...,
|
||||
object_pairs_hook: Optional[Callable[[List[Tuple[Any, Any]]], Any]] = ...,
|
||||
**kwds: Any) -> Any: ...
|
||||
|
||||
def load(fp: IO[str],
|
||||
encoding: Optional[str] = ...,
|
||||
cls: Any = ...,
|
||||
object_hook: Optional[Callable[[Dict], Any]] = ...,
|
||||
parse_float: Optional[Callable[[str], Any]] = ...,
|
||||
parse_int: Optional[Callable[[str], Any]] = ...,
|
||||
parse_constant: Optional[Callable[[str], Any]] = ...,
|
||||
object_pairs_hook: Optional[Callable[[List[Tuple[Any, Any]]], Any]] = ...,
|
||||
**kwds: Any) -> Any: ...
|
||||
encoding: Optional[str] = ...,
|
||||
cls: Any = ...,
|
||||
object_hook: Optional[Callable[[Dict], Any]] = ...,
|
||||
parse_float: Optional[Callable[[str], Any]] = ...,
|
||||
parse_int: Optional[Callable[[str], Any]] = ...,
|
||||
parse_constant: Optional[Callable[[str], Any]] = ...,
|
||||
object_pairs_hook: Optional[Callable[[List[Tuple[Any, Any]]], Any]] = ...,
|
||||
**kwds: Any) -> Any: ...
|
||||
|
||||
class JSONDecoder(object):
|
||||
def __init__(self,
|
||||
encoding: Union[Text, bytes] = ...,
|
||||
object_hook: Callable[..., Any] = ...,
|
||||
parse_float: Callable[[str], float] = ...,
|
||||
parse_int: Callable[[str], int] = ...,
|
||||
parse_constant: Callable[[str], Any] = ...,
|
||||
strict: bool = ...,
|
||||
object_pairs_hook: Callable[..., Any] = ...) -> None: ...
|
||||
|
||||
encoding: Union[Text, bytes] = ...,
|
||||
object_hook: Callable[..., Any] = ...,
|
||||
parse_float: Callable[[str], float] = ...,
|
||||
parse_int: Callable[[str], int] = ...,
|
||||
parse_constant: Callable[[str], Any] = ...,
|
||||
strict: bool = ...,
|
||||
object_pairs_hook: Callable[..., Any] = ...) -> None: ...
|
||||
def decode(self, s: Union[Text, bytes], _w: Any = ...) -> Any: ...
|
||||
|
||||
def raw_decode(self,
|
||||
s: Union[Text, bytes],
|
||||
idx: int = ...) -> Tuple[Any, Any]: ...
|
||||
def raw_decode(self, s: Union[Text, bytes], idx: int = ...) -> Tuple[Any, Any]: ...
|
||||
|
||||
class JSONEncoder(object):
|
||||
item_separator = ... # type: str
|
||||
@@ -80,15 +76,15 @@ class JSONEncoder(object):
|
||||
indent = ... # type: int
|
||||
|
||||
def __init__(self,
|
||||
skipkeys: bool = ...,
|
||||
ensure_ascii: bool = ...,
|
||||
check_circular: bool = ...,
|
||||
allow_nan: bool = ...,
|
||||
sort_keys: bool = ...,
|
||||
indent: int = ...,
|
||||
separators: Tuple[Union[Text, bytes], Union[Text, bytes]] = ...,
|
||||
encoding: Union[Text, bytes] = ...,
|
||||
default: Callable[..., Any] = ...) -> None: ...
|
||||
skipkeys: bool = ...,
|
||||
ensure_ascii: bool = ...,
|
||||
check_circular: bool = ...,
|
||||
allow_nan: bool = ...,
|
||||
sort_keys: bool = ...,
|
||||
indent: int = ...,
|
||||
separators: Tuple[Union[Text, bytes], Union[Text, bytes]] = ...,
|
||||
encoding: Union[Text, bytes] = ...,
|
||||
default: Callable[..., Any] = ...) -> None: ...
|
||||
|
||||
def default(self, o: Any) -> Any: ...
|
||||
|
||||
|
||||
Reference in New Issue
Block a user