mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 21:46:42 +08:00
Change imports so pytype can parse them (#394)
* Change imports so pytype can parse them relative imports -> absolute import foo.bar as baz -> equivalent "from foo ..." * fixup ...
This commit is contained in:
committed by
Matthias Kramm
parent
19135832bd
commit
d7db6221da
@@ -4,7 +4,7 @@ from typing import (
|
||||
List, Tuple, Union, Sequence, Mapping, IO, Any, Optional, AnyStr, Iterator,
|
||||
MutableMapping, NamedTuple
|
||||
)
|
||||
import os.path as path
|
||||
from os import path
|
||||
|
||||
error = OSError
|
||||
name = ... # type: str
|
||||
|
||||
@@ -5,6 +5,6 @@ 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 .scanner import JSONDecodeError
|
||||
from .decoder import JSONDecoder
|
||||
from .encoder import JSONEncoder, JSONEncoderForHTML
|
||||
from simplejson.scanner import JSONDecodeError
|
||||
from simplejson.decoder import JSONDecoder
|
||||
from simplejson.encoder import JSONEncoder, JSONEncoderForHTML
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
# NOTE: This dynamically typed stub was automatically generated by stubgen.
|
||||
|
||||
from typing import Union, Optional, Callable
|
||||
from .ElementTree import Element
|
||||
from xml.etree.ElementTree import Element
|
||||
|
||||
XINCLUDE = ... # type: str
|
||||
XINCLUDE_INCLUDE = ... # type: str
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
# NOTE: This dynamically typed stub was automatically generated by stubgen.
|
||||
|
||||
from typing import Pattern, Dict, Generator, Tuple, List, Union, TypeVar, Callable, Optional
|
||||
from .ElementTree import Element
|
||||
from xml.etree.ElementTree import Element
|
||||
|
||||
xpath_tokenizer_re = ... # type: Pattern
|
||||
|
||||
|
||||
Reference in New Issue
Block a user