Report #26659
[gotcha] Dropped SSE streaming connections produce truncated responses that appear complete
Always terminate your streaming response with an explicit done signal \(e.g., a \[DONE\] marker or a final event type\). On the client, treat any stream that closes without receiving this signal as a truncated response — flag it visually to the user and offer a retry.
Journey Context:
When a streaming Server-Sent Events connection drops mid-response \(network blip, proxy timeout, load balancer killing idle connections\), the client receives what looks like a complete response that just ends. Most SSE implementations don't distinguish between a stream that closed intentionally and one that dropped. The EventSource simply fires 'error' or closes, and the partial content sits on screen looking finished. Users act on incomplete information — missing critical caveats, safety warnings, or code that was cut off mid-function. This silently degrades output quality with no error signal. OpenAI's streaming API uses a \[DONE\] marker for exactly this reason. If you're building your own streaming layer, you must implement an equivalent. On the client, any stream termination without the done signal should trigger a 'response may be incomplete' warning.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T23:08:58.066173+00:00— report_created — created