Skip to content

Mouse wheel SGR input leaks into composer and interrupts active turn in fullscreen TUI (0.157.1, cmux) #49184

Closed

Description

@robinhur

Summary

In Codex CLI 0.157.1's default fullscreen TUI inside cmux, scrolling down with a mouse wheel can leak SGR mouse-report text into the composer and interrupt an active turn. I reproduced this while scrolling with a Nape Pro; I did not press Escape.

Environment

  • Codex CLI: 0.157.1
  • macOS: 27.0
  • Terminal: cmux 0.64.22 (102), TERM=xterm-256color, TERM_PROGRAM=ghostty
  • No tmux layer
  • Input device used for the observed scroll: Nape Pro
  • No explicit tui.fullscreen_transcript or tui.alternate_screen override in the Codex config

Observed steps and result

  1. Start a long-running Codex turn in a cmux terminal surface.
  2. Scroll up in the fullscreen transcript until the Back to bottom · esc hint is visible.
  3. With cmux focused and the turn still running, scroll down using the Nape Pro wheel.
  4. The turn displays Conversation interrupted. The composer contains two consecutive mouse-report tails at the same position: [<65;142;78M[<65;142;78M.

I also observed a separate instance where <65;74;46M appeared in the composer. In SGR mouse encoding, button code 65 is wheel down; the remaining numbers are terminal coordinates.

Expected behavior

Wheel scrolling should move the transcript without inserting control-sequence text into the composer or interrupting the active turn.

Scope and related changes

The visible result establishes the scroll action, leaked mouse-report text, and interruption in the same incident. I have not captured the PTY input bytes, reproduced it outside cmux, or compared another wheel device, so the exact component that splits or misinterprets the escape sequence remains unconfirmed.

PR #47178 changed the default to fullscreen transcript in 0.157.0. Issues #48097 and #48664 describe related mouse capture and copy/selection regressions, but do not cover this interruption and input leak.

Activity

  1. added
    bug
    CLI
    TUI
    on Sep 29, 2026
  2. bc-openai commented on Oct 2, 2026

    @bc-openai
    Contributor

    Thanks for the report! This should be fixed in 0.159.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    CLITUIbug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions