litellm/tests/test_litellm/llms
Mateo Wang 41e9cc491e
fix(bedrock-invoke): retain clear_tool_uses_20250919 context_management edits and emit context-management-2025-06-27 beta (LIT-3393) (#32658)
* fix(bedrock-invoke): retain clear_tool_uses_20250919 context_management edits and emit context-management-2025-06-27 beta (LIT-3393)

Copy of #29206 by oss-agent-shin, rebased onto litellm_internal_staging so CircleCI can run.

Bedrock InvokeModel supports automatic tool-call clearing (clear_tool_uses_20250919) under the context-management-2025-06-27 beta, but LiteLLM stripped the edit and dropped the beta header, causing a Bedrock 400. This maps bedrock.context-management-2025-06-27 to itself in anthropic_beta_headers_config.json (bedrock_converse stays null) and rewrites _filter_context_management_for_bedrock_invoke around an allowlist of supported edit types that keeps each supported edit and adds its matching beta.

* test(bedrock-invoke): restore beta-headers config cache with a shared fixture in LIT-3393 tests

Greptile flagged that three of the four new tests reloaded the module-level
beta-headers config into local mode without restoring it on teardown, leaking
state into later tests in the same process. Move setup/teardown into a
local_beta_headers_config fixture used by all four tests.

---------

Co-authored-by: oss-agent-shin <ext-agent-shin@berri.ai>
2026-07-09 14:31:27 -07:00
..
a2a/chat fix(a2a): populate response usage in a2a chat transformation (#31980) 2026-07-03 09:28:36 +05:30
aiml/image_generation feat(aiml): add openai/gpt-image-2 image model (#31323) 2026-06-25 16:41:43 -07:00
amazon_nova/chat
anthropic fix(batches): price anthropic passthrough message batches correctly in batch cost job (#32307) 2026-07-06 20:33:57 -07:00
apiserpent fix(search): block server credential leak to caller-supplied api_base (#30682) 2026-06-23 13:01:21 -07:00
azure fix(azure): build responses input_items url with path before query string (#32270) 2026-07-06 14:02:44 -07:00
azure_ai fix(azure_ai): preserve content, tables, and keyValuePairs in doc-intelligence /v1/ocr (#32018) 2026-07-02 22:38:36 -07:00
base_llm test(batches): add 1:1 test file scaffold for batches component paths (#30529) 2026-06-29 09:22:58 +05:30
baseten/chat
bedrock fix(bedrock-invoke): retain clear_tool_uses_20250919 context_management edits and emit context-management-2025-06-27 beta (LIT-3393) (#32658) 2026-07-09 14:31:27 -07:00
bedrock_mantle feat(bedrock_mantle): add xai.grok-4.3 to model cost map for SigV4 auth (#31916) 2026-07-01 15:44:30 -07:00
black_forest_labs
bytez/chat
chat
chatgpt
cloudflare fix(cloudflare): route native Workers AI provider through OpenAI-compatible endpoint (#31053) 2026-06-23 12:09:11 -07:00
cohere chore: litellm oss staging (#31185) 2026-06-26 09:17:44 -07:00
cometapi/chat
compactifai
crusoe
custom_httpx fix(bedrock): stop stale SigV4 headers clobbering fresh signature on strip-and-retry re-sign (#32371) 2026-07-07 16:01:46 -07:00
dashscope
databricks fix(databricks): split parallel tool calls so each tool message follows tool_calls (#31633) 2026-06-29 13:46:53 -07:00
datarobot
deepgram
deepinfra
deepseek chore: litellm oss staging (#31185) 2026-06-26 09:17:44 -07:00
docker_model_runner
elevenlabs
fal_ai/image_generation
fastcrw/search
featherless_ai/chat
fireworks_ai feat(fireworks_ai): sync chat completions endpoint with full API surface (#30885) 2026-06-20 19:49:07 -07:00
gdc/chat feat(gdc): implement Google Distributed Cloud (GDC) Gemini provider (#31895) 2026-07-01 17:31:07 -07:00
gemini fix(realtime): stop second Gemini Live setup, retry hung handshake, close guardrail bypass (#31519) 2026-06-28 08:52:20 +05:30
github_copilot feat(github_copilot): route /v1/messages to Copilot native Anthropic endpoint (#31802) 2026-07-01 17:16:21 -07:00
heroku
hosted_vllm fix(bedrock): normalize Messages system role and adaptive-thinking for Claude Invoke (#31364) 2026-06-27 11:35:36 -07:00
huggingface
inception
jina_ai/embedding
langflow
lemonade
litellm_proxy
llamafile/chat
lm_studio
manus
meta_llama
minimax
mistral feat(mistral): add mistral/mistral-ocr-2512 (OCR 3) to cost map (#31463) 2026-06-26 10:29:07 -07:00
modelscope
moonshot chore: litellm oss staging (#31185) 2026-06-26 09:17:44 -07:00
nebius
neosantara
novita/chat
nscale/chat
nvidia_riva
oci
ocr
ollama
openai feat(models): add GPT-5.6 (sol/terra/luna) pricing and metadata (#32659) 2026-07-09 11:51:12 -07:00
openai_like feat(messages): passthrough /v1/messages to native endpoints via supported_endpoints (#31685) 2026-06-30 12:17:33 -07:00
openrouter chore: litellm oss staging160626 (#30527) 2026-06-16 18:23:13 -07:00
ovhcloud
parallel_ai fix(search): block server credential leak to caller-supplied api_base (#30682) 2026-06-23 13:01:21 -07:00
parasail
pass_through
perplexity chore: litellm oss staging (#30968) 2026-06-23 07:31:44 -07:00
pg_vector/vector_stores
publicai
ragflow/chat
recraft
reducto
runwayml
s3_vectors
sagemaker
sambanova
sap
scaleway
snowflake
soniox chore: litellm oss staging (#30745) 2026-06-18 13:55:35 -07:00
stability
tencent feat(tencent): add Tencent TokenHub as a provider (#31903) 2026-07-02 18:31:59 -07:00
tinyfish feat(tinyfish): make search provider permissive, attribute errors (#31997) 2026-07-03 10:17:11 -07:00
vercel_ai_gateway
vertex_ai fix(vertex_ai): return create_vertex_url result directly for openai-path partner models with custom api_base (#32380) 2026-07-07 14:49:21 -07:00
volcengine
voyage
wandb
watsonx fix(watsonx): wrap string embedding input in array for WatsonX API (#30897) 2026-06-20 15:50:44 -07:00
xai
you_com
zai
test_cache_control_and_reasoning.py
test_file_content_block.py
test_file_search_responses.py
test_lifecycle_fix.py
test_oom_fixes.py
test_polling_url_origin_match.py
test_predibase_transformation.py