Repository navigation
fix(guardrails): report when check-bash-file-changes skips or truncates - #6710
Conversation
check-bash-file-changes exited quietly whenever it left a change unexamined, so its silence could not be told apart from a clean check. It now reports each skip to Claude as "N changed files not examined: <reason>": files past the 20-file cap or the time budget, a git status that failed or listed more than 10000 paths (at the snapshot or the check), a new symbolic link, a missing snapshot, no bash to run the guards, and a run_in_background command. Notes alone go out as additionalContext; beside a finding they join the block reason. A run that skips nothing stays quiet. Closes #6709 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EFqTQRnCGywRxhv4nw4o4V
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Claude finished @kyle-sexton's task in 6m 44s —— View job Review in progress
|
|
Claude finished @kyle-sexton's task in 2m 15s —— View job Security review complete
No security issues found. Reviewed the full diff ( Checked specifically for regressions a reviewer would expect here:
|
|
claude-security-review has reviewed this pull request through 69a6231; a later push is reviewed from there. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b68fc8d3b6
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
claude-review has reviewed this pull request through 69a6231; a later push is reviewed from there. |
committedFiles reads only the last 20 commits, so files changed only in earlier commits went unchecked with no note. The check now says how many earlier commits it did not read. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EFqTQRnCGywRxhv4nw4o4V
|
Claude finished @kyle-sexton's task in 1m 6s —— View job Security review complete
No security issues found in the changes made since commit This increment fixes exactly the gap Codex flagged and @kyle-sexton confirmed as valid: commits past the last 20 a shell command makes were silently dropped before Reviewed
No instruction-surface deletions, no authz/trust-boundary changes, no secret handling touched in this increment. |
|
Claude finished @kyle-sexton's task in 3m 7s —— View job Review complete
No blocking findings. This increment ( Traced the fix in
One non-blocking observation, not worth a fix on its own: unlike the file-cap path, which has a stay-quiet boundary test at exactly 20 changed files ( I was not able to execute the test suite or |

Closes #6709
Summary
check-bash-file-changesexited quietly whenever it left a change unexamined, so nobody reading its output could tell "checked and clean" from "not checked". It now reports every skip or truncation it can detect as "N changed files not examined: ".Fix
check()returns{findings, notes}. A note is added for:a01..a20pluszz.shrepro)git statusthat failed or listed more than 10000 paths, at the check or at the snapshotrun_in_backgroundcommand, whose later writes are not checkedgit statusfails, it now writes{root, failed: true}so the check can say why it examined nothing.stamp()records symbolic links ([size, mtime, isLink]fromlstat). A pre-existing link that the command did not touch stays quiet.hookSpecificOutput.additionalContextand never block. Next to a finding, they are appended to the existing block reason. A run with no findings and no notes prints nothing, as before..changes/guardrails/(patch).Verification
check-bash-file-changes.test.shgained a MUST REPORT section (R1-R5). Against the unmodified hook it had 8 failures, all in the new cases, for exampleFAIL: file cap: count and reason: '1 changed file not examined: ...' not in output:with empty output. After the fix:PASS=48 FAIL=0.scripts/affected-tests.sh --runoverplugins/guardrails/**/*.test.sh).check-changelog-fragments.sh --checkpasses.Related
🤖 Generated with Claude Code
https://claude.ai/code/session_01EFqTQRnCGywRxhv4nw4o4V