You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(guardrails): treat a word-continuing ( as a word character in the top-level segmenter #12360
The guardrails top-level command parser in plugins/guardrails/lib/hook-utils.sh (shared copies) splits a word-continuing ( (an array assignment such as a=(...) or an extglob such as @(...)) as if it were a subshell, then reads a # after the closing ) as the start of a comment. Bash does not: after a=(x) the # is literal when it continues the word. A destructive git command placed after such a construct can then be hidden from the dangerous-git guard at top level.
#12354 (the heredoc-body substitution scanner for #6730) makes the body scanner's verdict equal the top-level verdict for these forms and adds parity rows to run-guards.test.sh, so the remaining miss is in the top-level parser on main.
Fix
Treat a ( that continues a word as a word character in the top-level segmenter: no subshell frame and no comment start after its ). Add blocked rows to block-dangerous-git for the array-assignment and extglob forms.
Verification
The new rows fail on main and pass after the fix; block-dangerous-git, run-guards and lib/hook-utils.test stay green; sync-shared-copies --check is clean.
Proposed work class: work-class: scoped
Basis: automated intake triage; the lanes App applied this class.
Size: Small
Complexity: Medium
Uncertainty: Known
Flags: none
Blocked by: none
Understood: the top-level command segmenter in the guardrails shared hook-utils.sh treats a word-continuing ( (array assignment or extglob) as a subshell. It then reads a # after the closing ) as a comment, which can hide a later destructive git command from the dangerous-git guard. The fix is to treat that ( as a word character and add blocked rows to block-dangerous-git. The done-when is exact. No duplicates found among the open issues.
Not admitted to the issue lane: no trusted-human acceptance criteria: a listed human must put the confirmed - [ ] criteria in the body or post them as their own comment, or, on an issue a listed human filed, intake's newest refinement comment must hold them unedited. Admission takes the issue once each of those is met, when intake triages it again (.github/actions/resolve-config/admission-rules.json).
The work-resolve-issue lane stopped on this issue (already-done): the run found the issue's work already on the default branch at a commit it cites, so the issue closes.
Its reason cites no pull request merged into the default branch, or commit on it, made after the issue opened whose commit message closes this issue, so it retries instead of closing.
It keeps agent-ready, and work-unblock starts it again (retry 1 of 2).
In the run's words:
already-done: merged pull request #12384 (merge commit 019478d) delivers #12360. Its body lists #12360 under Refs, and main at 0cd1cf1 already holds the fix, the blocked rows and the parse-segments cases this issue asks for.
What the run says it did not do:
Did not run block-dangerous-git.test.sh, run-guards.test.sh or lib/hook-utils.test.sh. This lane may not run test scripts directly, and the suites passed in PR #12384's CI (90 checks passed).
Skipped tidy, review, verify and the PR prep: the work tree has no change.
The work-resolve-issue lane stopped on this issue (already-done): the run found the issue's work already on the default branch at a commit it cites, so the issue closes.
Its reason cites no pull request merged into the default branch, or commit on it, made after the issue opened whose commit message closes this issue, so it retries instead of closing.
It keeps agent-ready, and work-unblock starts it again (retry 2 of 2).
In the run's words:
already-done: merged pull request #12384 (merge commit 019478d) delivered this issue's parser work. It replaced the closed #12361, which had been opened for #12360, and lists #12360 under Related instead of closing it. The default branch at 3b9363c already carries the fix and every test row the issue asks for.
What the run says it did not do:
Did not run block-dangerous-git.test.sh, run-guards.test.sh or lib/hook-utils.test.sh: this lane cannot run a test runner directly, and the tests are unchanged on main. CI ran them when #12384 merged.
The repository is a shallow clone, so git could not trace the rows to #12384's merge commit. The merge SHA comes from the GitHub PR page, not from local history.
Skipped tidy, review, verify and checks prep: there is no diff to tidy or review.
The work-resolve-issue lane stopped on this issue (already-done): the lane has retried this issue as many times as limits.stop-retries, or the stop's own row, allows.
Its reason cites no pull request merged into the default branch, or commit on it, made after the issue opened whose commit message closes this issue, so it retries instead of closing.
It removed agent-ready and added no label.
In the run's words:
already-done: merged pull request #12384 (merge commit 019478d) already makes the top-level segmenter treat a word-continuing ( as part of the word and adds the issue's blocked rows; it is on the default branch at 591d521.
What the run says it did not do:
Did not run block-dangerous-git.test.sh, run-guards.test.sh or lib/hook-utils.test.sh: this lane runs only the named wrappers. The suites ran in #12384's CI, where the PR page shows 90 checks passed.
tidy, review and verify skipped: there is no diff to tidy, review or build.
Delivered: closing as completed. Merged PR #12384 (019478d) makes the top-level segmenter treat a word-continuing ( as part of the word and adds the issue's blocked rows to block-dangerous-git (array assignment, extglob, extglob alternation, and three more forms); its CI ran the suites. The lane's own run stopped on already-done. Written by the issue-triage session.
Activity
github-actions commentedon Nov 2, 2026
Proposed work class: work-class: scoped
Basis: automated intake triage; the lanes App applied this class.
Size: Small
Complexity: Medium
Uncertainty: Known
Flags: none
Blocked by: none
Understood: the top-level command segmenter in the guardrails shared
hook-utils.shtreats a word-continuing((array assignment or extglob) as a subshell. It then reads a#after the closing)as a comment, which can hide a later destructive git command from the dangerous-git guard. The fix is to treat that(as a word character and add blocked rows toblock-dangerous-git. The done-when is exact. No duplicates found among the open issues.Automated triage, applied by the lanes App.
melodic-automation-lanes commentedon Nov 2, 2026
Not admitted to the issue lane: no trusted-human acceptance criteria: a listed human must put the confirmed
- [ ]criteria in the body or post them as their own comment, or, on an issue a listed human filed, intake's newest refinement comment must hold them unedited. Admission takes the issue once each of those is met, when intake triages it again (.github/actions/resolve-config/admission-rules.json).melodic-automation-lanes commentedon Nov 2, 2026
The latest triage verdict holds nothing: the issue is at
status: ready.25 remaining items
github-actions commentedon Nov 2, 2026
melodic-automation-lanes commentedon Nov 2, 2026
The work-resolve-issue lane stopped on this issue (
already-done): the run found the issue's work already on the default branch at a commit it cites, so the issue closes.Its reason cites no pull request merged into the default branch, or commit on it, made after the issue opened whose commit message closes this issue, so it retries instead of closing.
It keeps
agent-ready, and work-unblock starts it again (retry 1 of 2).In the run's words:
What the run says it did not do:
Run: https://github.com/melodic-software/claude-code-plugins/actions/runs/41546053445
github-actions commentedon Nov 2, 2026
github-actions commentedon Nov 2, 2026
melodic-automation-lanes commentedon Nov 2, 2026
The work-resolve-issue lane stopped on this issue (
already-done): the run found the issue's work already on the default branch at a commit it cites, so the issue closes.Its reason cites no pull request merged into the default branch, or commit on it, made after the issue opened whose commit message closes this issue, so it retries instead of closing.
It keeps
agent-ready, and work-unblock starts it again (retry 2 of 2).In the run's words:
What the run says it did not do:
Run: https://github.com/melodic-software/claude-code-plugins/actions/runs/41547224064
github-actions commentedon Nov 2, 2026
github-actions commentedon Nov 2, 2026
melodic-automation-lanes commentedon Nov 2, 2026
The work-resolve-issue lane stopped on this issue (
already-done): the lane has retried this issue as many times as limits.stop-retries, or the stop's own row, allows.Its reason cites no pull request merged into the default branch, or commit on it, made after the issue opened whose commit message closes this issue, so it retries instead of closing.
It removed
agent-readyand added no label.In the run's words:
What the run says it did not do:
Run: https://github.com/melodic-software/claude-code-plugins/actions/runs/41548366817
To run it again, add
agent-ready.kyle-sexton commentedon Nov 3, 2026
Delivered: closing as completed. Merged PR #12384 (019478d) makes the top-level segmenter treat a word-continuing ( as part of the word and adds the issue's blocked rows to block-dangerous-git (array assignment, extglob, extglob alternation, and three more forms); its CI ran the suites. The lane's own run stopped on already-done. Written by the issue-triage session.