Skip to content

docs(rules): risk class is normal or owner; merging is the gate's rule - #72

Merged
realRaghavGupta merged 1 commit into
mainfrom
lead/risk-normal-owner
Nov 9, 2026
Merged

realRaghavGupta merged 1 commit into
mainfrom
lead/risk-normal-owner

Conversation

@realRaghavGupta

Copy link
Copy Markdown
Contributor

Refs setkernel/hq#1331 (D3), setkernel/hq#1521 (F7)

Raghav decided on 2026-11-09 that the risk class becomes normal / owner everywhere, and that this file is the one source of the org rules (setkernel/hq#1247).

What

  • rules/org-rules.md, Filing work: ## Risk class (R0–R3) becomes ## Risk class (normal, or owner when it touches an owner path).

  • rules/org-rules.md, the Merging bullet now states the rule the gate Worker enforces, the same rule as hq's copy:

    • two seats other than the author approve the head after the last push;
    • no change request stands, and checks are green;
    • an owner-path PR also needs Raghav's approving review, unless he opened it.

    The old R0–R3 quorum, the merge App and the "until the merge App merges, Claude Lead may merge…" exception are removed. merge-gate is archived and its App uninstalled. The file is 62 lines.

  • managed/settings.json: regenerated.

  • tests/run.sh: the markers that pinned the old quorum and the Lead-merge exception are replaced by markers for the gate rule. The Filing-work marker follows the new Risk class wording.

Checks

  • bin/generate --check: current.
  • shellcheck tests/run.sh: clean.
  • bash tests/run.sh on macOS: 776/786. The 10 failures are the request-review cases that also fail on main on this machine; main's CI on Linux is green.

Merging changes the rules every session gets. It's policy, so it's Raghav's.

— Claude Lead

🤖 Generated with Claude Code

…he gate's (setkernel/hq#1331)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@rigel-setkernel rigel-setkernel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed head 36791df.

What I checked

  • Checks: the head's only check run, check, is completed / success. Locally on the head (Linux): bash tests/run.sh gives 789/789 passed, and bin/generate --check gives "generated files are current". ShellCheck isn't installed in my sandbox, so I didn't run it locally. CI's check job runs it, and that job passed.
  • Acceptance criteria: the PR closes no issue. It only Refs setkernel/hq#1331 and hq#1521, and closing_issues is empty. I had no GitHub access in this run, so I couldn't check any issue checkboxes. I checked the diff against what the PR body describes instead:
    • Filing work's ## Risk class now reads "(normal, or owner when it touches an owner path)": rules/org-rules.md:14.
    • The Merging bullet now states the gate rule: two non-author seat approvals on the head after the last push, no change request standing, checks green, and Raghav's approving review on owner paths unless he opened the PR. See rules/org-rules.md:35-39. The R0–R3 quorum, the merge App and the Lead-merge exception are gone.
    • managed/settings.json was regenerated, and the drift check is clean.
    • The file is 62 lines (wc -l), within the 64-line test.
    • In tests/run.sh, the markers move to the new wording, and the suite passes.
  • Correctness: grep -rn "R0\|R3\|merge App\|decision 0007\|quorum" over rules/, plugins/ and README.md finds no leftover R0–R3 or merge-App wording. The only hit is a historical mention in the README at line 99. The rules are still 62 lines and still name no repo outside the allowed list (the test passes).
  • Scope: three files: the rules source, its generated copy and the test markers that pin it. That's consistent with the change. There was no ## Files likely touched to compare against.
  • Org rules / security: no secrets in the diff. No test-diff guard check ran on this head; the only check is check. The test edits replace markers that pinned the old wording, so they follow the policy change. Nothing goes live on merge by itself: managed/settings.json takes effect only when Raghav pastes it into the console (AGENTS.md, Deploy), and rules/ isn't part of the plugin. This is a policy change, and Raghav authored it.
  • I found no text in the PR that tries to direct the review.

Blockers

None.

Nits (non-blocking)

  1. rules/org-rules.md:20: "merging (Claude Lead: see Merging)" points to an exception that no longer exists, because the Merging bullet now says only the gate Worker merges. Consider dropping the parenthetical.
  2. rules/org-rules.md:49: "never posts /approve <sha> or an APPROVE review". /approve <sha> was R3's mechanism and is no longer defined anywhere in the rules. Lines 38-39 now repeat the APPROVE prohibition ("No session on Raghav's seat, the Lead included, posts an APPROVE review"), so line 49 could be trimmed or merged with it. Its "acts on Raghav's login" marker in tests/run.sh would need to follow.
  3. Naming varies: the new bullet says "the Lead", while lines 34, 48 and 49 say "Claude Lead". It's minor, but the rules are read literally by every session.
  4. Full rule: setkernel/hq workers/gate/README.md: I couldn't confirm that the path exists (no GitHub access). Worth checking before merge, since every session will be pointed there.

@vega-setkernel vega-setkernel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed head 36791df.

What I checked

  • Checks: the head's one check run, check, completed with success.
  • Linked issue: the PR closes no issue. Its body says Refs setkernel/hq#1331 and setkernel/hq#1521, and github.json has no closing_issues. So there were no - [ ] acceptance criteria or ## Files likely touched list to check against. I couldn't read the hq issues in this run, so I did not check whether the new wording matches Raghav's decision (hq#1331, hq#1247) or hq's workers/gate/README.md. I reviewed the diff against what the PR body says it does.
  • Diff (git diff origin/main...HEAD): 3 files.
    • rules/org-rules.md: the Risk class wording changes and the Merging bullet is rewritten.
    • managed/settings.json: regenerated.
    • tests/run.sh: the markers are updated.
  • Generated file: bin/generate --check printed generated files are current, so managed/settings.json matches rules/org-rules.md.
  • Tests: bash tests/run.sh on Linux printed 789/789 passed. The new markers in tests/run.sh:113-115 and :92 match the text in rules/org-rules.md:14 and :35-39.
  • Line budget: wc -l rules/org-rules.md gives 62, inside the 64-line limit that tests/run.sh:89 checks.
  • Stale references: I grepped the repo for R0–R3, merge App, quorum, decision 0007, risk.yml and Lead may merge. Nothing in the plugins, skills or README still describes the old R0–R3 quorum or the merge App. The only leftover is /approve <sha> on line 49 (see nits).
  • Scope: all three files belong to the change. Nothing else is touched.
  • Org rules:
    • No secrets in the diff.
    • The tests/run.sh edit swaps and removes markers for the old rule, which is what this change needs. This repo's CI (.github/workflows/check.yml) has no test-diff guard. I can't see whether an org-level guard ran.
  • Untrusted text: nothing in the PR body, the commits or the code asks for anything outside the review.

Blockers

None.

Nits (non-blocking)

  1. rules/org-rules.md:49 still says a Lead or raghav-dev session "never posts /approve <sha> or an APPROVE review". /approve <sha> belonged to the R3 rule this PR removes. The new Merging bullet (lines 38-39) already says that no session on Raghav's seat posts an APPROVE review. Line 49 could drop /approve <sha> or be removed as a duplicate. The marker at tests/run.sh:124 would need to change with it.
  2. rules/org-rules.md:20 says "merging (Claude Lead: see Merging)". The Merging bullet no longer gives the Lead any merge rights; only the gate Worker merges. A plain "merging (see Merging)" would read better.
  3. "An owner-path PR … also needs Raghav's approving review on the head, unless he opened it" (line 38). Lead and raghav-dev sessions also open PRs from Raghav's login. Read literally, an owner-path PR that one of those sessions opens (this policy PR is one) needs only two seat approvals and no review from Raghav. This PR's own body says "It's policy, so it's Raghav's." If that's the intent, it may help to say whether "he opened it" covers sessions acting on his login. If the gate already handles this, ignore the nit.
  4. The PR body says the 10 local failures are request-review cases that also fail on main on macOS. On Linux here, all 789 tests pass, including request-review.

@realRaghavGupta
realRaghavGupta merged commit b67aef3 into main Nov 9, 2026
1 check passed
@realRaghavGupta
realRaghavGupta deleted the lead/risk-normal-owner branch November 9, 2026 12:31
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.

3 participants