The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
style: apply black to litellm/router.py
shivam8a9457e0c02a
diff --git a/litellm/router.py b/litellm/router.pyindex db250b5a19e..5c336b7d9c8 100644--- a/litellm/router.py+++ b/litellm/router.py@@ -5366,14 +5366,17 @@ class Router:e,(litellm.ContextWindowExceededError, litellm.ContentPolicyViolationError),)- _request_team_id: Optional[str] = (- kwargs.get("metadata", {}) or {}- ).get("user_api_key_team_id")+ _request_team_id: Optional[str] = (kwargs.get("metadata", {}) or {}).get(+ "user_api_key_team_id"+ )# Use wildcard-aware lookup so order-based fallback also works for model# groups resolved via pattern routing (e.g. `openai/*` -> `openai/gpt-4.1-mini`).- all_deployments = self.get_model_list(- model_name=original_model_group, team_id=_request_team_id- ) or []+ all_deployments = (+ self.get_model_list(+ model_name=original_model_group, team_id=_request_team_id+ )+ or []+ )_order_set: set = {litellm.utils._get_deployment_order(d)for d in all_deployments