Repository navigation
fix: detect Claude in Chrome permission prompts as waiting_input - #322
Merged
Merged
Conversation
Permission prompts like "Claude in Chrome wants to navigate on ..." use a numbered Allow/Deny menu without "Do you want" / "esc to cancel" phrasing, so the Claude state detector treated them as idle. Detect the numbered "Deny (esc)" option line as a waiting_input marker. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
package.json already declares @kodaikabasawa/ccmanager-* 4.2.2 but the lockfile still pinned 4.2.1; bun install regenerated the entries. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
kbwo
marked this pull request as ready for review
August 10, 2026 13:38
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Claude Code shows browser-extension permission prompts (e.g. "Claude in Chrome wants to create a browser window and read your tabs") as a numbered Allow/Deny menu:
These prompts contain none of the markers the Claude state detector currently keys on — no "Do you want" / "Would you like" phrasing and no "esc to cancel" footer — so ccmanager reports the session as idle while it is actually blocked waiting for the user to answer. The user gets no waiting-input indication (status icon, notification hooks) for these prompts.
The fix detects the numbered
N. Deny (esc)option line, which is present in both the 2-option (Allow / Deny) and 3-option (Allow / Allow all actions / Deny) variants, and classifies it aswaiting_input. The "wants to ..." sentence itself is deliberately not used as a marker because that phrase commonly appears in ordinary assistant prose and would cause false positives.Verification
Prerequisites:
bun installfrom repo root.Steps:
bun run test src/services/stateDetector/claude.test.ts— 77 tests pass, including two new cases that reproduce the 2-option and 3-option permission prompts verbatim and assertwaiting_input.bun run lint,bun run typecheck, and fullbun run test(1790 passed / 10 skipped) succeed on the branch.🤖 Generated with Claude Code