* fix: video status/content credential injection for wildcard models
When using wildcard model patterns like `vertex_ai/*`, the video status
and content endpoints failed to resolve the model_name correctly,
causing credential injection to be skipped.
Changes:
- router.py: Added `custom_llm_provider` parameter to
`resolve_model_name_from_model_id` method
- router.py: Added Strategy 2 (provider prefix matching) and
Strategy 4 (wildcard pattern matching)
- endpoints.py: Pass `provider_from_id` to resolver in video_status,
video_content, and video_remix endpoints
This allows video_id like `vertex_ai:veo-3.0-generate-preview:...` to
correctly match `vertex_ai/*` wildcard pattern and inject credentials
from the model config.
Fixes: Video status returns "Your default credentials were not found"
when using Vertex AI video generation with wildcard model patterns.
* pr18845-video기능버그픽스 (vibe-kanban e43e2d2d)
pr코멘트 대응
litellm fork해서 branch만들고 작업후 pull request를 올렸는데 피드백을줬어.
이 내용 파악해서 내가 올린 pr 브랜치에 해당 작업 이어서 해야할거같아.
https://github.com/BerriAI/litellm/pull/18854#discussion\_r2677026995
여기 내용 읽고 현황 파악해서 작업하자.
테스트코드 작성해달라는데 테스트코드작성후 로컬에서 테스트명령어 한번 돌리고 커밋 푸시하려고.
litellm에서 pull request를 위한 문서가 있어.
https://docs.litellm.ai/docs/extras/contributing\_code
CRA서명은 했어. 그다음거부터 양식에 맞게 해야할듯. 지금 버그만 바로 고쳐서 pr했거든.
* fix: resolve mypy type error in resolve_model_name_from_model_id
Rename loop variable to avoid type conflict between DeploymentTypedDict
and Dict[Any, Any] from pattern_router.route() return type.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
* [Fix] Containers API - Allow routing to regional endpoints (#19118)
* fix get_complete_url
* fix url resolution containers API
* TestContainerRegionalApiBase
* feat(proxy): add keepalive_timeout support for Gunicorn server
Add configurable keepalive timeout parameter for Gunicorn workers to
match existing Uvicorn functionality. This allows users to tune the
keep-alive connection timeout based on their deployment requirements.
Changes:
- Add keepalive_timeout parameter to _run_gunicorn_server method
- Configure Gunicorn's keepalive setting (defaults to 90s if not specified)
- Update --keepalive_timeout CLI help text to document both Uvicorn and Gunicorn behavior
- Pass keepalive_timeout from run_server to _run_gunicorn_server
Tests:
- Add test to verify keepalive_timeout flag is properly passed to Gunicorn
- Add test to verify default 90s timeout when flag is not specified
Co-Authored-By: lizhen921 <294474470@qq.com>
Signed-off-by: Kris Xia <xiajiayi0506@gmail.com>
---------
Signed-off-by: Kris Xia <xiajiayi0506@gmail.com>
Co-authored-by: Ishaan Jaff <ishaanjaffer0324@gmail.com>
Co-authored-by: lizhen921 <294474470@qq.com>
* test_should_not_fail_with_forwarded_headers_bedrock_invoke_messages
* use common get_request_headers for BaseAWS
* fix get_request_headers
* test_should_not_fail_with_forwarded_headers_bedrock_invoke_messages
Tools with no parameters (like EnterPlanMode from Anthropic Agents SDK)
send schemas with only $schema and no type field. Gemini rejects these
with "functionDeclaration parameters schema should be of type OBJECT".
Adds type: object when schema has no type and no anyOf/oneOf/allOf.
Extract and preserve provider-specific headers (llm_provider-*) when
handling error responses from LLM providers. This ensures that useful
debugging information from providers is available even when requests
fail with BadRequestError or similar exceptions.
Gemini API rejects JSON schemas with $defs/$ref references anywhere in
the conversation, including in function_response content. This causes
errors when tools return JSON containing schemas (e.g., toolbelt_inspect_tool
returning tool definitions).
The fix:
1. Apply unpack_defs() to all JSON tool responses before sending to Gemini
2. Recursively remove $defs sections after inlining references
3. Replace any remaining $ref (circular refs, external URLs) with placeholders
Edge cases handled:
- Circular $ref (self-referential types like TreeNode.left -> TreeNode)
- External $ref (URL-based like https://...)
- Deeply nested $ref in anyOf/oneOf/allOf
This ensures function_response content is clean before being sent to the
Gemini API.
Related issues:
- https://github.com/google-gemini/gemini-cli/issues/13326
- FastMCP #1372, #1426
OpenAI's 400k context window is split between input and output:
- GPT-5/5.1/5.2 models: 272k input + 128k output = 400k context
- GPT-5-pro models: 128k input + 272k output = 400k context
Reference: https://openai.com/index/introducing-gpt-5-for-developers/
"In the API, all GPT-5 models can accept a maximum of 272,000 input
tokens and emit a maximum of 128,000 reasoning & output tokens"
Fixes incorrect 400k max_input_tokens values across 32 models.