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
test fix claude-sonnet-4-5-20250929
Ishaan Jaffer33371d18f4f3
diff --git a/tests/llm_responses_api_testing/test_anthropic_responses_api.py b/tests/llm_responses_api_testing/test_anthropic_responses_api.pyindex 58dec058d65..df818ce5c7d 100644--- a/tests/llm_responses_api_testing/test_anthropic_responses_api.py+++ b/tests/llm_responses_api_testing/test_anthropic_responses_api.py@@ -30,7 +30,7 @@ class TestAnthropicResponsesAPITest(BaseResponsesAPITest):def get_base_completion_call_args(self):#litellm._turn_on_debug()return {- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929",}async def test_basic_openai_responses_delete_endpoint(self, sync_mode=False):diff --git a/tests/llm_translation/test_anthropic_completion.py b/tests/llm_translation/test_anthropic_completion.pyindex eacf24be594..f42a424dcaa 100644--- a/tests/llm_translation/test_anthropic_completion.py+++ b/tests/llm_translation/test_anthropic_completion.py@@ -484,7 +484,7 @@ from litellm import completionclass TestAnthropicCompletion(BaseLLMChatTest, BaseAnthropicChatTest):def get_base_completion_call_args(self) -> dict:- return {"model": "anthropic/claude-sonnet-4-5-latest"}+ return {"model": "anthropic/claude-sonnet-4-5-20250929"}def get_base_completion_call_args_with_thinking(self) -> dict:return {@@ -1256,7 +1256,7 @@ async def test_anthropic_api_max_completion_tokens(model: str):def test_anthropic_websearch(optional_params: dict):litellm._turn_on_debug()params = {- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929","messages": [{"role": "user", "content": "Who won the World Cup in 2022?"}],**optional_params,}@@ -1275,7 +1275,7 @@ def test_anthropic_websearch(optional_params: dict):def test_anthropic_text_editor():litellm._turn_on_debug()params = {- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929","messages": [{"role": "user",@@ -1363,7 +1363,7 @@ def test_anthropic_mcp_server_responses_api(model: str):def test_anthropic_prefix_prompt():params = {- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929","messages": [{"role": "user", "content": "Who won the World Cup in 2022?"},{"role": "assistant", "content": "Argentina", "prefix": True},@@ -1479,7 +1479,7 @@ def test_anthropic_streaming():"content": "Do what you are told to do in the system prompt",},],- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929","max_tokens": 7000,"parallel_tool_calls": False,"stream": True,diff --git a/tests/local_testing/test_router.py b/tests/local_testing/test_router.pyindex d18bc89699f..3167ff52086 100644--- a/tests/local_testing/test_router.py+++ b/tests/local_testing/test_router.py@@ -105,7 +105,7 @@ async def test_router_provider_wildcard_routing():print("router model list = ", router.get_model_list())response1 = await router.acompletion(- model="anthropic/claude-sonnet-4-5-latest",+ model="anthropic/claude-sonnet-4-5-20250929",messages=[{"role": "user", "content": "hello"}],)@@ -126,7 +126,7 @@ async def test_router_provider_wildcard_routing():print("response 3 = ", response3)response4 = await router.acompletion(- model="claude-sonnet-4-5-latest",+ model="claude-sonnet-4-5-20250929",messages=[{"role": "user", "content": "hello"}],)diff --git a/tests/local_testing/test_router_auto_router.py b/tests/local_testing/test_router_auto_router.pyindex 9c18602b496..73e55c84c76 100644--- a/tests/local_testing/test_router_auto_router.py+++ b/tests/local_testing/test_router_auto_router.py@@ -52,7 +52,7 @@ async def test_router_auto_router():{"model_name": "litellm-claude-35","litellm_params": {- "model": "claude-sonnet-4-5-latest",+ "model": "claude-sonnet-4-5-20250929",},"model_info": {"id": "claude-id"},},@@ -89,7 +89,7 @@ async def test_router_auto_router():assert response._hidden_params["model_id"] == "openai-id"- # this goes to claude-sonnet-4-5-latest+ # this goes to claude-sonnet-4-5-20250929# these are the utterances in the router.json fileresponse = await router.acompletion(model="auto_router1",diff --git a/tests/local_testing/test_router_fallbacks.py b/tests/local_testing/test_router_fallbacks.pyindex 88643404b60..ce33b46f685 100644--- a/tests/local_testing/test_router_fallbacks.py+++ b/tests/local_testing/test_router_fallbacks.py@@ -1133,9 +1133,9 @@ async def test_router_content_policy_fallbacks(router = Router(model_list=[{- "model_name": "claude-sonnet-4-5-latest",+ "model_name": "claude-sonnet-4-5-20250929","litellm_params": {- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929","api_key": "","mock_response": mock_response,},@@ -1159,7 +1159,7 @@ async def test_router_content_policy_fallbacks({"model_name": "my-general-model","litellm_params": {- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929","api_key": "","mock_response": Exception("Should not have called this."),},@@ -1167,14 +1167,14 @@ async def test_router_content_policy_fallbacks({"model_name": "my-context-window-model","litellm_params": {- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929","api_key": "","mock_response": Exception("Should not have called this."),},},],content_policy_fallbacks=(- [{"claude-sonnet-4-5-latest": ["my-fallback-model"]}]+ [{"claude-sonnet-4-5-20250929": ["my-fallback-model"]}]if fallback_type == "model-specific"else None),@@ -1185,12 +1185,12 @@ async def test_router_content_policy_fallbacks(if sync_mode is True:response = router.completion(- model="claude-sonnet-4-5-latest",+ model="claude-sonnet-4-5-20250929",messages=[{"role": "user", "content": "Hey, how's it going?"}],)else:response = await router.acompletion(- model="claude-sonnet-4-5-latest",+ model="claude-sonnet-4-5-20250929",messages=[{"role": "user", "content": "Hey, how's it going?"}],)diff --git a/tests/local_testing/test_streaming.py b/tests/local_testing/test_streaming.pyindex ff28f79d056..faaea50cf34 100644--- a/tests/local_testing/test_streaming.py+++ b/tests/local_testing/test_streaming.py@@ -3982,7 +3982,7 @@ def test_streaming_finish_reason():## Anthropicresponse = litellm.completion(- model="anthropic/claude-sonnet-4-5-latest",+ model="anthropic/claude-sonnet-4-5-20250929",messages=[{"role": "user", "content": "What is the capital of France?"}],stream=True,stream_options={"include_usage": True},diff --git a/tests/test_litellm/responses/litellm_completion_transformation/test_session_handler.py b/tests/test_litellm/responses/litellm_completion_transformation/test_session_handler.pyindex 3eef43836ef..e67d6373dd4 100644--- a/tests/test_litellm/responses/litellm_completion_transformation/test_session_handler.py+++ b/tests/test_litellm/responses/litellm_completion_transformation/test_session_handler.py@@ -34,11 +34,11 @@ async def test_get_chat_completion_message_history_for_previous_response_id():"completion_tokens": 318,"startTime": "2025-05-30T03:17:06.703+00:00","endTime": "2025-05-30T03:17:11.894+00:00",- "model": "claude-sonnet-4-5-latest",+ "model": "claude-sonnet-4-5-20250929","session_id": "a96757c4-c6dc-4c76-b37e-e7dfa526b701","proxy_server_request": {"input": "who is Michael Jordan",- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929",},"response": {"id": "chatcmpl-935b8dad-fdc2-466e-a8ca-e26e5a8a21bb",@@ -75,11 +75,11 @@ async def test_get_chat_completion_message_history_for_previous_response_id():"completion_tokens": 628,"startTime": "2025-05-30T03:17:28.600+00:00","endTime": "2025-05-30T03:17:39.921+00:00",- "model": "claude-sonnet-4-5-latest",+ "model": "claude-sonnet-4-5-20250929","session_id": "a96757c4-c6dc-4c76-b37e-e7dfa526b701","proxy_server_request": {"input": "can you tell me more about him",- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929","previous_response_id": "resp_bGl0ZWxsbTpjdXN0b21fbGxtX3Byb3ZpZGVyOmFudGhyb3BpYzttb2RlbF9pZDplMGYzMDJhMTQxMmU3ODQ3MGViYjI4Y2JlZDAxZmZmNWY4OGMwZDMzMWM2NjdlOWYyYmE0YjQxM2M2ZmJkMjgyO3Jlc3BvbnNlX2lkOmNoYXRjbXBsLTkzNWI4ZGFkLWZkYzItNDY2ZS1hOGNhLWUyNmU1YThhMjFiYg==",},"response": {diff --git a/tests/test_litellm/test_router.py b/tests/test_litellm/test_router.pyindex 7d327dc5f67..5f66b0b09bb 100644--- a/tests/test_litellm/test_router.py+++ b/tests/test_litellm/test_router.py@@ -102,7 +102,7 @@ async def test_arouter_with_tags_and_fallbacks():{"model_name": "anthropic-claude-3-5-sonnet","litellm_params": {- "model": "claude-sonnet-4-5-latest",+ "model": "claude-sonnet-4-5-20250929","mock_response": "Hello, world 2!",},},@@ -670,9 +670,9 @@ async def test_router_v1_messages_fallbacks():router = litellm.Router(model_list=[{- "model_name": "claude-sonnet-4-5-latest",+ "model_name": "claude-sonnet-4-5-20250929","litellm_params": {- "model": "anthropic/claude-sonnet-4-5-latest",+ "model": "anthropic/claude-sonnet-4-5-20250929","mock_response": "litellm.InternalServerError",},},@@ -685,12 +685,12 @@ async def test_router_v1_messages_fallbacks():},],fallbacks=[- {"claude-sonnet-4-5-latest": ["bedrock-claude"]},+ {"claude-sonnet-4-5-20250929": ["bedrock-claude"]},],)result = await router.aanthropic_messages(- model="claude-sonnet-4-5-latest",+ model="claude-sonnet-4-5-20250929",messages=[{"role": "user", "content": "Hello, world!"}],max_tokens=256,)diff --git a/tests/test_litellm/test_utils.py b/tests/test_litellm/test_utils.pyindex b88615107f1..9d234388678 100644--- a/tests/test_litellm/test_utils.py+++ b/tests/test_litellm/test_utils.py@@ -353,7 +353,7 @@ def test_anthropic_web_search_in_model_info():supported_models = ["anthropic/claude-3-7-sonnet-20250219",- "anthropic/claude-sonnet-4-5-latest",+ "anthropic/claude-sonnet-4-5-20250929","anthropic/claude-3-5-sonnet-20241022","anthropic/claude-3-5-haiku-20241022","anthropic/claude-3-5-haiku-latest",@@ -1184,7 +1184,7 @@ class TestProxyFunctionCalling:), "Custom model names return False without proxy config context"# Case 2: Model name that can be resolved (matches pattern)- resolvable_model = "litellm_proxy/claude-sonnet-4-5-latest"+ resolvable_model = "litellm_proxy/claude-sonnet-4-5-20250929"result = supports_function_calling(resolvable_model)assert result is True, "Resolvable model names work with fallback logic"@@ -1195,7 +1195,7 @@ class TestProxyFunctionCalling:✅ WORKS (with current fallback logic):- litellm_proxy/gpt-4- - litellm_proxy/claude-sonnet-4-5-latest+ - litellm_proxy/claude-sonnet-4-5-20250929- litellm_proxy/anthropic/claude-3-haiku-20240307❌ DOESN'T WORK (requires proxy server config):diff --git a/tests/test_openai_endpoints.py b/tests/test_openai_endpoints.pyindex 1be35168a82..024d05e1037 100644--- a/tests/test_openai_endpoints.py+++ b/tests/test_openai_endpoints.py@@ -556,7 +556,7 @@ async def test_proxy_all_models():await chat_completion(session=session,key=LITELLM_MASTER_KEY,- model="anthropic/claude-sonnet-4-5-latest",+ model="anthropic/claude-sonnet-4-5-20250929",)