Document GitHub enforcement ruleset for Agent-Analysis verification (Sprint 1) - #12
Conversation
The agent-analysis-verification workflow already runs on PRs to main (pytest + git diff --check, stable job name agent-analysis-verification). This adds the missing Sprint 1 documentation so the advisory check can be made a required, blocking PR gate: - docs/github_enforcement.md: required branch ruleset for main (require PR, require the agent-analysis-verification status check, require up-to-date branch, conversation resolution, restrict deletions, block force pushes, empty bypass list). Notes that no harness PASS is faked in CI. - README: new "GitHub enforcement" section stating the check is advisory until required, and that merge stays human-controlled. No merge/deploy/force-pass endpoint or auto-merge behavior is introduced. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JQW4FXw46KBvMCVc2EduXT
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 386a3bb2c4
ℹ️ 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".
| | --- | --- | | ||
| | Require a pull request before merging | **On** | | ||
| | Require status checks to pass | **On** | | ||
| | → Required status check | **`agent-analysis-verification`** | |
There was a problem hiding this comment.
Pin required check to the GitHub Actions source
When adding this required status check, also document the expected source as the GitHub Actions app rather than leaving the ruleset at "any source". GitHub rulesets allow write-scoped users or integrations to set commit statuses when any source is accepted, so a write-capable actor could post a passing agent-analysis-verification status for the PR head without this workflow passing, defeating the no-self-certification gate the doc is meant to enforce.
Useful? React with 👍 / 👎.
| Configure under **Settings → Rules → Rulesets → New branch ruleset** (or the | ||
| classic **Settings → Branches → Branch protection rules**). Target the `main` |
There was a problem hiding this comment.
Require bypass protection for classic branch rules
Because this section presents classic branch protection as an equivalent setup path, it needs the classic-only Do not allow bypassing the above settings option as well. Classic branch protection defaults let admins and custom bypass roles ignore required checks unless that option is enabled, so someone following the Branches path can still merge with a pending or failing agent-analysis-verification check despite the later "no actor may bypass" claim.
Useful? React with 👍 / 👎.
Sprint 1 — GitHub Merge Enforcement (Epic 1)
Sprint goal: convert the existing local verification harness into a GitHub-enforceable PR gate without changing core runtime authority rules.
Context
The
agent-analysis-verificationworkflow already exists and is merged tomain(commit0974d8b). It runs on PRs tomain, installsbackend/requirements-dev.txt, runspython -m pytest -q, and runsgit diff --check, exposing the stable required-check job nameagent-analysis-verification.The remaining Sprint 1 gap was documentation so the advisory check can be made a required, blocking gate. This PR is docs-only.
Changes
docs/github_enforcement.md(new) — required branch ruleset formain: require PR before merge, require theagent-analysis-verificationstatus check, require branch up to date, require conversation resolution, restrict deletions, block force pushes, empty bypass list. Explicitly notes that CI does not fake a harness PASS (no self-certification).README.md— new "GitHub enforcement" section stating the check is advisory until required, that merge stays human-controlled, and linking the ruleset doc.Verification
Guardrails honored
Notes
Agent-Analysis-Verification.yml(filename case differs from the original handoff'sagent-analysis-verification.yml); the GitHub required-check identifier is the job nameagent-analysis-verification, which is correct. Left untouched to keep the PR minimal.verifier_report.jsonin CI, and faking one would violate the no-self-certification rule.🤖 Generated with Claude Code
Generated by Claude Code