(fix) proxy + cache - os.environ/ vars

This commit is contained in:
ishaan-jaff 2024-01-06 16:15:53 +05:30
parent 174248fc71
commit c222c0bfb8

View file

@ -675,7 +675,7 @@ class ProxyConfig:
# users can pass os.environ/ variables on the proxy - we should read them from the env
for key, value in cache_params.items():
if value.startswith("os.environ/"):
if type(value) is str and value.startswith("os.environ/"):
cache_params[key] = litellm.get_secret(value)
## to pass a complete url, or set ssl=True, etc. just set it as `os.environ[REDIS_URL] = <your-redis-url>`, _redis.py checks for REDIS specific environment variables