mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-27 03:34:10 +00:00
(feat) improve cache debugging litellm
This commit is contained in:
parent
a0601723e5
commit
c898ffe636
1 changed files with 10 additions and 3 deletions
|
@ -170,8 +170,10 @@ class RedisCache(BaseCache):
|
||||||
)
|
)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
# NON blocking - notify users Redis is throwing an exception
|
# NON blocking - notify users Redis is throwing an exception
|
||||||
print_verbose(
|
verbose_logger.error(
|
||||||
f"LiteLLM Redis Caching: async set() - Got exception from REDIS : {str(e)}"
|
"LiteLLM Redis Caching: async set() - Got exception from REDIS %s, Writing value=%s",
|
||||||
|
str(e),
|
||||||
|
value,
|
||||||
)
|
)
|
||||||
traceback.print_exc()
|
traceback.print_exc()
|
||||||
|
|
||||||
|
@ -200,7 +202,12 @@ class RedisCache(BaseCache):
|
||||||
# Optionally, you could process 'results' to make sure that all set operations were successful.
|
# Optionally, you could process 'results' to make sure that all set operations were successful.
|
||||||
return results
|
return results
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
print_verbose(f"Error occurred in pipeline write - {str(e)}")
|
verbose_logger.error(
|
||||||
|
"LiteLLM Redis Caching: async set_cache_pipeline() - Got exception from REDIS %s, Writing value=%s",
|
||||||
|
str(e),
|
||||||
|
cache_value,
|
||||||
|
)
|
||||||
|
traceback.print_exc()
|
||||||
|
|
||||||
async def batch_cache_write(self, key, value, **kwargs):
|
async def batch_cache_write(self, key, value, **kwargs):
|
||||||
print_verbose(
|
print_verbose(
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue