mirror of
https://github.com/openai/codex.git
synced 2026-11-18 22:20:48 +00:00
## Why A Cloud conversation can miss an entire turn while disconnected. A successful reattach, even with an idle thread, cannot establish that the client's history is complete. ## What changed Add an app-server client operation that reattaches a disconnected, loaded Cloud thread and returns its cached settings. The worker holds the replacement stream so the caller can refresh turn and item history before explicitly installing the stream and receiving buffered events. Reattachment, recovery history reads, and stream installation share a deadline and use the original Cloud sign-in and network permit. Dropping the release handle cancels the replacement. Personal access token sessions still reconnect by reopening the conversation. ## Testing Extend Cloud connection tests to cover quiet and busy reattachments, buffered event delivery, cancellation and retry, slow history reads, and sign-in changes during recovery. GitOrigin-RevId: a4e5cb967e097021596bc83aac2f8d1a95373712