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
ci: tighten deprecation_date pattern to reject impossible months and days
mateo-berri3d01c39d0010
diff --git a/ci_cd/generate_model_prices_schema.py b/ci_cd/generate_model_prices_schema.pyindex 83c48f788f8..612c105bbb6 100644--- a/ci_cd/generate_model_prices_schema.py+++ b/ci_cd/generate_model_prices_schema.py@@ -187,7 +187,8 @@ def string_key_schemas(modes: tuple) -> dict[str, JsonSchema]:"deprecation_date": {"type": "string","description": "Date the provider deprecates the model, YYYY-MM-DD.",- "pattern": "^\\d{4}-\\d{2}-\\d{2}$",+ "format": "date",+ "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01])$",},"web_search_billing_unit": {"type": "string",diff --git a/model_prices_and_context_window.schema.json b/model_prices_and_context_window.schema.jsonindex 6e3c3620232..988f56655fc 100644--- a/model_prices_and_context_window.schema.json+++ b/model_prices_and_context_window.schema.json@@ -167,7 +167,8 @@"deprecation_date": {"type": "string","description": "Date the provider deprecates the model, YYYY-MM-DD.",- "pattern": "^\\d{4}-\\d{2}-\\d{2}$"+ "format": "date",+ "pattern": "^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01])$"},"gemini_audio_only_live": {"type": "boolean"diff --git a/tests/test_litellm/test_model_prices_schema.py b/tests/test_litellm/test_model_prices_schema.pyindex 95b9952ad18..9321e974f8c 100644--- a/tests/test_litellm/test_model_prices_schema.py+++ b/tests/test_litellm/test_model_prices_schema.py@@ -57,6 +57,10 @@ def test_prices_file_validates_against_committed_schema(prices: dict, committed_{"litellm_provider": "openai", "mode": "not_a_real_mode"},{"mode": "chat"},{"litellm_provider": "openai", "deprecation_date": "June 2026"},+ {"litellm_provider": "openai", "deprecation_date": "2026-99-99"},+ {"litellm_provider": "openai", "deprecation_date": "2026-13-01"},+ {"litellm_provider": "openai", "deprecation_date": "2026-01-32"},+ {"litellm_provider": "openai", "deprecation_date": "2026-01-00"},{"litellm_provider": "openai", "supported_modalities": ["smell"]},{"litellm_provider": "openai", "supports_vision": "yes"},{"litellm_provider": "openai", "max_tokens": 8191.5},@@ -68,6 +72,10 @@ def test_prices_file_validates_against_committed_schema(prices: dict, committed_"unknown_mode","missing_provider","non_iso_deprecation_date",+ "impossible_month_and_day",+ "month_out_of_range",+ "day_out_of_range",+ "day_zero","unknown_modality","boolean_flag_as_string","fractional_max_tokens",