Skip to content

Commit

Permalink
minor changes in rdflib stub files to make them compatible with mypy …
Browse files Browse the repository at this point in the history
…in py3 mode

and move to typshed/2and3/ directory
  • Loading branch information
manu-chroma committed Jun 27, 2017
1 parent 65e583c commit ad05e61
Show file tree
Hide file tree
Showing 15 changed files with 13 additions and 13 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
#
# NOTE: This dynamically typed stub was automatically generated by stubgen.

from typing import Any, AnyStr, Dict, Union, IO, Tuple, Iterator
from StringIO import StringIO as BytesIO
from typing import Any, AnyStr, Dict, Union, IO, Tuple, Iterator, Text
from io import StringIO as BytesIO
from rdflib.term import Node, URIRef
from rdflib.store import Store
from rdflib.namespace import NamespaceManager
Expand Down Expand Up @@ -71,8 +71,8 @@ class Graph(Node):
def absolutize(self, uri, defrag=1): ...
def serialize(self, destination: Union[str, IO[Any]]=None, format: str='', base: str=None, encoding: str=None, **args) -> Union[bytes, None]: ...
def parse(self, source: str = None, publicID: str = None,
format: Union[str, unicode] = None,
location: Union[str, unicode] = None, file: IO[Any] = None,
format: Text = None,
location: Text = None, file: IO[Any] = None,
data: str = None, **args): ...
def load(self, source, publicID=None, format=''): ...
def query(self, query_object, processor: str = '', result: str = '', initNs: Dict = None, initBindings: Dict = None, use_store_provided: bool = True, **kwargs) -> Result: ...
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
#
# NOTE: This dynamically typed stub was automatically generated by stubgen.

from typing import Any, Tuple, Union
from typing import Any, Tuple, Union, Text

class Namespace(unicode):
class Namespace(Text):
__doc__ = ... # type: Any
def __new__(cls, value): ...
@property
Expand All @@ -13,7 +13,7 @@ class Namespace(unicode):
def __getitem__(self, key, default=None): ...
def __getattr__(self, name): ...

class URIPattern(unicode):
class URIPattern(Text):
__doc__ = ... # type: Any
def __new__(cls, value): ...
def __mod__(self, *args, **kwargs): ...
Expand Down Expand Up @@ -57,4 +57,4 @@ def is_ncname(name): ...

XMLNS = ... # type: Any

def split_uri(uri: Union[str, unicode]) -> Tuple[str, str]: ...
def split_uri(uri: Text) -> Tuple[str, str]: ...
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# NOTE: This dynamically typed stub was automatically generated by stubgen.

from typing import Any
from StringIO import StringIO as BytesIO
from io import StringIO as BytesIO

class Parser:
def __init__(self): ...
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# NOTE: This dynamically typed stub was automatically generated by stubgen.

from typing import Any
from StringIO import StringIO as BytesIO
from io import StringIO as BytesIO
import collections

class Processor:
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

from typing import Any
from rdflib.events import Event
from cStringIO import StringIO as BytesIO
from io import StringIO as BytesIO

class StoreCreatedEvent(Event): ...
class TripleAddedEvent(Event): ...
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
#
# NOTE: This dynamically typed stub was automatically generated by stubgen.

from typing import Any
from typing import Any, Text

class Node: ...

class Identifier(Node, unicode):
class Identifier(Node, Text):
def __new__(cls, value): ...
def eq(self, other): ...
def neq(self, other): ...
Expand Down
File renamed without changes.

0 comments on commit ad05e61

Please sign in to comment.