You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: DeepSeek stream terminated at ~4 minutes — API closes connection mid-stream (after #16201 fix) #16371
After upgrading to v0.8.8-rc4, which includes the fix from PR #16201 for the 5-minute undici timeout (issue #16195), a new and different termination occurs.
Agent and Preset runs using the custom DeepSeek endpoint now terminate after approximately 4 minutes with:
The model provider could not complete this request.
terminated
This is NOT the previous undici body/header timeout. Testing with NODE_DEBUG=undici,http,net shows the following sequence:
There is no bodyTimeout, no headersTimeout, and no ECONNRESET. The remote server (api.deepseek.com) closes the TCP connection after roughly 4 minutes of streaming.
HTTP 200 was received before the connection closed, so the request itself was accepted. The failure is on the response streaming.
This happens in both standard chat and Agent modes, and in Edge, Firefox, Chrome, and Opera, so it is not browser-specific.
Expected behaviour: The stream should continue until the model finishes, or LibreChat should retry when the connection is closed by the provider.
Actual behaviour: The stream terminates at ~4 minutes and the user sees a generic error.
Use the custom DeepSeek endpoint with deepseek-v4-pro and reasoning_effort: high.
Start a new conversation (standard chat or Agent).
Send a prompt that requires extended reasoning (more than 4 minutes of thinking).
Wait approximately 4 minutes.
Observe the termination error.
What browsers are you seeing the problem on?
Chrome, Firefox, Microsoft Edge
Relevant log output
UNDICI 26: received response to POST https://api.deepseek.com/v1/chat/completions - HTTP 200
...streaming for~4 minutes...
NET 26: close handle
NET 26: emit close
UNDICI 26: request to POST https://api.deepseek.com/v1/chat/completions errored - other side closed
2026-09-25 14:26:46 error: [api/server/controllers/agents/client.js #sendCompletion] Upstream model error
{"userId":"[REDACTED]","requestId":"846b13d6-4991-44bb-8794-096c4eb4e743","request_method":"POST","request_path":"/api/agents"}
Activity