Streaming/SSE fails silently in GUI
Goose Desktop fails to display streaming responses from custom OpenAI‑compatible provider, even though the provider returns valid SSE and non‑streaming works correctly.
This my be related to #3786 and #4685 (custom provider integration issues), but specific to streaming mode.
Environment
- OS: Windows Desktop app
- Goose: Latest Desktop build (as of 2025‑12‑18)
- Mode: Autonomous
Provider: Custom OpenAI‑compatible /v1/chat/completions endpoint
Steps to reproduce
- Configure custom provider with engine: "openai", supports_streaming: true
- Send prompt in Autonomous mode
- Observe: Request sent with stream: true, provider returns valid SSE chunks, Goose UI shows nothing
- Change supports_streaming: false, resend prompt
- Observe: UI displays full response correctly
What works
- Non‑streaming responses from same provider
- SSE stream from provider (verified via Bruno HTTP client)
- Goose receives the request (confirmed in logs)
What doesn't work
- Streaming responses displayed in Goose UI
- Silent failure—no error message or timeout
- Example valid SSE response from provider
Example streamed response (sanitized) This is an example of what the provider returns when stream: true is set. Each line is a separate SSE data: frame:
data:{"id":"chat","object":"chat.completion.chunk","created":1766073356,"choices":[{"index":0,"delta":{"role":"assistant","content":""}}],"model":"glm-4.6"}
data:{"id":"chat","object":"chat.completion.chunk","created":1766073356,"choices":[{"index":0,"delta":{"content":"\nHello","reasoning_content":""}}],"model":"glm-4.6"}
...
data:{"id":"chat","object":"chat.completion.chunk","created":1766073357,"choices":[{"index":0,"delta":{"content":" to help you with today?","reasoning_content":""}}],"model":"glm-4.6"}
data:{"id":"chat","object":"chat.completion.chunk","created":1766073357,"usage":{"prompt_tokens":7840,"completion_tokens":49,"total_tokens":7889},"choices":[{"index":0,"finish_reason":"stop","delta":{"content":""}}],"model":"glm-4.6"}
Note:
Every chunk has object: "chat.completion.chunk" and choices[0].delta.content, matching the usual OpenAI streaming shape. The last chunk includes finish_reason: "stop" and usage. When replayed with another HTTP client, the stream is readable and decodes to the expected text.