Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 9 additions & 7 deletions stubs/reportlab/reportlab/lib/utils.pyi
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
import datetime
import zipimport
from _typeshed import Incomplete, SupportsItems
from builtins import _ClassInfo
from collections.abc import Generator, Iterable, MutableMapping
from os import PathLike
from time import _TimeTuple, struct_time
from types import TracebackType
from typing import AnyStr, Final, Literal, TypeVar, overload, type_check_only
from typing_extensions import TypeIs
from urllib.request import _UrlopenRet

from reportlab.lib.rltempfile import get_rl_tempdir as get_rl_tempdir, get_rl_tempfile as get_rl_tempfile
Expand All @@ -31,10 +33,10 @@ __UNSET__: Final[_UNSET_]
isPyPy: bool

def isFunction(v: object) -> bool: ...
def isMethod(v: object, mt=...) -> bool: ...
def isMethod(v: object, mt: type = ...) -> bool: ...
def isModule(v: object) -> bool: ...
def isSeq(v: object, _st=...) -> bool: ...
def isNative(v: object) -> bool: ...
def isSeq(v: object, _st: _ClassInfo = ...) -> bool: ...
def isNative(v: object) -> TypeIs[str]: ...

strTypes: tuple[type[str], type[bytes]]

Expand All @@ -43,10 +45,10 @@ def asUnicode(v: str | bytes, enc: str = "utf8") -> str: ...
def asUnicodeEx(v: str | bytes, enc: str = "utf8") -> str: ...
def asNative(v: str | bytes, enc: str = "utf8") -> str: ...
def int2Byte(i: int) -> bytes: ...
def isStr(v: object) -> bool: ...
def isBytes(v: object) -> bool: ...
def isUnicode(v: object) -> bool: ...
def isClass(v: object) -> bool: ...
def isStr(v: object) -> TypeIs[str | bytes]: ...
def isBytes(v: object) -> TypeIs[bytes]: ...
def isUnicode(v: object) -> TypeIs[str]: ...
def isClass(v: object) -> TypeIs[type]: ...
def isNonPrimitiveInstance(x: object) -> bool: ...
def instantiated(v: object) -> bool: ...
def bytestr(x: object, enc: str = "utf8") -> bytes: ...
Expand Down