openai / openai/codex

stream disconnected before completion: stream closed before response.completed (regression in 26.825.51511)

Open
#41,989 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

app bug connectivity custom-model windows-os
Dominant language
Rust
Stars
125k
Forks
19.4k
PR merge metrics
PR metrics pending

Description

Description

Since version 26.825.51511 (released 2026-08-30), every response ends with a reconnect error:

stream disconnected before completion: stream closed before response.completed

The issue did not occur on the previous version. Timing matches the regression reported in #41799.

Environment

  • App version: 26.825.51511 (released 2026-08-30)
  • OS: Windows 11
  • wire_api:
    esponses\
  • Custom provider: third-party OpenAI-compatible endpoint

Config (redacted)

\\ oml
[model_providers.custom]
base_url = 'https:///v1'
wire_api = 'responses'
supports_websockets = false
\\

Steps to reproduce

  1. Configure a custom provider with \wire_api = 'responses'\
  2. Send any message
  3. After response generation, Codex shows reconnecting error and the message above

Expected behavior

Response completes normally without reconnect errors.

Additional notes

The upstream provider sends a valid SSE stream and closes the connection normally, but Codex does not receive the
esponse.completed\ event before the stream closes, triggering the reconnect loop. This behavior started with 26.825.51511 and did not occur on the prior version.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the issue with a custom provider using wire_api = 'responses' and supports_websockets = false, then trace the response stream and reconnect handling. Compare behavior with the previous version and verify that a valid SSE stream closing after response generation completes without a reconnect error.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
api
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
65/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.