mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-07 02:59:05 +00:00
fix(router): import the no-deployments error where the cooldown callback uses it
Keeps the new symbol out of the module-level litellm.router and litellm.types.router cycle that CodeQL flags. Co-authored-by: songkuan-zheng <252822057+songkuan-zheng@users.noreply.github.com> Co-authored-by: songkuan-zheng <songkuan-zheng@users.noreply.github.com>
This commit is contained in:
parent
8f3a7b54c7
commit
be50ed3773
1 changed files with 2 additions and 1 deletions
|
|
@ -296,7 +296,6 @@ from litellm.types.router import (
|
|||
RouterErrors,
|
||||
RouterGeneralSettings,
|
||||
RouterModelGroupAliasItem,
|
||||
RouterNoDeploymentsAvailableError,
|
||||
RouterRateLimitError,
|
||||
RouterRateLimitErrorBasic,
|
||||
RoutingContext,
|
||||
|
|
@ -8254,6 +8253,8 @@ class Router:
|
|||
)
|
||||
return False
|
||||
|
||||
from litellm.types.router import RouterNoDeploymentsAvailableError
|
||||
|
||||
if isinstance(exception, RouterNoDeploymentsAvailableError):
|
||||
return False
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue