litellm/tests/test_litellm/llms/bedrock/chat
tin d39c557743 fix(bedrock): drop conflicting tool_choice.type when toolConfig.toolChoice is set
Converse rejects a request that carries both toolConfig.toolChoice and an
additionalModelRequestFields.tool_choice.type, so any request that pairs
parallel_tool_calls with an explicit tool_choice 400s with "The additional field
tool_choice/type conflicts with the existing field toolConfig.toolChoice.auto".
That pairing is what agentic clients send by default; Codex CLI sends
tool_choice "auto" and parallel_tool_calls false on every turn, so tool calling
was broken outright on Bedrock models that advertise
supports_parallel_tool_use_config.

Drop the type from the Anthropic passthrough once toolChoice carries it, and keep
disable_parallel_tool_use, which has no toolConfig equivalent and is accepted
alongside toolChoice. Measured against Bedrock directly: toolChoice plus
{disable_parallel_tool_use} succeeds for auto, any and tool, while an empty
tool_choice with no toolChoice is rejected for a missing type, so the type still
has to be emitted when the caller sends no tool_choice.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-08-04 03:50:33 +00:00
..
agentcore fix(tests): remove importlib.reload of http_handler that breaks client injection in later tests (#34336) 2026-07-23 01:11:35 +00:00
invoke_transformations fix(bedrock): map guardrailConfig to InvokeModel guardrail headers (#31985) 2026-07-02 18:58:30 -07:00
test_converse_transformation.py fix(bedrock): drop conflicting tool_choice.type when toolConfig.toolChoice is set 2026-08-04 03:50:33 +00:00
test_converse_transformation_nova_2.py feat(bedrock): broaden Nova 2 model detection to support nova-2-pro reasoning 2026-02-16 20:35:00 -08:00
test_invoke_handler.py refactor(bedrock): remove the dead BedrockLLM invoke code path 2026-07-29 20:25:36 -07:00
test_mistral_config.py Litellm fix GitHub action testing (#11163) 2025-05-26 14:41:42 -07:00
test_service_tier.py feat(bedrock): add OpenAI-compatible service_tier parameter translation (#18091) 2026-01-12 17:28:49 +05:30
test_streaming_choice_index.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
test_writer_palmyra.py [Feat] New model - add bedrock writer models (#17685) 2025-12-08 17:49:06 -08:00