openai / openai/codex

[Windows] Caret does not advance after typing in content copied from Codex

Open
#41,180 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

app bug windows-os
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.820.71523

What subscription do you have?

ChatGPT Prolite

What platform is your computer?

Microsoft Windows NT 10.0.26200.0 x64

What issue are you seeing?

When I copy text generated by Codex and paste it into the Codex input/editor, subsequent typing can cause the caret position to behave incorrectly.

The newly typed character is inserted at the correct location, but the caret does not advance past that character.

For example, using | to represent the caret:

Before typing D:
ABC|

Expected:
ABCD|

Actual:
ABC|D

Typing text manually without first pasting Codex-generated content works normally.

The issue only appears after pasting content copied from Codex output.

What steps can reproduce the bug?
  1. Open a local Codex conversation in the Windows Codex App.
  2. Copy text from a Codex-generated response.
  3. Paste that copied text into the Codex input/editor.
  4. Place the caret at the end of the pasted content.
  5. Type another character.

For example:

Before:
ABC|

Type:
D

Expected:
ABCD|

Actual:
ABC|D
  1. Repeat the same test by manually typing equivalent text instead of pasting Codex-generated content.

Manually typed text behaves normally; the caret advances correctly.

What is the expected behavior?

After a character is inserted, the caret should move to the position immediately after the newly inserted character.

For example:

ABC| + D

should become:

ABCD|
Additional information

This appears to be specifically associated with content copied from Codex output.

I confirmed that manually typed content does not reproduce the issue.

There is a potentially related Windows Codex App issue involving CRLF/rendering behavior:

#35232

That issue concerns blank-line rendering and preserved CRLF content. It does not appear to report this caret-position behavior, so I am filing this separately.

I first noticed this after a recent Codex App update.

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

No source file or test is named. Reproduce the issue in the Windows Codex App by comparing caret behavior after pasting Codex-generated text with manually typed equivalent text, then trace the input/editor caret handling. Done means typing after pasted content leaves the caret immediately after each inserted character without affecting the manual-typing case.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
desktop
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.