copilot-cli icon indicating copy to clipboard operation
copilot-cli copied to clipboard

Double-Escape cancellation hangs indefinitely on v1.0.19 (macOS)

Open dezgit2025 opened this issue 7 months ago • 1 comments

Description

When pressing Escape twice (double-Escape) to cancel an operation in Copilot CLI v1.0.19, the CLI gets stuck in a "Cancelling" state indefinitely. It never completes the cancellation — the yellow "Cancelling" indicator stays on screen and the CLI becomes unresponsive. The only recovery is to force-quit the process.

Steps to Reproduce

  1. Start an interactive Copilot CLI session (copilot)
  2. Submit a prompt that triggers tool execution (e.g., a shell command or multi-step task)
  3. While the agent is executing, press Escape twice to cancel
  4. Observe: CLI shows ● Cancelling but never returns to the prompt

Expected Behavior

Double-Escape should cancel the current operation and return to the input prompt within a few seconds, as documented in the help text.

Actual Behavior

The CLI hangs on ● Cancelling indefinitely. No timeout. No recovery. Must force-quit.

Environment

  • Copilot CLI version: 1.0.19 (stable)
  • OS: macOS (Apple Silicon, ARM64)
  • Shell: zsh
  • Terminal: macOS Terminal.app
  • Install method: Install script (gh.io/copilot-install)

Notes

  • The v1.0.12 changelog mentions "Pressing Escape multiple times during autopilot cancellation no longer leaves the session stuck" — this fix may have regressed or may not cover the non-autopilot interactive mode case.
  • Reproducible across different types of operations (shell commands, tool calls).

dezgit2025 avatar Apr 07 '26 15:04 dezgit2025

We addressed the multi-Escape cancellation hang in v1.0.12 and further hardened it in v1.0.15 - both fixes are included in your v1.0.19. Additionally, v1.0.20 and v1.0.21 improved session idle behavior during background operations, which could help with related edge cases. Updating to v1.0.21 is worth trying. If the issue persists on the latest version, please feel free to reopen this issue.

examon avatar Apr 07 '26 23:04 examon