Permission gate: honor .claude/settings.json allow/ask/deny, serializ… - #17
Open
Revmagi wants to merge 1 commit into
Open
Permission gate: honor .claude/settings.json allow/ask/deny, serializ…#17Revmagi wants to merge 1 commit into
Revmagi wants to merge 1 commit into
Conversation
…e concurrent asks, exit cleanly on hangup Reads, lookups and other tools already covered by an "allow" rule in .claude/settings.json (user, project, and project-local) now skip the spoken permission ask entirely; a "deny" rule blocks silently; everything else still asks out loud as before. A second tool call needing a decision while one is already pending used to overwrite the first's pending future, orphaning it to time out no matter what the user said. An asyncio lock now serializes concurrent asks so only one question is ever live at a time. Two remaining QUIT_PHRASES comparisons still used text.lower() instead of _norm_speech(), missed by an earlier pass; fixed to match. asyncio.run()'s own shutdown (cancelling stray tasks, closing the default executor) can hang on native-library threads (torch/kokoro) after our own cleanup is already done; os._exit(0) skips that teardown on both the normal and KeyboardInterrupt exit paths.
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.
…e concurrent asks, exit cleanly on hangup
Reads, lookups and other tools already covered by an "allow" rule in .claude/settings.json (user, project, and project-local) now skip the spoken permission ask entirely; a "deny" rule blocks silently; everything else still asks out loud as before.
A second tool call needing a decision while one is already pending used to overwrite the first's pending future, orphaning it to time out no matter what the user said. An asyncio lock now serializes concurrent asks so only one question is ever live at a time.
Two remaining QUIT_PHRASES comparisons still used text.lower() instead of _norm_speech(), missed by an earlier pass; fixed to match.
asyncio.run()'s own shutdown (cancelling stray tasks, closing the default executor) can hang on native-library threads (torch/kokoro) after our own cleanup is already done; os._exit(0) skips that teardown on both the normal and KeyboardInterrupt exit paths.