litellm/tests/unit/responses
mateo-berri a88ab1c4c2 fix(responses)!: raise the mapped error when a non-streamed response comes back failed
A non-streamed Responses create that comes back HTTP 200 with status failed now raises the
same mapped error the streamed path raises for response.failed, so context window fallbacks
and other fallbacks run and the request is logged as a failure. Usage on a failed body is
billed on the failure row, and a success row no longer reads usage a failed round stashed on
the shared logging object. The gpt-oss max_model_len overflow wording maps to a context
window error, and Perplexity's own failed-body check is replaced by the shared one.

Port of the main branch fix to lts/1.108.x.
2026-12-04 17:53:26 -08:00
..
litellm_completion_transformation Merge pull request #56085 from BerriAI/litellm_responses_bridge_owned_keywords_lts_devin 2026-12-03 20:39:43 +00:00
mcp fix(streaming): keep stream-end logging when the client disconnects during final pricing 2026-12-02 08:01:12 -08:00
__init__.py ci: move provider-independent MCP tests into tests/unit and run mcp-integration from litellm-tests (#42904) 2026-09-24 23:07:48 +00:00
test_additional_tools.py test: move tests/test_litellm core utils, routing, responses, caching and rust_bridge into tests/unit (#43199) 2026-09-25 17:10:13 -07:00
test_custom_tool_call.py test: move tests/test_litellm core utils, routing, responses, caching and rust_bridge into tests/unit (#43199) 2026-09-25 17:10:13 -07:00
test_dispatch.py refactor(python-bridge): ship a signature base and read the resolved call (#45450) 2026-10-08 17:20:29 -07:00
test_metadata_codex_callback.py test: move tests/test_litellm core utils, routing, responses, caching and rust_bridge into tests/unit (#43199) 2026-09-25 17:10:13 -07:00
test_no_duplicate_spend_logs.py test: move tests/test_litellm core utils, routing, responses, caching and rust_bridge into tests/unit (#43199) 2026-09-25 17:10:13 -07:00
test_null_test_fix.py test: move tests/test_litellm core utils, routing, responses, caching and rust_bridge into tests/unit (#43199) 2026-09-25 17:10:13 -07:00
test_responses_api_bridge_flag.py fix(responses): forward caller fields named like bridge keywords instead of answering 500 2026-11-25 12:42:50 -08:00
test_responses_api_lifecycle.py test: make 77 legacy live tests offline in litellm_utils, router_unit and responses dirs (#45298) 2026-10-08 02:37:55 -07:00
test_responses_api_request_body.py fix(responses): strip Gemini signatures on WebSocket frames and token counts, keep them for litellm_proxy 2026-12-02 05:51:45 -08:00
test_responses_prompt_management.py fix(sdk): backport #45961 to lts/1.108.x 2026-11-07 17:55:52 -08:00
test_responses_router_cooldown.py test(responses): inject a refusing transport through the handler's client factory 2026-11-24 02:25:44 +00:00
test_responses_streaming_iterator.py fix(responses): free a drained stream without a cycle collection 2026-11-27 04:16:26 +00:00
test_responses_supported_endpoints_passthrough.py test: move tests/test_litellm core utils, routing, responses, caching and rust_bridge into tests/unit (#43199) 2026-09-25 17:10:13 -07:00
test_responses_utils.py fix(responses): forward caller fields named like bridge keywords instead of answering 500 2026-11-25 12:42:50 -08:00
test_responses_websocket_all_providers.py fix(responses): strip Gemini signatures on WebSocket frames and token counts, keep them for litellm_proxy 2026-12-02 05:51:45 -08:00
test_rust_bridge_websocket.py test: move tests/test_litellm core utils, routing, responses, caching and rust_bridge into tests/unit (#43199) 2026-09-25 17:10:13 -07:00
test_sse_output_recovery.py test: move tests/test_litellm core utils, routing, responses, caching and rust_bridge into tests/unit (#43199) 2026-09-25 17:10:13 -07:00
test_streaming_iterator.py fix(responses)!: raise the mapped error when a non-streamed response comes back failed 2026-12-04 17:53:26 -08:00
test_streaming_iterator_error_events.py fix(responses)!: raise the mapped error when a non-streamed response comes back failed 2026-12-04 17:53:26 -08:00
test_text_format_conversion.py refactor: expose core private helpers under public names (#44871) 2026-10-07 00:05:27 +00:00