-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
add boltons #8892
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
add boltons #8892
Changes from all commits
Commits
Show all changes
68 commits
Select commit
Hold shift + click to select a range
9680e81
update gitignore
AABur a6800a3
add auto-generated stubs for boltons
AABur ede7ad0
update dictutils/FrozenDict
AABur 0d7f4ff
update dictutils/FrozenHashError
AABur d40ab5d
update dictutils/subdict
AABur 04ab8fd
update dictutils/ManyToMany
AABur 24c1590
update dictutils/OneToOne
AABur 0c90a6e
update dictutils/FastIterOrderedMultiDict
AABur 76b5e8b
update dictutils/OrderedMultiDict
AABur af3dbb9
format code
AABur f120ae7
fix linter warnings
AABur 9ee21c5
fix linter warnings
AABur b6d5968
Merge branch 'python:master' into boltons
AABur 416ba9c
Make changes to pass flake8 (#2)
amaslenn 007b6d1
Merge branch 'python:main' into boltons
AABur 2155b12
boltons: fix stubtest errors
AABur 211c8d0
remove unused allowlist entry
AlexWaygood 155c216
Merge branch 'python:main' into boltons
AABur 339528c
boltons: queueutils realised
AABur 25400e7
Merge branch 'python:main' into boltons
AABur 0d63389
boltons: type annotations updated
AABur b4e0a7d
Merge branch 'python:main' into boltons
AABur f372c6c
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] f51cdc6
boltons: fix pathutils
AABur 4efb652
Merge branch 'python:main' into boltons
AABur d0e2679
Merge branch 'python:main' into boltons
AABur dc972ad
Merge branch 'python:main' into boltons
AABur 1ebd17f
fix subtest errors
AABur 13bd8da
boltons: ecoutils - fix stubtest errors
AABur 8dd781b
boltons: annotated - cacheutils, fileutils, formatutils, statsutils, …
AABur ba7843e
Merge branch 'python:main' into boltons
AABur dc819d4
boltons(cacheutils): fix pyright errors
AABur f661197
boltons(ecoutils): fix stubtest errors
AABur d58eefa
boltons(ecoutils): fexed
AABur fff4362
Merge branch 'python:main' into boltons
AABur ed0633e
boltons: fix flake8 errors
AABur 3c35bb5
boltons: fix allowlist
AABur 6725d86
boltons: types annotated for dictutils, fileutils, gcutils, mathutils…
AABur 7d80804
boltons(ecoutils): updated
AABur bff5263
boltons: fix stubtest_allowlist
AABur a7a969c
Fiddle with stubtest allowlist
AlexWaygood 3c50398
Fix `ecotutils.getrandbits`
AlexWaygood 399716c
Merge branch 'main' into boltons
AlexWaygood e24405a
remove commented-out code and unneeded TODO
AABur 3a4de5e
Merge branch 'python:main' into boltons
AABur 7a8811f
Merge branch 'python:main' into boltons
AABur 0948b5c
boltons.debugutils updated
AABur 048783f
Merge branch 'python:main' into boltons
AABur ad6c2ab
Merge branch 'python:main' into boltons
AABur 0a5b40c
update `casheutils` and `debugutils`
AABur e044708
fix `debugutils`
AABur b63f681
update dictutils
AABur 3fe149d
fix `cacheutils` and `dictutils`
AABur cff28a5
update listutils
AABur abb2d21
update listutils
AABur 019b6a9
update tbutils and typeutils
AABur a536c53
update dictutils and tbutils
AABur 69e8767
update `setutils` and `socketutils`
AABur f48d187
boltons: update `cacheutils`
AABur ef5c948
Merge branch 'main' into boltons
AABur 9d1128c
Many fixes
JelleZijlstra 5cfc655
Merge remote-tracking branch 'upstream/main' into boltons
JelleZijlstra f60417c
black
JelleZijlstra 700ab61
stubdefaulter
JelleZijlstra f7b8936
black
JelleZijlstra c83e076
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] de2d52a
Some mypy fixes
JelleZijlstra 8479b28
stubtest fixes
JelleZijlstra File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -68,3 +68,6 @@ analyze.py | |
|
|
||
| # Mypy cache | ||
| .mypy_cache/ | ||
|
|
||
| # pyenv local python version | ||
| .python-version | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| # These names exist in __all__, but have no definition: | ||
| boltons.strutils.int_list_complement | ||
| boltons.strutils.int_list_to_int_tuples | ||
|
|
||
| # Internal compatibility aliases | ||
| boltons.cacheutils.basestring | ||
| boltons.funcutils.basestring | ||
| boltons.funcutils.inspect_formatargspec | ||
| boltons.funcutils.make_method | ||
| boltons.iterutils.basestring |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| version = "23.0.*" | ||
|
|
||
| [tool.stubtest] | ||
| ignore_missing_stub = false |
Empty file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,115 @@ | ||
| import weakref | ||
| from _typeshed import Incomplete, Self, SupportsItems, SupportsKeysAndGetItem | ||
| from collections.abc import Callable, Generator, Hashable, Iterable, Iterator, Mapping | ||
| from typing import Any, Generic, TypeVar, overload | ||
|
|
||
| _KT = TypeVar("_KT") | ||
| _VT = TypeVar("_VT") | ||
| _T = TypeVar("_T") | ||
|
|
||
| PREV: int | ||
| NEXT: int | ||
| KEY: int | ||
| VALUE: int | ||
| DEFAULT_MAX_SIZE: int | ||
|
|
||
| class LRI(dict[_KT, _VT]): | ||
| hit_count: int | ||
| miss_count: int | ||
| soft_miss_count: int | ||
| max_size: int | ||
| on_miss: Callable[[_KT], _VT] | ||
| def __init__(self, max_size: int = 128, values: Incomplete | None = None, on_miss: Incomplete | None = None) -> None: ... | ||
| def __setitem__(self, key: _KT, value: _VT) -> None: ... | ||
| def __getitem__(self, key: _KT) -> _VT: ... | ||
| @overload | ||
| def get(self, key: _KT, default: None = None) -> _VT | None: ... | ||
| @overload | ||
| def get(self, key: _KT, default: _T) -> _T | _VT: ... | ||
| def __delitem__(self, key: _KT) -> None: ... | ||
| @overload | ||
| def pop(self, key: _KT) -> _VT: ... | ||
| @overload | ||
| def pop(self, key: _KT, default: _T) -> _T | _VT: ... | ||
| def popitem(self) -> tuple[_KT, _VT]: ... | ||
| def clear(self) -> None: ... | ||
| def copy(self: Self) -> Self: ... | ||
| @overload | ||
| def setdefault(self, key: _KT, default: None = None) -> _VT: ... | ||
| @overload | ||
| def setdefault(self, key: _KT, default: _VT) -> _VT: ... | ||
| def update(self, E: SupportsKeysAndGetItem[_KT, _VT] | Iterable[tuple[_KT, _VT]], **F: _VT) -> None: ... # type: ignore[override] | ||
|
|
||
| class LRU(LRI[_KT, _VT]): | ||
| def __getitem__(self, key: _KT) -> _VT: ... | ||
|
|
||
| def make_cache_key( | ||
| args: Iterable[Hashable], | ||
| kwargs: SupportsItems[Hashable, Hashable], | ||
| typed: bool = False, | ||
| kwarg_mark: object = ..., | ||
| fasttypes: frozenset[type] = ..., | ||
| ): ... | ||
|
|
||
| class CachedFunction: | ||
| func: Incomplete | ||
| get_cache: Incomplete | ||
| scoped: Incomplete | ||
| typed: Incomplete | ||
| key_func: Incomplete | ||
| def __init__(self, func, cache, scoped: bool = True, typed: bool = False, key: Incomplete | None = None): ... | ||
| def __call__(self, *args, **kwargs): ... | ||
|
|
||
| class CachedMethod: | ||
| func: Incomplete | ||
| get_cache: Incomplete | ||
| scoped: Incomplete | ||
| typed: Incomplete | ||
| key_func: Incomplete | ||
| bound_to: Incomplete | ||
| def __init__(self, func, cache, scoped: bool = True, typed: bool = False, key: Incomplete | None = None): ... | ||
| def __get__(self, obj, objtype: Incomplete | None = None): ... | ||
| def __call__(self, *args, **kwargs): ... | ||
|
|
||
| def cached(cache: Mapping[Any, Any], scoped: bool = True, typed: bool = False, key: Incomplete | None = None): ... | ||
| def cachedmethod(cache, scoped: bool = True, typed: bool = False, key: Incomplete | None = None): ... | ||
|
|
||
| class cachedproperty(Generic[_T]): | ||
| func: Callable[[Incomplete], _T] | ||
| def __init__(self, func: Callable[[Incomplete], _T]) -> None: ... | ||
| def __get__(self, obj: _T, objtype: type | None = None): ... | ||
|
|
||
| class ThresholdCounter(Generic[_T]): | ||
| total: int | ||
| def __init__(self, threshold: float = 0.001) -> None: ... | ||
| @property | ||
| def threshold(self) -> float: ... | ||
| def add(self, key: _T) -> None: ... | ||
| def elements(self) -> Iterator[_T]: ... | ||
| def most_common(self, n: int | None = None) -> list[tuple[_T, int]]: ... | ||
| def get_common_count(self) -> int: ... | ||
| def get_uncommon_count(self) -> int: ... | ||
| def get_commonality(self) -> float: ... | ||
| def __getitem__(self, key: _T) -> int: ... | ||
| def __len__(self) -> int: ... | ||
| def __contains__(self, key: _T) -> bool: ... | ||
| def iterkeys(self) -> Iterator[_T]: ... | ||
| def keys(self) -> list[_T]: ... | ||
| def itervalues(self) -> Generator[int, None, None]: ... | ||
| def values(self) -> list[int]: ... | ||
| def iteritems(self) -> Generator[tuple[_T, int], None, None]: ... | ||
| def items(self) -> list[tuple[_T, int]]: ... | ||
| def get(self, key: _T, default: int = 0) -> int: ... | ||
| def update(self, iterable: Iterable[_T] | Mapping[_T, int], **kwargs: Iterable[_T] | Mapping[_T, int]) -> None: ... | ||
|
|
||
| class MinIDMap(Generic[_T]): | ||
| mapping: weakref.WeakKeyDictionary[_T, int] | ||
| ref_map: dict[_T, int] | ||
| free: list[int] | ||
| def __init__(self) -> None: ... | ||
| def get(self, a: _T) -> int: ... | ||
| def drop(self, a: _T) -> None: ... | ||
| def __contains__(self, a: _T) -> bool: ... | ||
| def __iter__(self) -> Iterator[_T]: ... | ||
| def __len__(self) -> int: ... | ||
| def iteritems(self) -> Iterator[tuple[_T, int]]: ... | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| from _typeshed import Incomplete | ||
| from collections.abc import Callable | ||
| from typing import Any | ||
|
|
||
| def pdb_on_signal(signalnum: int | None = None) -> None: ... | ||
| def pdb_on_exception(limit: int = 100) -> None: ... | ||
| def wrap_trace( | ||
| obj: Incomplete, hook: Callable[..., Any] = ..., which: str | None = None, events: str | None = None, label: str | None = None | ||
| ) -> Incomplete: ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| from types import ModuleType | ||
| from typing import Any | ||
|
|
||
| class DeprecatableModule(ModuleType): | ||
| def __init__(self, module: ModuleType) -> None: ... | ||
| def __getattribute__(self, name: str) -> Any: ... | ||
|
|
||
| def deprecate_module_member(mod_name: str, name: str, message: str) -> None: ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,90 @@ | ||
| from _typeshed import SupportsKeysAndGetItem | ||
| from binascii import Incomplete | ||
| from collections.abc import Generator, ItemsView, Iterable, KeysView, ValuesView | ||
| from typing import NoReturn, TypeVar | ||
| from typing_extensions import Self, TypeAlias | ||
|
|
||
| _KT = TypeVar("_KT") | ||
| _VT = TypeVar("_VT") | ||
| _T = TypeVar("_T") | ||
|
|
||
| class OrderedMultiDict(dict[_KT, _VT]): | ||
| def add(self, k: _KT, v: _VT) -> None: ... | ||
| def addlist(self, k: _KT, v: Iterable[_VT]) -> None: ... | ||
| def clear(self) -> None: ... | ||
| def copy(self) -> Self: ... | ||
| def counts(self) -> OrderedMultiDict[_KT, _VT]: ... | ||
| @classmethod | ||
| def fromkeys(cls, keys: _KT, default: _VT | None = None) -> OrderedMultiDict[_KT, _VT]: ... # type: ignore[override] | ||
| def get(self, k: _KT, default: _VT | None = None) -> OrderedMultiDict[_KT, _VT]: ... # type: ignore[override] | ||
| def getlist(self, k: _KT, default: _VT | None = ...) -> list[object]: ... | ||
| def inverted(self) -> OrderedMultiDict[_KT, _VT]: ... | ||
| def items(self, multi: bool = False) -> list[tuple[_KT, _VT]]: ... # type: ignore[override] | ||
| def iteritems(self, multi: bool = False) -> Generator[tuple[_KT, _VT], None, None]: ... | ||
| def iterkeys(self, multi: bool = False) -> Generator[_KT, None, None]: ... | ||
| def itervalues(self, multi: bool = False) -> Generator[_VT, None, None]: ... | ||
| def keys(self, multi: bool = False) -> list[_KT]: ... # type: ignore[override] | ||
| def pop(self, k: _KT, default: _VT | None = ...) -> _VT: ... # type: ignore[override] | ||
| def popall(self, k: _KT, default: _VT | None = ...) -> list[_VT]: ... | ||
| def poplast(self, k: _KT | None = ..., default: _VT | None = ...) -> _VT: ... | ||
| def setdefault(self, k: _KT, default: _VT | None = ...) -> _VT: ... | ||
| def sorted(self, key: _KT | None = None, reverse: bool = False) -> OrderedMultiDict[_KT, _VT]: ... | ||
| def sortedvalues(self, key: _KT | None = None, reverse: bool = False) -> OrderedMultiDict[_KT, _VT]: ... | ||
| def todict(self, multi: bool = False) -> dict[_KT, _VT]: ... | ||
| def update(self, E: dict[_KT, _VT] | Iterable[object], **F) -> None: ... # type: ignore[override] | ||
| def update_extend(self, E: dict[_KT, _VT] | Iterable[object], **F) -> None: ... | ||
| def values(self, multi: bool = False) -> list[_VT]: ... # type: ignore[override] | ||
| def viewitems(self) -> ItemsView[_KT, _VT]: ... | ||
| def viewkeys(self) -> KeysView[_KT]: ... | ||
| def viewvalues(self) -> ValuesView[_VT]: ... | ||
|
|
||
| OMD: TypeAlias = OrderedMultiDict[_KT, _VT] | ||
| MultiDict: TypeAlias = OrderedMultiDict[_KT, _VT] | ||
|
|
||
| class FastIterOrderedMultiDict(OrderedMultiDict[_KT, _VT]): # undocumented | ||
| def iteritems(self, multi: bool = False) -> Generator[tuple[_KT, _VT], None, None]: ... | ||
| def iterkeys(self, multi: bool = False) -> Generator[_KT, None, None]: ... | ||
|
|
||
| class OneToOne(dict[_KT, _VT]): | ||
| inv: dict[_VT, _KT] | ||
| def clear(self) -> None: ... | ||
| def copy(self) -> Self: ... | ||
| def pop(self, key: _KT, default: _VT | _T = ...) -> _VT | _T: ... | ||
| def popitem(self) -> tuple[_KT, _VT]: ... | ||
| def setdefault(self, key: _KT, default: _VT | None = None) -> _VT: ... | ||
| @classmethod | ||
| def unique(cls, *a, **kw) -> Self: ... | ||
| def update(self, dict_or_iterable, **kw) -> None: ... # type: ignore[override] | ||
|
|
||
| class ManyToMany(dict[_KT, frozenset[_VT]]): | ||
| data: dict[_KT, set[_VT]] | ||
| inv: dict[_VT, set[_KT]] | ||
| # def __contains__(self, key: _KT): ... | ||
| def __delitem__(self, key: _KT) -> None: ... | ||
| def __eq__(self, other): ... | ||
| def __getitem__(self, key: _KT): ... | ||
| def __init__(self, items: Iterable[Incomplete] | None = None) -> None: ... | ||
| def __iter__(self): ... | ||
| def __len__(self): ... | ||
| def __setitem__(self, key: _KT, vals: Iterable[_VT]) -> None: ... | ||
| def add(self, key: _KT, val: _VT) -> None: ... | ||
| def get(self, key: _KT, default: frozenset[_VT] = ...) -> frozenset[_VT]: ... # type: ignore[override] | ||
| def iteritems(self) -> Generator[tuple[_KT, _VT], None, None]: ... | ||
| def keys(self): ... | ||
| def remove(self, key: _KT, val: _VT) -> None: ... | ||
| def replace(self, key: _KT, newkey: _KT) -> None: ... | ||
| def update(self, iterable: ManyToMany[_KT, _VT] | SupportsKeysAndGetItem[_KT, _VT] | tuple[_KT, _VT]) -> None: ... # type: ignore[override] | ||
|
|
||
| def subdict(d: dict[_KT, _VT], keep: Iterable[_KT] | None = None, drop: Iterable[_KT] | None = None) -> dict[_KT, _VT]: ... | ||
|
|
||
| class FrozenHashError(TypeError): ... # undocumented | ||
|
|
||
| class FrozenDict(dict[_KT, _VT]): | ||
| def __copy__(self) -> Self: ... | ||
| def clear(self, *a, **kw) -> None: ... | ||
| @classmethod | ||
| def fromkeys(cls, keys: Iterable[_KT], value: _VT | None = None) -> FrozenDict[_KT, _VT]: ... # type: ignore[override] | ||
| def pop(self, *a, **kw) -> NoReturn: ... | ||
| def popitem(self, *a, **kw) -> NoReturn: ... | ||
| def setdefault(self, *a, **kw) -> NoReturn: ... | ||
| def updated(self, *a, **kw) -> Self: ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,3 @@ | ||
| from typing import NoReturn | ||
|
|
||
| def gobs_program() -> NoReturn: ... | ||
AABur marked this conversation as resolved.
Show resolved
Hide resolved
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| from typing import Any | ||
|
|
||
| ECO_VERSION: str | ||
| PY_GT_2: bool | ||
| HAVE_URANDOM: bool | ||
| INSTANCE_ID: str | ||
| IS_64BIT: bool | ||
| HAVE_UCS4: bool | ||
| HAVE_READLINE: bool | ||
| SQLITE_VERSION: str | ||
| OPENSSL_VERSION: str | ||
| TKINTER_VERSION: str | ||
| ZLIB_VERSION: str | ||
| EXPAT_VERSION: str | ||
| CPU_COUNT: int | ||
| HAVE_THREADING: bool | ||
| HAVE_IPV6: bool | ||
| RLIMIT_NOFILE: int | ||
| RLIMIT_FDS_SOFT: int | ||
| RLIMIT_FDS_HARD: int | ||
| START_TIME_INFO: dict[str, str | float] | ||
|
|
||
| def getrandbits(k: int) -> int: ... | ||
| def get_python_info() -> dict[str, Any]: ... | ||
| def get_profile(**kwargs) -> dict[str, Any]: ... | ||
| def get_profile_json(indent: bool = False) -> str: ... | ||
| def main() -> None: ... | ||
| def dumps(val: Any, indent: int) -> str: ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| from typing import Any | ||
| from typing_extensions import Self | ||
|
|
||
| class ExceptionCauseMixin(Exception): | ||
| cause: Any | ||
| def __new__(cls, *args, **kw) -> Self: ... | ||
| def get_str(self) -> str: ... | ||
|
|
||
| class MathError(ExceptionCauseMixin, ValueError): ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,79 @@ | ||
| from _typeshed import StrOrBytesPath | ||
| from collections.abc import Callable, Generator, Iterable | ||
| from types import TracebackType | ||
| from typing import IO, Any, NoReturn | ||
| from typing_extensions import Self | ||
|
|
||
| def mkdir_p(path: StrOrBytesPath) -> None: ... | ||
|
|
||
| class FilePerms: | ||
| user: str | ||
| group: str | ||
| other: str | ||
| def __init__(self, user: str = "", group: str = "", other: str = "") -> None: ... | ||
| @classmethod | ||
| def from_int(cls, i: int) -> Self: ... | ||
| @classmethod | ||
| def from_path(cls, path: StrOrBytesPath) -> Self: ... | ||
| def __int__(self) -> int: ... | ||
|
|
||
| def atomic_save(dest_path: str, **kwargs) -> AtomicSaver: ... | ||
|
|
||
| class AtomicSaver: | ||
| dest_path: str | ||
| overwrite: bool | ||
| file_perms: int | ||
| overwrite_part: bool | ||
| part_filename: str | ||
| rm_part_on_exc: bool | ||
| text_mode: bool | ||
| buffering: int | ||
| dest_dir: str | ||
| part_path: str | ||
| mode: str | ||
| open_flags: int | ||
| part_file: str | None | ||
| def __init__(self, dest_path: str, **kwargs) -> None: ... | ||
| def setup(self) -> None: ... | ||
| def __enter__(self) -> IO[Any] | None: ... | ||
| def __exit__( | ||
| self, exc_type: type[BaseException] | None, exc_val: BaseException | None, exc_tb: TracebackType | None | ||
| ) -> None: ... | ||
|
|
||
| def iter_find_files( | ||
| directory: str, patterns: str | Iterable[str], ignored: str | Iterable[str] | None = None, include_dirs: bool = False | ||
| ) -> Generator[str, None, None]: ... | ||
| def copy_tree( | ||
| src: StrOrBytesPath, | ||
| dst: StrOrBytesPath, | ||
| symlinks: bool = False, | ||
| ignore: None | Callable[[str, list[str]], Iterable[str]] | Callable[[StrOrBytesPath, list[str]], Iterable[str]] = None, | ||
| ) -> None: ... | ||
|
|
||
| copytree = copy_tree | ||
|
|
||
| class DummyFile: | ||
| name: str | ||
| mode: str | ||
| closed: bool | ||
| errors: None | ||
| isatty: bool | ||
| encoding: None | ||
| newlines: None | ||
| softspace: int | ||
| def __init__(self, path: StrOrBytesPath, mode: str = "r", buffering: int | None = None) -> None: ... | ||
| def close(self) -> None: ... | ||
| def fileno(self) -> int: ... | ||
| def flush(self) -> None: ... | ||
| def next(self) -> NoReturn: ... | ||
| def read(self, size: int = 0) -> str: ... | ||
| def readline(self, size: int = 0) -> str: ... | ||
| def readlines(self, size: int = 0) -> list[str]: ... | ||
| def seek(self) -> None: ... | ||
| def tell(self) -> int: ... | ||
| def truncate(self) -> None: ... | ||
| def write(self, string: str) -> None: ... | ||
| def writelines(self, list_of_strings: list[str]) -> None: ... | ||
| def __next__(self) -> NoReturn: ... | ||
| def __enter__(self) -> None: ... | ||
| def __exit__(self, exc_type, exc_val, exc_tb) -> None: ... |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.