[Windows] Remote Control enrollment and WebSocket succeed, but pairing says enrollment is incomplete
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 125k
- Forks
- 19.4k
- PR merge metrics
- PR metrics pending
Description
What version of the Codex App are you using (From “About Codex” dialog)?
26.901.6511.0
What subscription do you have?
Pro
What platform is your computer?
Windows 10 Pro 22H2, Build 19045, x64
What issue are you seeing?
Remote Control successfully enrolls this Windows PC and establishes the Remote Control WebSocket connection, but attempting to pair a mobile device fails with:
“Pairing code unavailable: remote control pairing is unavailable until enrollment completes.”
The failure continues even though Codex's local state and logs show that enrollment has completed and Remote Control has reached the Connected state.
Troubleshooting confirmed:
- ChatGPT authentication is working.
- Desktop app-server initializes successfully.
- OpenAI HTTP endpoints are reachable.
- WebSocket handshake succeeds with HTTP 101.
- Remote Control enrollment is successfully persisted.
- remote_control_enabled = 1.
- Remote Control WebSocket reaches Connected.
- Logs show has_enrollment=true.
- remoteControl/pairing/start reaches the app-server.
I also performed a complete Remote-only identity reset. Codex generated a new installation ID, new server ID, and new environment ID, successfully enrolled the new identity, and connected its Remote WebSocket. The exact same pairing error remained.
Earlier troubleshooting exposed an HTTP 409 Conflict with {"detail":"Remote app server already online"}. A complete shutdown of ChatGPT/Codex processes cleared that conflict, and subsequent logs confirmed the Remote WebSocket connected successfully. Pairing still failed afterward.
codex doctor --json while the Desktop app is running reports the Desktop app-server handshake, authentication, installation, HTTP reachability, WebSocket reachability, and database integrity as OK.
Expected: Once Remote enrollment is complete and the Remote WebSocket is connected, clicking Add should generate a QR/manual pairing code.
Actual: The desktop continues to say pairing is unavailable until enrollment completes.
Codex CLI version: 0.153.4
I have retained the relevant logs, request IDs, old/new Remote identifiers, and Doctor output and can provide sanitized diagnostic data if needed.
What steps can reproduce the bug?
- Launch Codex Desktop on Windows 10 Pro 22H2.
- Sign into ChatGPT.
- Open Settings → Connections.
- Enable Allow connections.
- Wait for Remote Control enrollment and connection.
- Confirm logs show the enrollment persisted and Remote WebSocket status Connected.
- Click Add to pair a mobile device.
- Desktop displays: “Pairing code unavailable: remote control pairing is unavailable until enrollment completes.”
- Structured logs nevertheless show remoteControl/pairing/start reaching the app-server.
What is the expected behavior?
After Remote Control enrollment completes and the Remote WebSocket reaches Connected, clicking Add should generate a QR code or manual pairing code so the mobile device can connect.
Additional information
This appears related to #32164 (“Remote Control enrollment never completes on Windows”). I am submitting this report because I was able to confirm additional diagnostic details: Remote enrollment successfully persists, the Remote WebSocket reaches Connected, the Desktop app-server handshake passes, and the problem survives generation of a completely new installation ID, server ID, and environment ID. I can provide sanitized logs and the full codex doctor --json report if useful.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the remoteControl/pairing/start handling and the enrollment state reported by logs, then reproduce on Windows with the Remote WebSocket connected and has_enrollment=true. Compare the pairing-availability check with the successful enrollment and connection states; done means Add produces a QR or manual pairing code after enrollment completes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- desktop, networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100