ci/cd add debugging for cache eviction

This commit is contained in:
Ishaan Jaff 2024-06-25 08:14:09 -07:00
parent 05fe43f495
commit e899359427

View file

@ -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)