mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-08 22:21:35 +00:00
fix(lowest_tpm_rpm_v2.py): ensure backwards compatibility for python 3.8
This commit is contained in:
parent
81573b2dd9
commit
3b9e2a58e2
1 changed files with 2 additions and 2 deletions
|
|
@ -39,7 +39,7 @@ class LowestTPMLoggingHandler_v2(CustomLogger):
|
|||
self.router_cache = router_cache
|
||||
self.model_list = model_list
|
||||
|
||||
def pre_call_check(self, deployment: Dict) -> Dict | None:
|
||||
def pre_call_check(self, deployment: Dict) -> Optional[Dict]:
|
||||
"""
|
||||
Pre-call check + update model rpm
|
||||
|
||||
|
|
@ -113,7 +113,7 @@ class LowestTPMLoggingHandler_v2(CustomLogger):
|
|||
raise e
|
||||
return deployment # don't fail calls if eg. redis fails to connect
|
||||
|
||||
async def async_pre_call_check(self, deployment: Dict) -> Dict | None:
|
||||
async def async_pre_call_check(self, deployment: Dict) -> Optional[Dict]:
|
||||
"""
|
||||
Pre-call check + update model rpm
|
||||
- Used inside semaphore
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue