mirror of
https://github.com/BerriAI/litellm.git
synced 2026-08-28 05:25:59 +00:00
fix(redis): say when an async client drops an unusable connect func
A caller-supplied redis_connect_func has no way to run on an async connection, so log it instead of dropping it in silence.
This commit is contained in:
parent
bfe54eb013
commit
307ca1bcc7
1 changed files with 6 additions and 0 deletions
|
|
@ -589,6 +589,12 @@ def _async_credential_provider(redis_connect_func: object | None) -> CredentialP
|
|||
if azure_credential is not None:
|
||||
return AzureADCredentialProvider(azure_credential, username=os.environ.get("REDIS_USERNAME") or None)
|
||||
|
||||
if redis_connect_func is not None:
|
||||
verbose_logger.warning(
|
||||
"REDIS: dropping redis_connect_func, which an async connection cannot run. "
|
||||
"Configure Azure AD or GCP IAM auth so a credential provider handles the token instead."
|
||||
)
|
||||
|
||||
return None
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue