Bump cachetools to 5.4.* (#12353)

This commit is contained in:
sobolevn
2024-07-16 16:07:42 +03:00
committed by GitHub
parent 1209816e48
commit 274b10da70
4 changed files with 8 additions and 2 deletions

View File

@@ -1,2 +1,2 @@
version = "5.3.*"
version = "5.4.*"
upstream_repository = "https://github.com/tkem/cachetools"

View File

@@ -2,6 +2,7 @@ from _typeshed import IdentityFunction, Unused
from collections.abc import Callable, Iterator, MutableMapping, Sequence
from contextlib import AbstractContextManager
from typing import Any, TypeVar, overload
from typing_extensions import deprecated
__all__ = ("Cache", "FIFOCache", "LFUCache", "LRUCache", "MRUCache", "RRCache", "TLRUCache", "TTLCache", "cached", "cachedmethod")
__version__: str
@@ -36,6 +37,8 @@ class Cache(MutableMapping[_KT, _VT]):
class FIFOCache(Cache[_KT, _VT]): ...
class LFUCache(Cache[_KT, _VT]): ...
class LRUCache(Cache[_KT, _VT]): ...
@deprecated("@mru_cache is deprecated")
class MRUCache(Cache[_KT, _VT]): ...
class RRCache(Cache[_KT, _VT]):

View File

@@ -1,6 +1,7 @@
from _typeshed import IdentityFunction
from collections.abc import Callable, Sequence
from typing import TypeVar
from typing_extensions import deprecated
__all__ = ("fifo_cache", "lfu_cache", "lru_cache", "mru_cache", "rr_cache", "ttl_cache")
_T = TypeVar("_T")
@@ -8,6 +9,7 @@ _T = TypeVar("_T")
def fifo_cache(maxsize: float | None = 128, typed: bool = False) -> IdentityFunction: ...
def lfu_cache(maxsize: float | None = 128, typed: bool = False) -> IdentityFunction: ...
def lru_cache(maxsize: float | None = 128, typed: bool = False) -> IdentityFunction: ...
@deprecated("@mru_cache is deprecated")
def mru_cache(maxsize: float | None = 128, typed: bool = False) -> IdentityFunction: ...
def rr_cache(
maxsize: float | None = 128, choice: Callable[[Sequence[_T]], _T] | None = ..., typed: bool = False

View File

@@ -1,8 +1,9 @@
from _typeshed import Unused
from collections.abc import Hashable
__all__ = ("hashkey", "methodkey", "typedkey")
__all__ = ("hashkey", "methodkey", "typedkey", "typedmethodkey")
def hashkey(*args: Hashable, **kwargs: Hashable) -> tuple[Hashable, ...]: ...
def methodkey(self: Unused, *args: Hashable, **kwargs: Hashable) -> tuple[Hashable, ...]: ...
def typedkey(*args: Hashable, **kwargs: Hashable) -> tuple[Hashable, ...]: ...
def typedmethodkey(self: Unused, *args: Hashable, **kwargs: Hashable) -> tuple[Hashable, ...]: ...