Skip to content

Tab completion for slash commands doesn't move cursor to end of completed text #2429

@mkusaka

Description

@mkusaka

What version of Codex is running?

codex-cli 0.22.0

Which model were you using?

gpt-5

What platform is your computer?

Darwin 24.6.0 arm64 arm

What steps can reproduce the bug?

  1. Start codex
  2. Type /c (cursor is right after the 'c')
  3. Press Tab key to complete to /compact (which appears as the filtered candidate)
  4. The text /compact is inserted, but the cursor remains at position 2 (after /c) instead of moving to the end of the completed text

What is the expected behavior?

When tab completion inserts /compact, the cursor should move to the end of the completed text (position 8, after /compact).

What do you see instead?

The text /compact is correctly inserted, but the cursor stays at position 2 (after /c), making it difficult to continue typing. Users need to manually move the cursor to the end to continue input.

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions