mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-08-01 21:50:21 +08:00
Fixing flake8 E401, E402 errors
This commit is contained in:
+4
-4
@@ -1,10 +1,10 @@
|
||||
from typing import Any, IO
|
||||
|
||||
from simplejson.scanner import JSONDecodeError
|
||||
from simplejson.decoder import JSONDecoder
|
||||
from simplejson.encoder import JSONEncoder, JSONEncoderForHTML
|
||||
|
||||
def dumps(obj: Any, *args: Any, **kwds: Any) -> str: ...
|
||||
def dump(obj: Any, fp: IO[str], *args: Any, **kwds: Any) -> None: ...
|
||||
def loads(s: str, **kwds: Any) -> Any: ...
|
||||
def load(fp: IO[str]) -> Any: ...
|
||||
|
||||
from simplejson.scanner import JSONDecodeError
|
||||
from simplejson.decoder import JSONDecoder
|
||||
from simplejson.encoder import JSONEncoder, JSONEncoderForHTML
|
||||
|
||||
Vendored
+7
-6
@@ -2,14 +2,19 @@
|
||||
|
||||
from __future__ import print_function
|
||||
|
||||
import types
|
||||
from typing import (
|
||||
Any, AnyStr, Callable, Iterable, Mapping, Optional,
|
||||
Pattern, Tuple, TypeVar, Union, overload, ValuesView, KeysView, ItemsView
|
||||
)
|
||||
import typing
|
||||
|
||||
import unittest
|
||||
import types
|
||||
|
||||
# Exports
|
||||
from __builtin__ import unichr as unichr
|
||||
from StringIO import StringIO as StringIO, StringIO as BytesIO
|
||||
from functools import wraps as wraps
|
||||
|
||||
|
||||
_T = TypeVar('_T')
|
||||
_K = TypeVar('_K')
|
||||
@@ -62,12 +67,10 @@ def viewitems(d: Mapping[_K, _V]) -> ItemsView[_K, _V]: ...
|
||||
|
||||
def b(s: str) -> binary_type: ...
|
||||
def u(s: str) -> text_type: ...
|
||||
from __builtin__ import unichr as unichr
|
||||
int2byte = chr
|
||||
def byte2int(bs: binary_type) -> int: ...
|
||||
def indexbytes(buf: binary_type, i: int) -> int: ...
|
||||
def iterbytes(buf: binary_type) -> typing.Iterator[int]: ...
|
||||
from StringIO import StringIO as StringIO, StringIO as BytesIO
|
||||
|
||||
def assertCountEqual(self: unittest.TestCase, first: Iterable[_T], second: Iterable[_T], msg: str = ...) -> None: ...
|
||||
@overload
|
||||
@@ -82,8 +85,6 @@ def raise_from(value: BaseException, from_value: BaseException) -> None: ...
|
||||
|
||||
print_ = print
|
||||
|
||||
from functools import wraps as wraps
|
||||
|
||||
def with_metaclass(meta: type, *bases: type) -> type: ...
|
||||
def add_metaclass(metaclass: type) -> Callable[[_T], _T]: ...
|
||||
def python_2_unicode_compatible(klass: _T) -> _T: ...
|
||||
|
||||
+3
-3
@@ -7,9 +7,6 @@ from . import base
|
||||
from . import selectable
|
||||
from . import dml
|
||||
|
||||
func = functions.func # type: functions._FunctionGenerator
|
||||
modifier = functions.modifier # type: functions._FunctionGenerator
|
||||
|
||||
from .visitors import Visitable
|
||||
|
||||
from .elements import ClauseElement, ColumnElement,\
|
||||
@@ -28,6 +25,9 @@ from .selectable import Alias, Join, Select, Selectable, TableClause, \
|
||||
subquery, HasPrefixes, HasSuffixes, Exists, ScalarSelect, TextAsFrom
|
||||
from .dml import Insert, Update, Delete, UpdateBase, ValuesBase
|
||||
|
||||
func = functions.func # type: functions._FunctionGenerator
|
||||
modifier = functions.modifier # type: functions._FunctionGenerator
|
||||
|
||||
and_ = ... # type: Any
|
||||
or_ = ... # type: Any
|
||||
bindparam = ... # type: Any
|
||||
|
||||
Reference in New Issue
Block a user