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
If the task provides an APPROVED PLAN / authoritative scope (e.g. issue #100's plan gate), also verify
30
30
the diff stays within it — a diff that exceeds the approved plan's declared files or approach is a
31
-
valid reject under this lens ("exceeds approved scope").
31
+
valid reject under this lens ("exceeds approved scope"). Protected-paths hard reject (issue #94 Layer
32
+
2): if the diff touches any path matching the adapter's `protectedPaths` globs (`.claude/gates.json`,
33
+
resolved via `GATES_FILE`), REJECT — an agent PR must not modify the loop's own control plane.
34
+
EXCEPTION: if the adapter's `protectedPaths` is empty or absent (the self-hosting override), skip this
35
+
check (the harness files are the product).
32
36
-**tests**: do tests actually exercise the change? coverage of edge/failure paths? meaningful assertions, not just "it runs"? Run the test gate if needed.
33
37
-**security**: injection, auth/access control, unsafe input, secrets, dependency risk, (for smart contracts) reentrancy/overflow/access — defer to the project security skill if configured.
Copy file name to clipboardExpand all lines: .claude/gates.json
+4-1Lines changed: 4 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -77,5 +77,8 @@
77
77
"commentFix": { "botAllowlist": [] },
78
78
79
79
"_plan_note": "issue #100 — optional spec/plan gate before implementation starts. plan.gate: off (default; today's single-pass advance behavior, unchanged) | label (gate only planned issues that ALSO carry a plan-first label) | always (gate every planned+module:* issue). Unknown/missing value falls back to off. When gated, the loop posts ONE structured plan comment on the issue (marked `<!-- plan-gate:plan -->`) and labels it plan-review + needs-human instead of implementing; the owner reviews the comment and either replaces plan-review with plan-approved (approve — the next tick implements with the plan injected into the implementer and reviewers as authoritative scope) or removes plan-review (request changes — the loop re-plans). Owner-only approval is NOT identity-enforced — same limitation as the `planned` label itself (see docs/USAGE.md). Read by loop-census.sh/loop-tick.sh/loop-event.sh.",
80
-
"plan": { "gate": "off" }
80
+
"plan": { "gate": "off" },
81
+
82
+
"_protectedPaths_note": "issue #94 Layer 2 — deterministic protected-paths guard. Array of glob patterns (\"*\" = one path segment, \"**\" = any depth). An agent-authored PR whose diff touches ANY matching path is NEVER auto-merged: merge-ready.sh blocks the merge and labels the PR needs-human, and reviewers hard-reject it (see .claude/agents/reviewer.md). Protects the loop's own control plane from an injected instruction that tries to edit it. EMPTY ARRAY = disabled (same empty-means-skip convention as `gates`/`notify`) — self-hosted repos whose harness files ARE the product override this to [] in .claude/self/gates.json. Read from the adapter resolved via GATES_FILE (falls back to this root adapter). Documented in docs/HARDENING.md.",
"PR #$n touches protected paths -- human review required" \
164
+
"$title: this PR's diff touches protected path(s): $protected_hit. Auto-merge is blocked by the protected-paths guard (issue #94 Layer 2). A human must review and merge it manually."
0 commit comments