mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-06 08:16:43 +00:00
ci/cd add debugging for cache eviction
This commit is contained in:
parent
05fe43f495
commit
e899359427
1 changed files with 8 additions and 0 deletions
|
|
@ -97,6 +97,14 @@ class InMemoryCache(BaseCache):
|
|||
"""
|
||||
for key in list(self.ttl_dict.keys()):
|
||||
if time.time() > self.ttl_dict[key]:
|
||||
print( # noqa
|
||||
"Cache Evicting item key=",
|
||||
key,
|
||||
"ttl=",
|
||||
self.ttl_dict[key],
|
||||
"size of cache=",
|
||||
len(self.cache_dict),
|
||||
)
|
||||
self.cache_dict.pop(key, None)
|
||||
self.ttl_dict.pop(key, None)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue