litellm/tests/unified_google_tests
Sameer Kankute 729b005e4e
fix(google_genai): preserve complete SSE events in Vertex/Gemini image streaming (#30270)
* fix(google_genai): preserve complete SSE events in image streaming

Use iter_lines/aiter_lines instead of byte chunking so large inlineData
base64 payloads from Vertex/Gemini streamGenerateContent are not split
across events, which caused truncated JSON and SDK parse failures.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix(google_genai): buffer SSE lines until event delimiter

Assemble multi-field SSE events on blank-line boundaries instead of
terminating each field line individually.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix(tests): update google_ai_studio mocks from aiter_bytes to aiter_lines

Streaming iterator was changed to use iter_lines/aiter_lines instead of
iter_bytes/aiter_bytes. Update the two mocked streaming responses in
test_google_ai_studio.py to match.

Co-authored-by: Cursor <cursoragent@cursor.com>

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-12 07:49:30 -07:00
..
base_google_genai_proxy_sdk_test.py test(google): add google-genai SDK proxy integration tests (#29781) 2026-06-05 21:05:32 +00:00
base_google_test.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
base_interactions_test.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
conftest.py test(google): add google-genai SDK proxy integration tests (#29781) 2026-06-05 21:05:32 +00:00
google_genai_proxy_test_config.yaml test(google): add google-genai SDK proxy integration tests (#29781) 2026-06-05 21:05:32 +00:00
test_gemini_interactions.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
test_google_ai_studio.py fix(google_genai): preserve complete SSE events in Vertex/Gemini image streaming (#30270) 2026-06-12 07:49:30 -07:00
test_litellm_responses_bridge.py chore(ci): modernize model references in tests and configs (#27856) 2026-05-15 15:44:28 -07:00
test_vertex_ai_native.py test(google): add google-genai SDK proxy integration tests (#29781) 2026-06-05 21:05:32 +00:00
test_vertex_anthropic.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
vertex_key.json test: update to new vertex ai keys 2026-03-28 20:19:05 -07:00