Litellm stable UI 02 17 2025 p1 (#8599)

* fix(key_management_endpoints.py): initial commit with logic to get all keys for teams user is an admin for

* fix(key_managements_endpoints.py): return all keys for teams user is an admin for

* fix(key_management_endpoints.py): add query param to ensure user opts into seeing all team keys (not just their own)

* fix(regenerate_key_modal.tsx): fix key regenerate

* fix(proxy_server.py): fix model metrics check on none api base

* test(test_key_generate_prisma.py): remove redundant test

* test(test_proxy_utils.py): add unit test covering new management endpoint helper util

* fix: fix test

* test(test_proxy_server.py): fix test
This commit is contained in:
Krish Dholakia 2025-02-17 17:55:05 -08:00 committed by GitHub
parent d0413ec96b
commit 51cb3c84e3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 277 additions and 121 deletions

View file

@ -6472,9 +6472,9 @@ async def model_metrics(
if _day not in _daily_entries:
_daily_entries[_day] = {}
_combined_model_name = str(_model)
if "https://" in _api_base:
if _api_base is not None and "https://" in _api_base:
_combined_model_name = str(_api_base)
if "/openai/" in _combined_model_name:
if _combined_model_name is not None and "/openai/" in _combined_model_name:
_combined_model_name = _combined_model_name.split("/openai/")[0]
_all_api_bases.add(_combined_model_name)