Repository navigation
Description
Summary
Codex Desktop on macOS repeatedly stalls on Connecting/Reconnecting during image/video workflows. One long conversation recovered after WebSocket-to-HTTP fallback, but later the HTTP retry itself waited over 15 minutes and returned 408. A separate newer conversation also disconnected.
Related: #55730 and #18960. This report adds HTTP-fallback timeout evidence and a separate newer-conversation observation. Please merge/close as a duplicate if appropriate.
Environment
- macOS 26.2, Apple Silicon arm64; ChatGPT sign-in.
- Incident logs record Desktop client
26.1021.31345and core client0.164.0(not a fresh binary-version assertion). - Models:
gpt-6.1-solin the older conversation;gpt-6-astrain the newer one. - Clash/Mihomo TUN via a VPS proxy, with WARP egress for ChatGPT/OpenAI. Proxy/network involvement has not been ruled out.
- All timestamps below: 2026-10-25, UTC.
A: WebSocket retries followed by slow HTTP recovery
- 05:35:55: turn started.
- 05:36:00–05:36:20: retries 1/5 through 5/5:
stream disconnected before completion: IO error: Broken pipe (os error 32). - Reconnection handshakes succeeded between failures.
- 05:36:28:
falling back to HTTP; zstd request bodypre_compression_bytes=39290701 post_compression_bytes=28884008. - 05:44:37: HTTP 200, about 8 minutes 9 seconds after fallback request preparation.
- 05:44:40: assistant output resumed.
These are HTTP body sizes, not captured failed WebSocket payload sizes.
B: later HTTP streaming failure and 15-minute timeout
In the same conversation:
- 08:27:03: HTTP request
pre_compression_bytes=52496891 post_compression_bytes=38685415. - 08:42:13: HTTP 200 response headers logged.
- 08:42:17: streaming failed:
Transport error: network error: error decoding response body. - 08:42:17: retry request
pre_compression_bytes=52497435 post_compression_bytes=38685580. - 08:57:30:
408 Request Timeout, approximately 15 minutes 13 seconds after retry preparation. - Another similarly sized request was prepared immediately afterwards.
- Recorded context: 338,783 tokens, below the recorded 450,000-token auto-compaction threshold.
C: a newer conversation also disconnected
This is a separate observation, not proof of the same root cause:
- Context: 86,401 tokens.
- 15:02:15: retry 1/5:
websocket closed by server before response.completed. - 15:02:16: WebSocket reconnected successfully.
- 15:03:39: retry 2/5:
IO error: Broken pipe (os error 32). - 15:03:40: WebSocket reconnected successfully.
- No HTTP fallback had appeared at inspection time. Request byte size and Close code were unavailable for this case.
Reproduction and limitations
Observed during extended image/video workflows with retained history and multiple tool calls. No deterministic minimal reproduction yet.
Large HTTP bodies and retained historical images make request size a plausible contributor in A/B, but do not prove a specific WebSocket limit or a shared root cause for every disconnect. Logs do not distinguish upload time, network/intermediary delay, and backend waiting. Stable short ICMP tests do not rule out large-transfer or proxy issues.
Expected behavior / investigation request
- Preserve WebSocket Close code/reason; distinguish transient failures from explicit size rejection.
- Consider serialized-byte budgets, including retained images, separately from token-based compaction.
- Avoid unchanged retries when an explicit size rejection is identified, and choose a supported recovery path.
- Investigate HTTP fallback stalls/timeouts rather than assuming fallback alone resolves the problem.
- Show actionable progress (retrying, changing transport, waiting for response), instead of prolonged generic Connecting/Reconnecting.
Only sanitized diagnostic excerpts are included: no credentials, private prompts/images, raw transcripts, local paths, proxy addresses, or account/conversation identifiers.
Prepared from local logs and submitted by an assistant at the user's explicit request.
Activity
github-actions commentedon Oct 25, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
chipfighter commentedon Oct 29, 2026
@maomaoyu403 Waiting more than 15 minutes to continue an image-heavy task sounds rough. For the retained-picture part of your workflow, I built Context Attachment Manager after repeated character-image revisions kept making my Codex chat reconnect. I'm the author.
It's free and open source, currently v0.9.1 with 560 GitHub Stars. People facing similar image-history problems are using it and sharing feedback. After installation and restarting Codex, automatic selection is on by default. The assistant retrieves originals when needed, including after compaction, instead of carrying every old image into each turn.
The panel gives you thumbnails, search by remembered visual details, zoomable previews, and control over references to keep selected. Original quality and conversation records are preserved. Management stays on your machine; the plugin doesn't separately collect or upload your pictures or chats.
https://github.com/chipfighter/context-attachment-manager
The page has setup steps. Once you're comfortable with it, you can ask Codex or Claude Code to install it for you. It supports Codex Desktop and the local Code tab in Claude Desktop.
If you're still doing visual work in Codex Desktop, I'd welcome a try and your feedback on whether reducing the carried image history helps in your case.
olafchou commentedon Nov 4, 2026
Additional observations: Desktop 26.1029.61003 / CLI 0.166.0-alpha.6, retained image history and repeated per-chat stalls
Adding local observations from 2026-11-04 to this existing issue. The account owner explicitly requested this feedback. These observations resemble the reported symptoms; they do not establish an identical root cause.
Environment
OpenAI, withrequires_openai_auth=true,supports_websockets=true, Responses API, and no custom base URL. Diagnostic CLI probes also used temporary overrides that ignored user provider/plugin configuration; those overrides were not applied globally to the affected chats.User-visible failure
Two established image-heavy chats repeatedly stopped making progress while remaining active in the sidebar/Thinking state. Stopping and sending a text-only “continue” did not reliably recover the same chats. Other requests could complete during the investigation, so this was not a demonstrated total connectivity outage.
This significantly interrupts ordinary multi-turn visual work. The UI does not clearly distinguish uploading retained context, waiting for a response, retrying a failed transport, and actual model thinking. A brief successful tool call can be followed by another prolonged stall.
Application log measurements
Two observed HTTP request preparations recorded:
These are serialized request-body sizes reported by the client, not measurements of how many bytes the remote server accepted. Later preparations were almost unchanged in size despite short text follow-ups.
Observed errors included:
In the HTTP phase, some consecutive preparation/failure/retry events were approximately 10 minutes apart. Earlier WebSocket observations also included repeated failures around 81 seconds after upgrade. These timings vary by request and are not presented as a universal timeout or payload limit.
Controls and bounded upload experiments
PROBE_OK, andresponse.completedin approximately 6.5, 7.6, 9.8, and 10.8 seconds. These were actual authenticated model requests, not Google latency tests or WebSocket-upgrade checks.turn.completedin 73.45 seconds. This was not a strict same-route/same-time comparison with every later failure.PROBE_OK. The JSON was 18,887,481 bytes, zstd-compressed to 14,170,239 bytes. Distinct images avoided a misleadingly tiny compressed body caused by duplicating identical bytes.TimeoutError; total elapsed 70.73 seconds.BrokenPipeError; 125.89 seconds.TimeoutError; 44.70 seconds.Content-Length, sending the body in 64 KiB application chunks. Counts above mean bytes accepted by successful local send calls, not proof of remote application receipt. It had bounded timeouts; its 15-second per-write timeout could fail earlier than the Desktop client's retry cycle.The observation that a small request works therefore does not establish that a large retained-history request will work. Conversely, these failures alone do not prove a Codex-only bug or exclude network/proxy causes. A separate earlier fresh-chat failure involved a much smaller compressed body, so no single fixed size threshold has been established.
Recovery observed
With the user's authorization, we created two new chats with concise text-only handoffs and local file paths, without copying the old image history. Both produced assistant commentary and completed multiple real tool calls. The old chats were then archived through the normal app interface; their active turns were confirmed interrupted and their records preserved.
This is an observed workaround, not proof of a permanent fix or that the underlying visual tasks were completed. The user should not have to repeatedly rebuild chats to continue routine work.
Reproduction scope
The user-observed sequence is:
There is no fully deterministic minimal application reproduction yet. The synthetic upload experiment is a separate control, not an exact reproduction of the original conversation.
Requested engineering investigation
Related symptom reports: #32555, #45921, #57725. These references are not assertions that every report has the same cause.
Privacy: This comment contains only sanitized measurements and error categories. No credentials, subscription URLs, node names/addresses, account or conversation IDs, private prompts/images, raw transcripts, local paths, or original screenshots are included. TLS verification was not disabled; conversation history was not rewritten and databases were not reset.
942377949 commentedon Nov 6, 2026
Additional reproduction: automatic compaction fails before a text-only reply
Affected macOS application logs record Desktop 26.1029.61003 and bundled CLI 0.166.0-alpha.6 (ChatGPT sign-in). An established image-heavy conversation repeatedly stalls even when the follow-up requests only a short text reply and prohibits file operations.
Observed results:
Broken pipe (os error 32); the client fell back to HTTP and eventually replied.run_pre_sampling_compact,reason=ContextLimit,phase=PreTurn.websocket closed by server before response.completed. The original Sol/medium setting has been restored.A successful WebSocket handshake was not sufficient for successful compaction. We did not capture the serialized failing WebSocket message size or Close 1009, so this does not establish a specific payload limit or an identical root cause to other reports.
In-app feedback with diagnostics has already been submitted successfully. Its ID can be provided privately if maintainers need it. No private conversation title/ID, prompts, images, credentials, raw transcripts, or local file paths are included in this comment.
Please advise whether there is an official fix or supported in-place recovery that preserves the original conversation and source files, without manual JSONL/SQLite edits or requiring a new conversation.