From 33193a40648d09105fab0cb3e9be77448aea550d Mon Sep 17 00:00:00 2001 From: Josh Terry Date: Mon, 17 Aug 2026 09:16:49 -0700 Subject: [PATCH] Adopt PR-flow dogfooding: every change lands through its own receipt Three pieces make the CI merge gate the real path instead of a bystander: - Ignore /receipt.md and /receipt.json. The CI shell redirect creates the receipt file BEFORE the scanner walks the tree, so an unignored receipt would appear inside its own change scope as an untracked file. - Append the receipt to the job summary so it is readable without scrolling the log. - Record the convention in AGENTS.md: no direct commits to master, the receipt is read before merge, refutations block, and a remainder that misstates the change is itself a correctful bug the PR surfaced. Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_015GeUG1gboWiZSnFyzQghyp --- .github/workflows/correctful.yml | 1 + .gitignore | 6 ++++++ AGENTS.md | 18 ++++++++++++++++++ 3 files changed, 25 insertions(+) diff --git a/.github/workflows/correctful.yml b/.github/workflows/correctful.yml index f751b7c..7901b7c 100644 --- a/.github/workflows/correctful.yml +++ b/.github/workflows/correctful.yml @@ -38,6 +38,7 @@ jobs: echo "gate=$?" >> "$GITHUB_OUTPUT" set -e cat receipt.md + cat receipt.md >> "$GITHUB_STEP_SUMMARY" - name: Post or update PR comment env: diff --git a/.gitignore b/.gitignore index 4346977..68a40ad 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,9 @@ /correctful /dist/ *.receipt.json + +# The receipt's own output must never enter its own change scope: the CI shell +# redirect creates receipt.md BEFORE the scanner walks the tree, so an +# unignored receipt file would appear in the receipt as an untracked change. +/receipt.md +/receipt.json diff --git a/AGENTS.md b/AGENTS.md index cdfce58..31dff20 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -60,3 +60,21 @@ commit publishes the secret it removes. JSON receipt) and treat "could not run" as distinct from "refuted". - The schema (`schema/`) is the payload; changes to it are versioned (`SchemaVersion`) and deliberate. + +## How changes land + +correctful is dogfooded on itself: every change lands through a pull request, +and the CI workflow (`.github/workflows/correctful.yml`) emits a receipt for +the PR's diff as a self-updating comment. That receipt is the merge gate. + +- Never commit directly to `master`; branch, push, open a PR. +- Read the receipt before merging. A refuted claim blocks the merge (the + workflow exits non-zero) and must be resolved by fixing the change — never + by weakening the probe or rewording the claim out of harvest range. +- The remainder does not block, but it is part of the review: if the receipt's + remainder misstates what the change leaves unchecked — a false entry, a + missed claim, a misleading tier — that is a correctful bug the PR just + surfaced, and fixing it is the point of dogfooding. File or fix it before + merging. +- Squash-merge, so one PR is one commit on `master`; the PR description + carries what the receipt could not check and why that is acceptable.