mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-01 02:02:20 +00:00
* fix: enforce team member budget check in common_checks - Add missing team member budget validation in common_checks() function - Checks team membership budget when team key is used - Raises BudgetExceededError when team member spend exceeds max_budget_in_team - Follows same pattern as other budget checks (team, user, end_user) - Uses cached get_team_membership() for performance - Fix AttributeError in lowest_tpm_rpm.py - Add null check for model_info before accessing .get() method - Prevents 'NoneType' object has no attribute 'get' error - Add unit tests for team member budget enforcement - Test budget exceeded scenario - Test within budget scenario - Test edge cases (no budget, no membership, personal keys) - Tests run without requiring proxy server Fixes failing test: test_users_in_team_budget * fix: mock get_async_httpx_client in test_langsmith_key_based_logging - Mock get_async_httpx_client to return a mock AsyncHTTPHandler instance - Fixes test failure where mock_post was never called - LangsmithLogger creates its own httpx client instance via get_async_httpx_client, so we need to mock the factory function rather than the class method - Use MagicMock for response.raise_for_status (sync method) instead of AsyncMock * fix: resolve linting errors (PLR0915, F401) - Remove unused imports (datetime, ServiceLoggerPayload) from arize_phoenix.py - Extract health ping setup logic from RedisCache.__init__ to reduce statement count - Extract team member budget check from common_checks to reduce statement count * fix: resolve type errors in ChatCompletionToolCallChunk construction - Cast type field to Literal['function'] to satisfy TypedDict requirements - Ensure arguments field is explicitly str type to match TypedDict signature - Fixes pyright errors for incompatible types in transformation.py |
||
|---|---|---|
| .. | ||
| _experimental/mcp_server | ||
| agent_endpoints | ||
| anthropic_endpoints | ||
| auth | ||
| client | ||
| common_utils | ||
| db | ||
| discovery_endpoints | ||
| experimental/mcp_server | ||
| google_endpoints | ||
| guardrails | ||
| health_endpoints | ||
| hooks | ||
| image_endpoints | ||
| management_endpoints | ||
| management_helpers | ||
| middleware | ||
| openai_files_endpoint | ||
| pass_through_endpoints | ||
| prompts | ||
| public_endpoints | ||
| response_api_endpoints | ||
| spend_tracking | ||
| test_configs | ||
| ui_crud_endpoints | ||
| vector_store_endpoints | ||
| __init__.py | ||
| conftest.py | ||
| test_batch_metadata_none_fix.py | ||
| test_caching_routes.py | ||
| test_common_request_processing.py | ||
| test_custom_proxy.py | ||
| test_enforce_user_param.py | ||
| test_fastapi_offline_routes.py | ||
| test_health_check_functions.py | ||
| test_litellm_pre_call_utils.py | ||
| test_model_id_header_propagation.py | ||
| test_proxy_cli.py | ||
| test_proxy_server.py | ||
| test_proxy_types.py | ||
| test_proxy_utils.py | ||
| test_route_llm_request.py | ||
| test_shared_health_check.py | ||
| test_spend_log_cleanup.py | ||
| test_swagger_chat_completions.py | ||
| test_team_member_update.py | ||