Skip to content

Commit e5123a3

Browse files
committed
Update _Timer.
1 parent 0b07823 commit e5123a3

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

stubs/cachetools/cachetools/__init__.pyi

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,11 @@ class RRCache(Cache[_KT, _VT]):
5252
class _TimedCache(Cache[_KT, _VT]):
5353
def __init__(self, maxsize: float, timer: Callable[..., _TT], getsizeof: Callable[[_VT], float] | None): ...
5454

55-
class _Timer(AbstractContextManager[_TT]):
55+
class _Timer:
56+
def __init__(self, timer: Callable[[], _TT]) -> None: ...
5657
def __call__(self) -> _TT: ...
58+
def __enter__(self) -> _TT: ...
59+
def __exit__(self, *exc: Unused) -> None: ...
5760
def __getattr__(self, name: str) -> Any: ...
5861

5962
@property

0 commit comments

Comments
 (0)