Repository navigation
fix(proof-receipt): port #1626's review fixes onto the shared generator - #1656
Conversation
…r writer and reader PROOF-POLICY §8.5.1 asks every repository that records grades to keep a proof receipt, and each home repository has so far carried its own generator (secret-types' grade-receipt.sh is 622 lines; Lintel's wrote a pre-§8.5.1 shape that the reader refuses). This adds one writer for the estate. - scripts/proof-receipt.js (Bun): reads a TOML receipt source that holds only the typed facts (claims, run ledger, echoes, trusted base, input-set rules) and derives the rest from git: each leg's input set at its receipt's commit (the Agda cone through the include directories; glob patterns for other provers), the manifests and digests by the reference script, an (import ...) for each pinned sibling with its pin checked against the home pin file, the echo witnesses at both ends, the :source-commit, and each :pwg. `check` regenerates and refuses any difference, refuses a current receipt whose inputs changed since its run, runs scripts/check-proof-receipt.sh, and a negative control on the reader. `row` and `--runs` let CI record its own run. - deed_lint.js: the §8.2-§8.4 derivation moves, unchanged, out of readProofReceipt into the exported deriveProofGrade, which the writer calls. A writer and the reader cannot disagree. 331 reader tests pass unchanged. - scripts/tests/proof-receipt-test.sh: 27 cases on a scratch home repository with a pinned sibling and a squash merge carried by an echo. Two mutations of the writer (no comment stripping; no pin check) each fail the suite. - 3-practice/PROOF-RECEIPT-SOURCE.adoc documents the source; PROOF-POLICY §8.5.1 points to the writer. self-test.yml runs both receipt suites by name. Acceptance: from a TOML transcription of secret-types' ledger the writer reproduces secret-types' main receipt (9fb8430) byte for byte, and `check` passes there; it also writes Lintel's first §8.5.1 receipt. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017yYi5JxzXZs6nz1ZSForfP
…ipt.sh The owner kept the bash generator of #1620 and closed #1626 (2026-11-17, "Keep #1620, port mine"). This merge brings main in and returns every file #1626 touched to main's version, so the branch's tree equals main and the next commit holds only the port of #1626's review fixes onto scripts/proof-receipt.sh. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017yYi5JxzXZs6nz1ZSForfP
The owner kept the bash generator of #1620 and asked for the review fixes of the closed JS writer (#1626) to be ported onto it. Five apply: - Currency covers imports (§8.5.1, Imported repositories). --check and --write now ask receipt_imports again at HEAD and compare the binding with the current row, and require each imported clone to hold the pinned files. Before, a repin that the home inputs did not see, or a sibling checkout edited since the run, passed with exit 0. - --run-row needs --axioms (none, or NAME:c|b|debt,...). The row no longer asserts "no axioms" on a run's behalf; a leg outside DTT may admit (c) axioms (§8.4) and must say so. - No HEAD fallback for the :source-commit. With no current run, --write needs --commit: HEAD on a pull request is a commit a squash merge leaves off the default branch, so the receipt would fail its git checks once merged. - A clone with neither origin/<default> nor <default> is refused (exit 2) rather than handed to the checker. - The checker's exit 2 ("cannot run") is kept as exit 2, not reported as a failed check, so CI can tell a broken environment from a refused receipt. Not ported, with reasons: claim-scoped current runs (the bash ledger has no claim scoping); the literal- and literate-aware Agda import lexer (the cone is a text scan that a home gate checks against agda --dependency-graph); the shared deriveProofGrade (the reader already re-derives every grade, with a negative control, so nothing here would call it). A single-line reported field and echo witnesses only for current legs were already in place. Tests: scripts/tests/proof-receipt-test.sh 89 passed, 0 failed (77 before). Against main's generator, with --axioms dropped from the calls, exactly the eight new refusal cases fail and the other 81 pass. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017yYi5JxzXZs6nz1ZSForfP
|
🟢 conformant · commit
Scope: DEED syntax and K9 contracts L0–L2. L3 signature verification and routed coordination files are checked by the coordination validator only. Green is limited to this scope. Orange is missing evidence; grey is an explicit scope exclusion. Logs and report.json are in the dated conformance-evidence artifact on the linked run. Base: 58797d4 (merge base), graded by this revision's checker. Checker-only categories do not depend on the tree. |
Fork governance
Scope: the three lanes below are static checks at the named commit. A K9-DEED conformance🟢 conformant · commit
K9 live corpus (L0–L2): 2 finding(s) / scope notes
Scope: K9 components L0–L2 against contract v1.0.0 at the named standards commit. L3 signature verification is not certified. coordination.k9 files are graded in their own category against the v1.2 ABNF grammar and its schema rule. Green is limited to this scope. Orange is missing evidence; yellow is grandfathered debt or warnings; grey is an explicit scope exclusion. report.json, badge.json and the validator logs are in the k9-grid artifact on the linked run. Base: 58797d4 (the PR's merge base, or the commit a push replaced), graded by this revision's checker. Hypatia verdict grid🟢 clean · commit Advisory: 12 row(s), worst 🟡 medium (0 critical, 0 high in grid scope) — reported, never grading the change. Unique graded findings across gating and advisory rows: 3 (3 reporter observations; 3 without sufficient identity to corroborate). Row counts remain per reporter; unique totals do not change gating.
panic-attack assail: 83 finding(s)
pons asinorum: 16 finding(s)
echidnabot: not_applicable — 2-protocols/k9-coordination/tools/validate/proofs/GrammarExtension.idr is typechecked by the idris2-standards job of echidna-verify.yml; 2-protocols/overlay/src/abi/OverlayProtocol.idr is unchecked in CI under the overlay KEEP-SPEC-DEFER-IMPL decision (3-practice/PROOF-NEEDS.adoc); no ECHIDNA engine is configured for this repository
rhodibot (RSR compliance): 9 finding(s)
panicbot (panic-attack, shadow of the direct panic-attack row): 83 finding(s)
sustainabot: not_applicable — reserved fleet slot; no adapter exists (gitbot-fleet bots/sustainabot/README.adoc)
glambot (presentation quality): 663 finding(s)
seambot: not_applicable — no seam register is declared (spec/seams/seam-register.json)
finishingbot (release readiness): 507 finding(s)
cipherbot: not_applicable — this repository implements no cryptography; checksums in scripts are integrity pins, not a crypto surface
accessibilitybot (WCAG on the served HTML under 2-protocols/axel/public): 33 finding(s)
ponsbot (pons asinorum, shadow of the direct pons row): 16 finding(s)
Scope: static findings reported by each row's tool at the named commit. The table grades only findings in files this change touches, so the colour answers "does this change introduce anything?", not "what does the whole repository still carry?". Standing findings are counted in each accordion and in report.json; the baseline filter remains the place where acknowledged debt is recorded. The lane state is the worst GATING row; advisory rows are listed and counted but never set it. Purple, red, yellow and blue grade the worst GRADED finding present; orange is evidence missing, malformed or a scanner that did not run; grey is an explicit scope exclusion with its reason. No row is a security certification. report.json, badge.json and the raw findings are in the verdict-grid artifact on the linked run. External reviewer coverage (advisory snapshot) Head:
|
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.
…image After the merge of main, --run-row needs --axioms (#1656) and a current run counts toward PWG-1 only when it names a digest-pinned image (#1625). The scope test's rows at the second commit had neither, so they were refused and, once accepted, derived PWG-2ii where the test asserts that a scope moves no grade. The rows now carry both. IMG is reused later in the file for an echo image, so the run image has its own variable. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013CuBToxr5h9catptGiTsFX
…-unreconciled legs; reader: foundation-diverse needs RECONCILED (#1671) ## Summary 1. `scripts/proof-receipt.sh`: new optional hook `receipt_run_scope` (rows `prover|run|claim ids`), so a superseded run that checked only some claims is listed under those claims only. Needed by hyperpolymath/januskey#186. 2. A merge of main into the branch, and a test fix: the scope test's run rows now pass `--axioms none` and `--image`, which #1656 and #1625 made necessary. 3. Found by generating hyperpolymath/resource-algebra's receipt with the shared generator and comparing the reader's output with a hand-written receipt (28 of 29 claims identical; M-2, a Lean bridge with no Agda statement, differed): - Generator: a claim whose token is not `proven` or `proven-with-postulates` is now written `AGDA-PENDING` with no receipt (it was `AGDA-VERIFIED` carrying the Agda runs). - Generator: a recheck leg in state `COQ-CHECKED`, `LEAN-CHECKED` or `BRIDGE-PENDING` now gets token `proven` (`proven-with-postulates` when its run reported an axiom), not `open`, per PROOF-POLICY §2.2. It still counts toward no grade. `COQ-CHECKED` is refused on a non-Rocq leg, `LEAN-CHECKED` on a non-Lean leg. - Generator: optional `RECEIPT_BEHOLDING_CHORA` (`#u8"…"` or `#uuid"…"`), written after `:canonical-name`. - Reader (`deed_lint.js`, `readProofReceipt`): §8.3 gives the foundation-diverse tag to a kernel-checked witness whose correspondence is recorded as in §2.2. The reader now also requires state `RECONCILED`. - With these, the generator reproduces all 29 claims of resource-algebra's receipt reader-identically. 4. `1-formats/deed/tools/README.adoc`: one sentence stating the RECONCILED condition for the tag. PROOF-POLICY §8.3/§8.5 already say this and needed no change. Waiting on this: hyperpolymath/januskey#186 and hyperpolymath/resource-algebra#52. Note the branch head is now `340f546` (docs commit on top of `f4e8304`), so pins taken at `f4e8304` still hold the code unchanged. ## Tests (real output) - `bash scripts/tests/proof-receipt-test.sh`: `131 passed, 0 failed` - `bash scripts/tests/check-proof-receipt-test.sh`: `20 passed, 0 failed` - `cd 1-formats/deed/tools && bun test deed_lint.test.js`: `337 pass, 0 fail` --- _Generated by [Claude Code](https://claude.ai/code/session_01J4QvDfoDA4uk25z9qQLeWv)_ --------- Co-authored-by: Claude <noreply@anthropic.com>
Summary
On 2026-11-17 the owner kept the bash generator from #1620 and closed the JS writer of #1626. The ruling was "Keep #1620, port mine". This PR ports the review fixes from #1626 that apply to
scripts/proof-receipt.sh. It was waiting on #1625 (the image rule), which has merged.The diff against
mainis two files. The branch also carries #1626's commits, followed by a merge that returns every file #1626 touched tomain's version, so a squash merge brings in only the port.Changes (
scripts/proof-receipt.sh)--checkwith exit 0.--checkand--writeaskreceipt_importsagain at HEAD and compare the binding with the current row. Each imported clone must hold the pinned files.--run-rowneeds--axioms--axioms noneorNAME:c|b|debt,…, as the run reported. A leg outside DTT may admit axioms of disposition (c) (§8.4) and now says so.:source-commit--writeused HEAD. On a PR that is a commit a squash merge leaves off the default branch, so the receipt failed its git checks once merged.--writerefuses unless--commitnames a commit on the default branch.Not ported, with reasons:
agda --dependency-graph, as proof: §8.5.1 receipt on the standard's shared generator; re-pin secret-types to main; legs in a pinned image lintel#31'scheck-trusted-base.shdoes.deriveProofGrade. The reader already re-derives every grade and runs a negative control, so nothing here would call it.Two fixes were already in place: a single-line
reportedfield (control characters are refused), and echo witnesses only for current legs.Testing
scripts/tests/proof-receipt-test.sh--axioms;--axioms noneandClassical:crecorded; a repin the home inputs don't see; an edited imported checkout;--checkpassing again once restored;--writewith no current run, with and without--commit; no default branch (exit 2); a checker that cannot run (exit 2).main's generator (with--axioms noneremoved from the calls)main.check-proof-receipt-test.sh;proof-inputs-sha256-test.shdeed_lint.js --self-testshellcheckonproof-receipt.shmain; none newEffect beyond this repository
Every home pins standards by commit and sha256, so nothing changes until a home bumps its pin. When it does:
--run-rowmust add--axioms none, or the axioms it reported. hyperpolymath/secret-types calls--run-rowthrough its own generator today, so this applies when it moves onto the shared generator, which is the next step the owner chose. hyperpolymath/januskey may call it; I can't see that repository from this session.--committo--write. proof: §8.5.1 receipt on the standard's shared generator; re-pin secret-types to main; legs in a pinned image lintel#31 already does.--checkruns with a sibling checkout away from its pin now fails. That is the intended fix.Generated by Claude Code