Skip to content

fix(scripts): allow any user to prevent auto-close with thumbs down - #84365

Open
alifakbxr wants to merge 2 commits into
anthropics:mainfrom
alifakbxr:fix/79146-auto-close-duplicates-thumbs-down
Open

fix(scripts): allow any user to prevent auto-close with thumbs down#84365
alifakbxr wants to merge 2 commits into
anthropics:mainfrom
alifakbxr:fix/79146-auto-close-duplicates-thumbs-down

Conversation

@alifakbxr

Copy link
Copy Markdown

Fixes #79146. Matches the dedupe bot's promise by allowing any user's thumbs down to prevent closure.

This fixes a vulnerability where an exception (such as an ImportError or
a generic exception during rule evaluation) would cause the hook to exit
with status 0 and allow the gated tool execution. Now, exceptions will
emit a permissionDecision: 'deny', ensuring unauthorized actions are
prevented when the hook fails.

Resolves anthropics#84302
Fixes anthropics#79146.
The dedupe bot promises 'To prevent auto-closure, add a comment or 👎 this comment', but the logic only checked if the issue author thumbs-downed. Since anyone commenting already prevents closure, anyone thumbs-downing should as well, matching the comment's wording and intent.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

auto-close-duplicates only honors a thumbs-down from the issue author, unlike what the bot comment promises

1 participant