[BUG] Ctrl+G in plan selection TUI causes escape sequence dump and breaks terminal input

Resolved 💬 4 comments Opened Feb 26, 2026 by WolfieLeader Closed Mar 26, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Bug Description

When Claude Code presents the plan execution prompt with options (Yes/auto-accept/manually approve/edit), pressing Ctrl+G (described as "edit in VS Code") causes the TUI to break. Instead of opening VS Code, raw terminal escape sequences are dumped to the screen (^[[O) and the selection interface becomes unresponsive — I can no longer select options 1-4. The process effectively crashes out.

Workaround

After pressing Ctrl+G terminate the Claude running process and paste the plan markdown

Environment
  • OS: macOS Tahoe 26.3
  • Installation method: brew
  • Claude Code version: 2.1.59
Screenshot

<img width="686" height="183" alt="Image" src="https://github.com/user-attachments/assets/f3fcd657-dbf6-4479-8e50-2a00720c915e" />

(It starts with ^[[O the rest of the chars are just a bunch of attempts

Thank you!

What Should Happen?

Pressing Ctrl+G should either open the plan file in VS Code as described in the hint text, or if VS Code is not available, fail gracefully without breaking the TUI. The selection prompt should remain functional regardless.

Error Messages/Logs

Claude has written up a plan and is ready to execute. Would you like to proceed?

 ❯ 1. Yes, clear context (63% used) and auto-accept edits (shift+tab)
   2. Yes, auto-accept edits
   3. Yes, manually approve edits
   4. Type here to tell Claude what to change

 ctrl-g to edit in VS Code · ~/.claude/plans/distributed-enchanting-metcalfe.md
^[[O^[[I^[[O^[[I^C%

Steps to Reproduce

  1. Start Claude Code and give it a task complex enough to generate a plan
  2. Wait for the plan selection prompt to appear with the 4 options
  3. Press Ctrl+G (as suggested by the hint text at the bottom)
  4. Observe escape sequences dumped to terminal and inability to select any option

Claude Model

Opus

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

2.1.59

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

VS Code integrated terminal

Additional Information

<img width="686" height="183" alt="Image" src="https://github.com/user-attachments/assets/f3fcd657-dbf6-4479-8e50-2a00720c915e" />

View original on GitHub ↗

This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗