[TUI][macOS][Warp] Ctrl+V after copying plain terminal text freezes the TUI

Open 💬 0 comments Opened Jun 12, 2026 by yuebozhang

What version of Codex is running?

codex-cli 0.139.0

Which model were you using?

Not known / not relevant. The freeze occurred while pasting into the TUI composer, before submitting a prompt.

What platform is your computer?

  • macOS 26.5.1 (25F80), Apple Silicon / arm64
  • Warp 0.2026.06.03.09.49.02
  • Terminal reported in Codex logs as WarpTerminal/v0.2026.06.03.09.49.stable_02

What steps can reproduce the bug?

  1. Run this command in Warp:

``shell
ls /dev/tty.usb*
``

  1. Select and copy plain terminal output similar to:

``text
/dev/tty.usbserial-1130 /dev/tty.usbserial-11420
``

  1. Focus the Codex TUI composer.
  2. Press Ctrl+V.

What is the expected behavior?

The copied plain text should be pasted, or Ctrl+V should be ignored without affecting TUI responsiveness.

What do you see instead?

The Codex TUI becomes permanently unresponsive. I had to open a new Codex session to continue working. The original Codex process remained alive after the freeze.

Additional diagnostic information

I inspected the local Codex logs and processes after the incident:

  • No macOS Codex crash or hang report was generated.
  • No panic, error, SQLite lock error, clipboard event, or paste event appeared around the incident time.
  • The lack of a paste event may indicate that the freeze occurs early in TUI clipboard handling, before the event reaches normal logging.
  • Multiple Codex instances were running against the same default $CODEX_HOME at the time.
  • ~/.codex/logs_2.sqlite was approximately 106 MB, its WAL was approximately 7.5 MB, and SQLite reported busy_timeout=0.
  • A process sample of the surviving Codex process showed TUI render/event-loop paths and multiple sqlx-sqlite-worker threads, but did not reveal a conclusive deadlock location.

There appear to be two plausible interacting causes:

  1. Ctrl+V uses Codex's special clipboard/image handling path on macOS, and Warp's clipboard payload for selected terminal text triggers a freeze.
  2. Multi-instance SQLite contention stalls the TUI when clipboard handling triggers additional work.

Related issues:

  • #3397: inconsistent Cmd+V / Ctrl+V clipboard behavior on macOS
  • #20213: multi-terminal Codex freezes caused by SQLite lock contention

This report differs from #3397 because copying normal text and pressing Ctrl+V caused a permanent TUI freeze rather than doing nothing.

View original on GitHub ↗