claude-code - 💡(How to fix) Fix Escape key does not interrupt Claude when deep in tool chain (Remote Control / SSH sessions) [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#46698Fetched 2026-04-12 13:35:24
View on GitHub
Comments
1
Participants
2
Timeline
6
Reactions
0
Author
Timeline (top)
labeled ×5commented ×1
RAW_BUFFERClick to expand / collapse

Problem

When Claude Code is executing a long chain of tool calls (file edits, SCP, SSH commands), pressing Escape (even twice) does not interrupt the execution. The progress counter keeps spinning with no way to stop it.

Steps to reproduce

  1. Start a Claude Code session via Remote Control (claude.ai)
  2. Give Claude a task that involves multiple sequential tool calls (e.g. editing several large files + SCP to remote server + SSH commands)
  3. While the tool chain is executing (counter spinning), press Escape or Escape twice
  4. Nothing happens — Claude continues executing

Expected behavior

Escape should interrupt the current tool chain and return control to the user.

Actual behavior

Escape has no effect. The only way to stop execution is to kill the session entirely and resume, losing context of what was happening.

Environment

  • Claude Code via Remote Control (claude.ai)
  • macOS 15.7.4
  • Session involved: large file edits + scp + SSH commands to remote server

Impact

User is forced to kill the session and resume, which is disruptive especially during long deployments.

extent analysis

TL;DR

The issue can be mitigated by investigating the handling of interrupt signals within the Claude Code session, potentially requiring adjustments to how Escape key presses are captured and processed during tool chain execution.

Guidance

  • Investigate how Claude Code handles interrupt signals (e.g., SIGINT) when the Escape key is pressed, to understand why the current implementation does not interrupt the tool chain as expected.
  • Review the documentation or source code of Claude Code to see if there are any specific configurations or settings that need to be adjusted to enable proper interrupt handling during remote sessions.
  • Consider testing the behavior with different types of tool chains or individual tool calls to isolate if the issue is specific to certain commands or the combination of commands.
  • Look into whether there are any known issues or open tickets related to interrupt handling in Claude Code's issue tracker that might provide insight or a temporary workaround.

Example

No specific code example can be provided without more details on the internal implementation of Claude Code or its handling of keyboard interrupts.

Notes

The solution may depend on the specifics of how Claude Code is implemented, especially regarding its use of subprocesses for tool calls and how it captures and handles keyboard input during execution. The issue might also be related to the Remote Control environment (claude.ai) and its interaction with the local macOS environment.

Recommendation

Apply a workaround, as the root cause seems to be related to the handling of interrupts within Claude Code, and without a clear indication of a fixed version that addresses this issue, adjusting the current setup or waiting for an update seems prudent.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

Escape should interrupt the current tool chain and return control to the user.

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix Escape key does not interrupt Claude when deep in tool chain (Remote Control / SSH sessions) [1 comments, 2 participants]