mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-07 02:59:05 +00:00
fix(router): declare cooldown_time as float on RouterRateLimitError
The shared base declares cooldown_time as float | None because the budget limiter and the sync tpm strategy have no window to report. RouterRateLimitError always receives one, so it redeclares the attribute as float and callers that compare it keep a narrowed type 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
20e7ac6d8a
commit
05abb93c5d
1 changed files with 2 additions and 0 deletions
|
|
@ -967,6 +967,8 @@ class RouterErrorTypes(str, enum.Enum):
|
|||
|
||||
|
||||
class RouterRateLimitError(RouterNoDeploymentsAvailableError):
|
||||
cooldown_time: float
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
model: str,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue