litellm/tests/unit/llms/bedrock/chat/invoke_transformations
mateo-berri a09b92dbb6 fix(anthropic): answer 400 for a raised extra_body max_tokens and promote system on Azure AI
An extra_body max_tokens above the request's answers 400 unless drop_params
is on, which caps it, so the output tokens the limiters reserved still bound
the call. Keys litellm builds that extra_body tries to set are dropped with a
warning under drop_params. Azure AI sends extra_body.system as the system
prompt, since litellm moves a top-level system kwarg there. extra_body
output_config now wins over the mapped one, and transform_request no longer
pops extra_body from the caller's optional_params.

Ported from 8a9ed2f63d on #48373. The 1.108 line
has no OpenCode Go chat config, so that part of the commit has no port.
2026-11-19 22:54:41 -08:00
..
__init__.py test(unit): make every tests/unit directory a package so pytest collection is unique 2026-09-20 11:50:59 +00:00
test_amazon_moonshot_transformation.py test: move the unit half of 126 mixed legacy files into tests/unit (#45090) 2026-10-07 14:07:43 -07:00
test_amazon_nova_transformation.py fix(bedrock): honor batch drop_params for guarded parts on Nova records 2026-11-14 01:21:19 -08:00
test_amazon_openai_transformation.py test: migrate tests/llm_translation into unit, integration and e2e tiers (#45759) 2026-10-11 07:58:53 +00:00
test_amazon_qwen2_transformation.py chore(typing): clear 670 basedpyright Any errors by validating provider payloads at the boundary (#45388) 2026-10-13 15:35:23 -07:00
test_amazon_qwen3_transformation.py chore(typing): clear 670 basedpyright Any errors by validating provider payloads at the boundary (#45388) 2026-10-13 15:35:23 -07:00
test_base_invoke_transformation.py fix: drop only the invalid control option under drop_params 2026-11-14 04:42:25 -08:00
test_bedrock_chat_invoke_transformations_anthropic_claude3_transformation.py fix(anthropic): answer 400 for a raised extra_body max_tokens and promote system on Azure AI 2026-11-19 22:54:41 -08:00
test_twelvelabs_pegasus_transformation.py test(llms): migrate bedrock, baseten and base_llm batch tests to tests/unit 2026-09-20 07:51:50 +00:00