On windows terminal when ssh to a linux host it render error

Resolved 💬 21 comments Opened Oct 5, 2025 by andjohnsonj5 Closed Nov 14, 2025
💡 Likely answer: A maintainer (github-actions[bot], contributor) responded on this thread — see the highlighted reply below.

What version of Codex is running?

v0.44.0

Which model were you using?

gpt-5-codex

What platform is your computer?

Linux 6.12.43+deb13-amd64 x86_64 unknown

What steps can reproduce the bug?

on windows terminal, ssh to a linux host, then execute codex

What is the expected behavior?

The rendering of the input box should be normal.

What do you see instead?

<img width="1150" height="545" alt="Image" src="https://github.com/user-attachments/assets/8f469397-5277-4da0-b5af-4aab1e9fc2de" />

Additional information

it leaks some string

› 10;rgb:cccc/cccc/cccc11;rgb:0c0c/0c0c/0c0c

It's more likely to happen when the network is unstable.

View original on GitHub ↗

21 Comments

github-actions[bot] contributor · 9 months ago

Potential duplicates detected:

  • #4749
  • #4744

Powered by Codex Action

andjohnsonj5 · 9 months ago

I dug into this today and it looks like this report is separate from the tmux background/palette issues that were tracked in #4744/#4747.\n\nWhat is happening here: when we regain terminal focus we call , which emits the OSC 10/11 queries ( / ). Those responses come back over the same PTY and crossterm delivers each printable byte as a key event. Because the input stack treats them as real keystrokes, they get appended to the composer, so you see strings like .\n\nIn other words, this is not the background rendering bug fixed by #4747; it is that the OSC response stream bleeds into user input. We need to either filter OSC sequences out of the event loop (so they never reach handling) or change the default-color querying strategy so the replies are consumed out-of-band (e.g. via a raw read that does not race with the input loop).],

andjohnsonj5 · 9 months ago

@bolinfest

andjohnsonj5 · 9 months ago

@dylan-hurd-oai

TaoSeekAI · 9 months ago

ubuntu 24
same issue

superido245w · 9 months ago

The same problem occurs when trying to SSH to Ubuntu 24 using macOS Terminal, Tabby, or Visual Code. Because of the same color detection problem, Codex Resume has become unavailable and the history conversation list cannot be successfully displayed.

vbmania · 9 months ago

The same issue occurs in macOS 0.45.0

<img width="591" height="151" alt="Image" src="https://github.com/user-attachments/assets/9f477d49-5051-4478-9a81-f2b816759ed6" />

linQian99 · 9 months ago

same here

pixeldepartment · 9 months ago

same here

claytongentry · 9 months ago

I notice when it leaks this string, oftentimes if I've been prompted to permit a command, the first result in the selection ("Yes") is automatically selected when I focus the terminal window, without me hitting Enter. This is significantly more problematic — even potentially dangerous — than the character leak itself. Raising because they seem to occur together.

stewartcelani · 9 months ago

Yep me too.

stan1233 · 9 months ago

me too.
OpenAI Codex (v0.46.0)

jiangying000 · 9 months ago

same when macos sshed to remote ubuntu
codex-cli 0.46.0

stan1233 · 9 months ago
same when macos sshed to remote ubuntu codex-cli 0.46.0

me too. macos sshed to remote ubuntu.

jiangying000 · 9 months ago
same when macos sshed to remote ubuntu codex-cli 0.46.0

This also happens when I'm using codex locally in macos terminal APP, though less often

Kiyliy · 9 months ago

same issue

<img width="1267" height="441" alt="Image" src="https://github.com/user-attachments/assets/b803e84e-a9ef-4981-bf11-95a5c22fd2e7" />

Shunxing-Fan · 9 months ago

<img width="749" height="121" alt="Image" src="https://github.com/user-attachments/assets/11a1bd85-2e86-4bb0-b769-897f63b2428d" /> me too

happyme531 · 9 months ago

Same issue on Cursor.
Maybe related: https://github.com/microsoft/vscode/issues/207545

IANTHEREAL · 8 months ago

Had it been fixed?

foreverpiano · 8 months ago

same, how to fix?

etraut-openai contributor · 8 months ago

I think this has been fixed in recent versions. If you're still seeing this in the latest version, let us know.