mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-07 08:26:10 +00:00
streaming_handler.py: EndpointType.ANTHROPIC was missing from the cost
injection block — only VERTEX_AI was handled, so Anthropic passthrough
streaming never got cost injected into message_delta chunks even with
include_cost_in_streaming_usage: true.
test_anthropic_passthrough.py: AnthropicResponsesStreamWrapper yields
full multi-line SSE frames as single bytes objects (e.g.
"event: message_delta\ndata: {...}\n\n"). The tests were checking
startswith('data: ') on the whole chunk, which starts with 'event:',
so every message_delta event was silently skipped. Fix: split each chunk
by \n before checking for the data: prefix. Also removes the
@pytest.mark.skip added with wrong diagnosis on the OpenAI model test.
|
||
|---|---|---|
| .. | ||
| ruby_passthrough_tests | ||
| base_anthropic_messages_test.py | ||
| test_anthropic_passthrough.py | ||
| test_anthropic_passthrough_basic.py | ||
| test_anthropic_passthrough_python_sdkpy | ||
| test_assembly_ai.py | ||
| test_gemini.js | ||
| test_gemini_with_spend.test.js | ||
| test_hosted_vllm_passthrough.py | ||
| test_local_gemini.js | ||
| test_local_vertex.js | ||
| test_mcp_routes.py | ||
| test_openai_assistants_passthrough.py | ||
| test_vertex.test.js | ||
| test_vertex_ai.py | ||
| test_vertex_with_spend.test.js | ||
| vertex_key.json | ||