Issue #3586425: Resolve "ai_ckeditor: streamGenerateContent causes 400 Bad Request with Gemini 2.x models"
Description
Testing instructions
- Follow the instructions here: https://project.pages.drupalcode.org/ai/1.3.x/contribute/testing/full_patch_test/#setup-ai-ckeditor
- Try with a provider that allows streaming (OpenAI) - it should stream.
- Try with a provider that doesn't allow streaming (Gemini) - it should sit and wait and come in one dump.
Checklist
- I have linked the related issue in the MR title or description
- I have performed a self-review of my own code
- I have written testing instructions and verified them locally
AI Compliance
Note
Check the one that best describes your usage, or leave all unchecked if AI was not significantly used.
- AI Assisted Code
Mainly written by a human; AI used for autocomplete or partial generation under full human supervision. - AI Generated Code
Mainly generated by AI, reviewed and approved by a human before this MR was created. - Vibe Coded
Generated by AI and only functionally reviewed before this MR was created.
Closes #3586425
Edited by Marcus Johansson