ExitPlanMode Gets Stuck in Infinite Loop on Claude Desktop

Resolved 💬 4 comments Opened Dec 31, 2025 by alphonsolionheart Closed Dec 31, 2025

Bug Report: ExitPlanMode Gets Stuck in Infinite Loop on Claude Desktop

Environment

  • Platform: macOS (Darwin 24.6.0)
  • Application: Claude Desktop
  • Date: 2025-12-31

Description

When using Plan Mode in Claude Desktop, the ExitPlanMode tool gets stuck in an infinite loop. The AI repeatedly attempts to exit plan mode but fails to transition back to normal mode, causing the conversation to become unresponsive.

Steps to Reproduce

  1. Open Claude Desktop on macOS
  2. Enter Plan Mode (via Shift+Tab or by starting with --permission-mode plan)
  3. Complete planning/analysis tasks
  4. Attempt to exit Plan Mode using Shift+Tab or when Claude calls ExitPlanMode
  5. Observe that the mode transition fails and loops repeatedly

Expected Behavior

  • Plan Mode should exit cleanly
  • Permission mode should cycle: Plan Mode → Normal Mode
  • The conversation should continue normally after exiting plan mode

Actual Behavior

  • ExitPlanMode gets called repeatedly in a loop
  • The mode transition never completes
  • The conversation becomes stuck/unresponsive
  • User has to force quit or restart the session

Workarounds Attempted

  • [x] Tried Alt+M as alternative shortcut
  • [x] Tried Ctrl+D to exit and restart session
  • [ ] Ran /terminal-setup (not applicable for Desktop app)

Additional Context

This issue occurs specifically on Claude Desktop (GUI application), not the CLI version. The loop behavior suggests the permission mode state machine is not properly transitioning between states.

Possible Causes

  1. State machine not receiving confirmation of mode change
  2. UI/backend desync on permission mode status
  3. macOS-specific keyboard event handling issue
  4. Desktop app not properly implementing ExitPlanMode tool response

Logs

If applicable, logs can be found at: ~/.claude/debug/

---

Reporter: User via Claude Code CLI
Priority: Medium (workaround exists: restart session)

View original on GitHub ↗

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