feat(#247): cap review verdict at comment-only for governance docs#261
feat(#247): cap review verdict at comment-only for governance docs#261fullsend-ai-coder[bot] wants to merge 2 commits into
Conversation
Add governance-document check to pr-review skill step 6e and post-review.sh defense-in-depth. When ALL changed files match governance patterns (MAINTAINERS.md, GOVERNANCE.md, CODE_OF_CONDUCT.md, SECURITY.md), the review outcome is capped at comment-only with an info-level finding. PRs mixing governance docs with other files follow the normal review flow. Closes #247 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
E2E tests did not runE2E tests run automatically for org/repo members and collaborators on pull requests. For other contributors, a maintainer must add the See E2E testing guide for details. |
|
🤖 Finished Review · ❌ Failure · Started 12:54 PM UTC · Completed 12:54 PM UTC |
|
/fs-review |
|
🤖 Finished Review · ✅ Success · Started 3:57 PM UTC · Completed 4:10 PM UTC |
ReviewFindingsLow
Previous runReviewFindingsMedium
Low
|
|
/fs-fix |
|
🤖 Finished Fix · ✅ Success · Started 5:38 PM UTC · Completed 5:49 PM UTC |
- Combine temp file cleanup into a single trap covering both MODIFIED_RESULT and GOV_RESULT (previously GOV_RESULT had no cleanup, inconsistent with the protected-path downgrade path) - Add governance document detection tests (is_all_governance helper with 7 test cases: single/multiple/subdir/mixed/non-gov/substring/ all-four-patterns) - Update stale comment to acknowledge both downgrade paths - Add explicit category-override note in step 6f outcome rules (protected-path and governance-document cap outcome at comment) Addresses review feedback on #261
🔧 Fix agent — iteration 1 (human-triggered)Addressed 3 of 4 review findings. Fixed GOV_RESULT temp file cleanup by combining both downgrade paths into a single trap. Added 7 governance detection test cases and updated a stale comment. Added explicit category-override note in step 6f. Disagreed with 1 finding (adding governance-document to the triage table) per the reviewer's own analysis that it would be conceptually wrong. Fixed (3):
Disagreed (1):
Tests: passed Updated by fullsend fix agent |
|
🤖 Finished Review · ✅ Success · Started 5:51 PM UTC · Completed 6:05 PM UTC |
| "CODE_OF_CONDUCT.md" | ||
| "SECURITY.md" | ||
| ) | ||
|
|
There was a problem hiding this comment.
[low] edge-case
The is_all_governance() test helper returns true for empty input (vacuous truth). In production this is guarded by PR_FILES non-empty check. Adding a documenting test case would make the edge case explicit.
Suggested fix: Add: run_gov_test "empty-input-vacuous-true" "" "true" with a comment noting the upstream guard.
| # protected-path downgrade above). | ||
| # Governance document patterns (kept in sync with pr-review SKILL.md): | ||
| # ------------------------------------------------------------------------- | ||
| if [ "${DOWNGRADED}" = "false" ]; then |
There was a problem hiding this comment.
[low] edge-case
Governance check is skipped when protected-path already fired (DOWNGRADED=false guard). Both paths produce the same result (comment action with DOWNGRADED=true), so enforcement is correct. User sees only the protected-path explanation.
Summary
Extends the ADR comment-only pattern (fullsend-ai#1659) to governance/process documents. Complements fullsend-ai#1772 by addressing the highest-risk document subset first.
Note: pre-commit hooks could not run in sandbox (shellcheck-py download blocked by network policy). Post-script runs authoritative pre-commit on the runner.
Closes #247
Post-script verification
agent/247-governance-doc-comment-only)