diff --git a/.github/workflows/agda-meta-checker.yml b/.github/workflows/agda-meta-checker.yml index 301110dc..271dcea8 100644 --- a/.github/workflows/agda-meta-checker.yml +++ b/.github/workflows/agda-meta-checker.yml @@ -15,6 +15,8 @@ on: - 'meta-checker/**' - 'scripts/ci/*agda.sh' - 'scripts/ci/check-receipt-controls.sh' + - 'scripts/ci/agda-cone-receipt.sh' + - 'scripts/ci/test-agda-cone-receipt.sh' - '.github/workflows/agda-meta-checker.yml' # No paths-filter on pull_request: this is a REQUIRED status check, so it must # report on every PR (a path-filtered required check deadlocks PRs that don't @@ -55,7 +57,7 @@ jobs: GH_TOKEN: ${{ github.token }} run: | set -euo pipefail - PATTERN='^(meta-checker/|scripts/ci/(setup-agda|check-agda|check-receipt-controls)\.sh$|\.github/workflows/agda-meta-checker\.yml$)' + PATTERN='^(meta-checker/|scripts/ci/(setup-agda|check-agda|check-receipt-controls|agda-cone-receipt|test-agda-cone-receipt)\.sh$|\.github/workflows/agda-meta-checker\.yml$)' if [ "${{ github.event_name }}" = "pull_request" ]; then FILES=$(gh api "repos/${{ github.repository }}/pulls/${{ github.event.pull_request.number }}/files" \ --paginate --jq '.[].filename') @@ -85,3 +87,26 @@ jobs: - name: Type-check meta-checker (PROOF-POLICY §2.1 canonical invocation) if: steps.detect.outputs.relevant == 'true' run: bash scripts/ci/check-agda.sh + + # PROOF-POLICY §8.2/§8.4: the receipt a PWG-3 grade is derived from. It + # records the toolchain, the flags, the import cone of the theory + # module with a digest per file, and a comment-aware postulate scan of + # that cone. The receipt is printed to the log and the step summary. + - name: Record the §8.2 cone receipt for the theory theorems (Receipt.agda) + if: steps.detect.outputs.relevant == 'true' + env: + AGDA_STDLIB_SHA256: 72ca3ea25094efa0439e106f0d949330414232ec4cc5c3c3316e7e70dd06d431 + run: | + set -euo pipefail + bash scripts/ci/test-agda-cone-receipt.sh + receipt="$RUNNER_TEMP/agda-cone-receipt.json" + (cd meta-checker && bash ../scripts/ci/agda-cone-receipt.sh src/Echidna/Receipt.agda) > "$receipt" + cat "$receipt" + { + echo '## PROOF-POLICY §8.2 cone receipt (Receipt.agda)' + jq -r '"commit \(.source.commit), \(.toolchain.agda), \(.import_cone.count) modules in the import cone, postulate scan: \(.postulate_scan.result)"' "$receipt" + echo + echo '```json' + cat "$receipt" + echo '```' + } >> "$GITHUB_STEP_SUMMARY" diff --git a/EXPLAINME.adoc b/EXPLAINME.adoc index 5079b7dd..01f8f3df 100644 --- a/EXPLAINME.adoc +++ b/EXPLAINME.adoc @@ -164,8 +164,13 @@ ECHIDNA-specific anchors: backends). * `generated/abi/` — auto-generated C headers from the Idris2 ABI. -The Agda meta-checker provides independent formal verification of the -Rust trust-pipeline properties; see `proofs/agda/`. +The Agda meta-checker (`meta-checker/`) type-checks *models* of the trust +pipeline and two theory results (receipt vs warrant, and proof composition +soundness over an arbitrary logic). A model is not a proof +about the Rust code: under `3-practice/PROOF-POLICY.adoc` §1 the Rust +behaviour is verified with Creusot/Pearlite and Verus on the code, and that is +still open. `proofs/agda/` is a test corpus, not evidence. Status per +obligation: `docs/PROOF-STATUS.adoc`. == File map: key modules @@ -194,7 +199,8 @@ Rust trust-pipeline properties; see `proofs/agda/`. | `src/ui/tea/`, `src/ui/public/` | TEA sources (compile pipeline unavailable) and working static shell | `src/abi/` | Idris2 formal specifications (ABI contracts + totality proofs) | `ffi/zig/`, `src/zig_ffi/` | Zig FFI implementation -| `proofs/agda/` | Agda meta-checker (independent verification of trust properties) +| `meta-checker/` | Agda meta-checker: trust-pipeline models and the receipt/warrant theory (see `docs/PROOF-STATUS.adoc`) +| `proofs/agda/` | Agda test corpus (fixtures for the Agda backend; not evidence, `PROOF-POLICY` §3) | `tests/` | Integration / property / interface test suites |=== diff --git a/docs/DEBT.adoc b/docs/DEBT.adoc index df7ba09e..1c9953ba 100644 --- a/docs/DEBT.adoc +++ b/docs/DEBT.adoc @@ -442,7 +442,7 @@ Fixed so far: the docs and the published site now say "capability present, not currently engaged" instead of claiming a step that does not run. Now machine-checked on the specification side: -`+meta-checker/src/Echidna/Integrity.agda+` (`+docs/PROOF-STATUS.adoc+` R9) +`+meta-checker/src/Echidna/Integrity.agda+` (`+docs/PROOF-STATUS.adoc+` R9, an engineering model under the 2026-11-09 §1 classification; the Rust obligation is R1) proves that verification in its model requires an initialised manifest and that an uninitialised manifest never verifies. Its explicit hypothesis is digest-comparison soundness: an accepted comparison implies equal digests. diff --git a/docs/PROOF-STATUS.adoc b/docs/PROOF-STATUS.adoc index 9d05a59c..9cf5dfc5 100644 --- a/docs/PROOF-STATUS.adoc +++ b/docs/PROOF-STATUS.adoc @@ -96,6 +96,66 @@ on `+2ab7574+`. *Rocq*: `+open+`, `+BRIDGE-PENDING+`, no receipt. *Lean*: Grades are derived from receipts, never asserted, and are never flattened into a percentage. See R5 and R6. +=== Census of theory theorems (`+PROOF-POLICY+` §8.5) + +Denominator: the fifteen theory theorems, ten in `+Receipt.agda+` (R11) and five in +`+Composition.agda+` (R6). In `+Receipt.agda+` The file has 18 top-level +proof declarations; three are inhabitation witnesses +(`+warrant-elsewhere+`, `+receipt-in-sharpened-frame+`, +`+one-passing-sample+`) and five are projections, aliases or pairings of +other results (`+postulates-name-an-axiom+`, `+discharge-postulates+`, +`+proven-in-sharpened-frame+`, `+coarse-yet-sharpened+`, +`+warrant-and-receipt+`). Those eight are not graded. `+Composition.agda+`'s five are +`+cut+`, `+explosion+`, `+compose-realised+`, `+detector-cannot-miss+` and +`+detector-must-flag+`. + +[width="100%",cols="34%,12%,12%,14%,14%,14%",options="header"] +|=== +|Theorem |§5 token |PWG |`+foundation_diverse+` |Rocq leg |Lean leg + +|`+receipt-factive+` |`+proven+` |`+PWG-3+` |no |`+open+` |`+open+` +|`+warrant-not-factive+` |`+proven+` |`+PWG-3+` |no |`+open+` |`+open+` +|`+warrant-not-receipt+` |`+proven+` |`+PWG-3+` |no |`+open+` |`+open+` +|`+no-receipt-anywhere+` |`+proven+` |`+PWG-3+` |no |`+open+` |`+open+` +|`+receipt′-factive+` |`+proven+` |`+PWG-3+` |no |`+open+` |`+open+` +|`+frame-receipt-factive+` |`+proven+` |`+PWG-3+` |no |`+open+` |`+open+` +|`+false-sample-rejected+` |`+proven+` |`+PWG-3+` |no |`+open+` |`+open+` +|`+no-free-promotion+` |`+proven+` |`+PWG-3+` |no |`+open+` |`+open+` +|`+no-unconditional-postulate-promotion+` |`+proven+` |`+PWG-3+` |no |`+open+` |`+open+` +|`+no-test-promotion+` |`+proven+` |`+PWG-3+` |no |`+open+` |`+open+` +|`+cut+` |`+argued+` |ungraded |no |`+open+` |`+open+` +|`+explosion+` |`+argued+` |ungraded |no |`+open+` |`+open+` +|`+compose-realised+` |`+argued+` |ungraded |no |`+open+` |`+open+` +|`+detector-cannot-miss+` |`+argued+` |ungraded |no |`+open+` |`+open+` +|`+detector-must-flag+` |`+argued+` |ungraded |no |`+open+` |`+open+` +|=== + +Census: `+PWG-1+` 0/15, `+PWG-2ii+` 0/15, `+PWG-2i+` 0/15, `+PWG-3+` 10/15, +ungraded 5/15. The five `+Composition.agda+` theorems stay `+argued+` and +ungraded until a source-bound receipt covers that module (R6); the cone +receipt below has `+Receipt.agda+` as its entrypoint only. No result carries `+foundation_diverse+`. + +`+PWG-3+` is derived from the receipt +link:reports/2026-11-09-agda-cone-receipt.json[`+2026-11-09-agda-cone-receipt.json+`] +(§8.2, §8.4), written by `+scripts/ci/agda-cone-receipt.sh+`: + +* Commit `+4c3ea688+`, with no uncommitted change under `+meta-checker/+`. + The `+meta-checker/+` sources are identical to `+2ab7574+`. +* Agda 2.7.0.1, executable SHA-256 `+6de41437…+` (the repository pin), and + `+agda-stdlib+` 2.1, archive SHA-256 `+72ca3ea2…+`. +* Flags `+--safe --without-K --cubical-compatible+`, entrypoint + `+src/Echidna/Receipt.agda+`, which the kernel accepted. +* An import cone of 211 modules, each with its SHA-256: 1 first-party, 202 + from the standard library and 8 from Agda's built-in library. +* A comment-aware scan of the cone that is clean. Its only postulates are + `+Agda.Primitive+`'s universe-level primitives, which belong to the + Agda kernel's trust base. + +The `+agda-meta-checker+` job writes the same receipt on every run that +touches these sources. Any change to a cone file invalidates the grade until +a fresh receipt is recorded. The ceiling is `+PWG-3+` while R5's Rocq and +Lean legs are `+open+`. + == Obligations Grouped by the `+PROOF-POLICY+` §1 mapping, because that is what decides which @@ -118,6 +178,10 @@ Annotation is not proof. It is also a *parallel model* ("`NOT a runtime dependency`"), so even a green Creusot run would cover that model, not the shipped `+src/rust/+` code, until a refinement or the annotations move onto the shipped code. *Verus:* not started; no Verus specification or proof exists. +*Known gaps the models hid (2026-11-09 audit):* dispatch accepts an unverified +solver in four ways (an `+Uninitialized+` status, a prover missing from the +manifest, no checker configured, and a `+verify_all()+` error read as an empty +report), and runs the integrity step after proving, not first. Row stays `+open+` until a Creusot or Verus run on shipped code yields a receipt with a commit hash. @@ -179,7 +243,17 @@ package: `+BojForeign+`, `+OverlayForeign+`, `+TentaclesForeign+`, packaged modules), `+CoprocessorForeign+` (an orphan whose module name does not match its path) and `+NeSyAssistTesting+` (does not parse, and states an empirical claim rather than a provable one). They carry no row until the owner -decides their fate (open question A5). +decides their fate (open question A5). *Audit 2026-11-09 of +`+verification/proofs/idris2/+`:* several modules prove less than their names say: +`+TrustLevelSoundness+` holds by definition of a local function that +disagrees with Rust; `+DispatchCorrectness+` never mentions +`+select_prover+`; `+DispatchOrdering+` proves `+LT 0 1 … LT 0 5+` over an +unused type; `+BasicTotality+` is filler by its own header; +`+ClampTrustBounds+` models a `+Nat → TrustLevel+` function that does not +exist in Rust (the real `+clamp_trust+` is a three-argument range clamp); +`+ProverKindInjectivity+` encodes 79 of 107 variants differently from +`+src/rust/ffi/mod.rs+`, so it is about a different function. Retire or +re-title them; do not count them as evidence. |=== @@ -205,6 +279,14 @@ to Idris 2 (or Creusot/Verus on the Rust), not Lean. Calling them "§4 exceptions" is not enough: no §4 exception record (reason, alternative considered) exists beside them. Owner call: write the §4 records, or move the statements to Idris 2. Being engineering proofs, they carry no PWG (§8.1). +*Audit 2026-11-09.* What the models say about the code, for R1: `+ConfidenceLattice+` matched +the pre-2026-11-09 trust rule branch for branch and now describes the old +rule; `+IntegrityVerification+` PI-11 (`+solver_integrity_ok+` iff +`+Verified+`) contradicts the four fail-open paths in dispatch, and its +collision-resistance classes assume injectivity on unbounded byte strings, +which real digests cannot satisfy; PO-12 in `+ParetoMaximality+` assumes no +two candidates share all four objective values, which real input can +violate. |=== diff --git a/docs/reports/2026-11-09-agda-cone-receipt.json b/docs/reports/2026-11-09-agda-cone-receipt.json new file mode 100644 index 00000000..c0096cb3 --- /dev/null +++ b/docs/reports/2026-11-09-agda-cone-receipt.json @@ -0,0 +1 @@ +{"import_cone":{"count":211,"modules":[{"module":"Agda.Builtin.Bool","origin":"agda-kernel","sha256":"514fa25a0df7064cdb213507a0f6332c97288a52d538be3a9df06cc7001ba7f5"},{"module":"Agda.Builtin.Equality","origin":"agda-kernel","sha256":"5735edb0be7e530133814e9431d1466bb1e7892c2a4746c1a0d2a3a0dbea91cd"},{"module":"Agda.Builtin.List","origin":"agda-kernel","sha256":"387c75a65f0f14dc6268a8cf84c93b80b7139f0e90ba6d8d6d672f02c2882195"},{"module":"Agda.Builtin.Maybe","origin":"agda-kernel","sha256":"982f7f2afbfbc4ac41b6bdafddfb5e032a5ddfa71e204f39bbecc23967dc4808"},{"module":"Agda.Builtin.Nat","origin":"agda-kernel","sha256":"2e681d9dde9a39460364ee775181f31f7bcb7eba7220bd2ab8e4deb3d02d94c9"},{"module":"Agda.Builtin.Sigma","origin":"agda-kernel","sha256":"5c393f230b359032f64ff78ad693799a162dbf9cada2089048aedb4c6f669e1f"},{"module":"Agda.Builtin.Unit","origin":"agda-kernel","sha256":"03d06283f9d8005beff99fd42de38b7315aa7697099ea22fc19d060600b16249"},{"module":"Agda.Primitive","origin":"agda-kernel","sha256":"e5e4e04900cf1a28202e2ff26bb20d6fa6401fcc9f4049cd8d14fedd5bd697f8"},{"module":"Algebra","origin":"library","sha256":"68574fe8c5138702eaaeeaf8995c18fe39aee139c7c9895530362a481598aa9a"},{"module":"Algebra.Bundles","origin":"library","sha256":"4694a20f513c393d884ced2846ec7e146765d71eecd72148499ec8aa294e4b4d"},{"module":"Algebra.Bundles.Raw","origin":"library","sha256":"63e2b1366e5981632e9f641f4ba209f2bffe4763dbe4cd66a89781d1a7e0df90"},{"module":"Algebra.Consequences.Base","origin":"library","sha256":"1dd3cc76a3d268c3a08fb3a340f9eb18e911aa863afe4b50ebd87ec301a02bd9"},{"module":"Algebra.Consequences.Propositional","origin":"library","sha256":"97a782c17117835e8248ceac1fd378de2eddc4d372fe5325c90e634218fa06bb"},{"module":"Algebra.Consequences.Setoid","origin":"library","sha256":"1446934805faf31a20c401e8567a280ac41236caac784bba0730d54af7f28da1"},{"module":"Algebra.Construct.LiftedChoice","origin":"library","sha256":"cd89bfc08389e152571023dd4878f47df09f7ab4506ff51eac2938bd09d3f977"},{"module":"Algebra.Construct.NaturalChoice.Base","origin":"library","sha256":"8342e6ca3070c23738ff4256d62d4f887d6d4a3a47ebff5536b26f2d3e9f892a"},{"module":"Algebra.Construct.NaturalChoice.Max","origin":"library","sha256":"5645ae0f79adcb3d6dea0e443e295f4a2ce41685dee91591df1838104dc1ac1e"},{"module":"Algebra.Construct.NaturalChoice.MaxOp","origin":"library","sha256":"6e542ae7c407c170b74e80caa3893ba57afe3ccd56228126511186b65585a55f"},{"module":"Algebra.Construct.NaturalChoice.Min","origin":"library","sha256":"a19b2652895621f9d7296553188db05bf104dd42d3ca9e7dadb957e3ab0d6627"},{"module":"Algebra.Construct.NaturalChoice.MinMaxOp","origin":"library","sha256":"71ea1096b7d636353016a072773a1e2865f2a668e86e1c66fa2d9dfbc0d0d9b9"},{"module":"Algebra.Construct.NaturalChoice.MinOp","origin":"library","sha256":"82e7594935a144d306d9fdeb496af03c5819d8263de1a590fdb264b08ca94b42"},{"module":"Algebra.Core","origin":"library","sha256":"7e634f414b5321bdf07203c9cf0b9b767ce3c53fe910726c40f35024e166691a"},{"module":"Algebra.Definitions","origin":"library","sha256":"8060f473f8d19bd297998b4392c2782f4727163489f8cecabe13602a98051635"},{"module":"Algebra.Definitions.RawMagma","origin":"library","sha256":"b65091be0caa130b2ff5c1ffea22792787bb72262b2b6881fb3d83d269a4380d"},{"module":"Algebra.Lattice.Bundles","origin":"library","sha256":"a98d1768afc4d20e2ec6b24ad2ceca364e4459289b711ef0b029aa8e3212a8d0"},{"module":"Algebra.Lattice.Bundles.Raw","origin":"library","sha256":"ae7723213f71c2565459ba848c11925131c52c19f220719311a3b0fdc6503c84"},{"module":"Algebra.Lattice.Construct.NaturalChoice.MaxOp","origin":"library","sha256":"f741b2fffbe5bef177e9aac75c89a9fef5a64935c507f0eed68b7e0a683e820b"},{"module":"Algebra.Lattice.Construct.NaturalChoice.MinMaxOp","origin":"library","sha256":"0e46784f879fd6ed8950589f6d4ea2f2e88923fd6dbc7f08334dd3b2f9cc07cd"},{"module":"Algebra.Lattice.Construct.NaturalChoice.MinOp","origin":"library","sha256":"c1216153d8914a0650a5ce57c713dc00e4cfd71b3ec7a7f444bd9c2a03620e1e"},{"module":"Algebra.Lattice.Properties.BooleanAlgebra","origin":"library","sha256":"585134a60483b6af035c793e666c26e39383d3a65055511cbcc4cbadf28c372c"},{"module":"Algebra.Lattice.Properties.DistributiveLattice","origin":"library","sha256":"e82b816f1ee76c26c7387286631a50345732b3d3779a608af1ed260eb985cb16"},{"module":"Algebra.Lattice.Properties.Lattice","origin":"library","sha256":"315b48528ab4f83d351fd2baf11d3dccb713266ca49036ba83bf54bdfa57afc0"},{"module":"Algebra.Lattice.Properties.Semilattice","origin":"library","sha256":"c4e30b4dfc2760990837f6308e6aeb231dc6e657d2ea2e9d66661a2dacd649d8"},{"module":"Algebra.Lattice.Structures","origin":"library","sha256":"437f53700eef1f46c55bedeffc8654d3168c4279c1b22c96b51123265ed00708"},{"module":"Algebra.Morphism","origin":"library","sha256":"8a95112ecfa55c05692178ab9bfb1ae323b22fba4cb301ed7a953831921fbda8"},{"module":"Algebra.Morphism.Definitions","origin":"library","sha256":"818270682d9684729a68bac0518e2b99298f56c3fe30b067476bf45ca3b7e3f0"},{"module":"Algebra.Morphism.Structures","origin":"library","sha256":"d788089d70bdd4d75135bbca29492edaec3842abcf5fc4f9383f18fc90701266"},{"module":"Algebra.Properties.CommutativeSemigroup","origin":"library","sha256":"6790bf6e2690dbb6a9dbd8b4dc933540d4f6290962bd78995d7756857b0bbedb"},{"module":"Algebra.Properties.Group","origin":"library","sha256":"f00e1139abc3615360c4dbea4d635169116c43d123086ce85e4722ccb65e7954"},{"module":"Algebra.Properties.Loop","origin":"library","sha256":"fe2cb895f208353e8d534b4be4479bce62f9612fb33ddc8fa5087b495688341a"},{"module":"Algebra.Properties.Quasigroup","origin":"library","sha256":"7beabe5a5838eeff9cbad00947102c7950573122feebef25c198f1c46afe2a42"},{"module":"Algebra.Properties.Semigroup","origin":"library","sha256":"4251bf552a3f38fa49d9c03cba16cf9f06d0f39bea51b2a2f5bf538668cae636"},{"module":"Algebra.Structures","origin":"library","sha256":"7cbe41828a109797b463bed65a1235f4702d941b3c55d0f574977506fc660ea9"},{"module":"Algebra.Structures.Biased","origin":"library","sha256":"f0e6579adcefdd68eed3669bed1b6b4d9437a62ea5aa60396717ba8f1e1bd2d8"},{"module":"Axiom.Extensionality.Propositional","origin":"library","sha256":"fdb5f8ea6a8942e17de4be545067b5dc7ee3081a753611f3d6f0c4a3a59e595e"},{"module":"Axiom.UniquenessOfIdentityProofs","origin":"library","sha256":"3e8130b43640052d52ce67207e057bd69eb04df769634f4833bec2057a78d885"},{"module":"Data.Bool.Base","origin":"library","sha256":"124e425ebafee9cbe8fb496b4c8467fdd372b0961ca03e445bfda506738204f6"},{"module":"Data.Bool.Properties","origin":"library","sha256":"1398693823e0edbe7f2506cc0923787fc36c49d37e68d7baa223ce845eb640ad"},{"module":"Data.Empty","origin":"library","sha256":"3a68a9e529c13054202a3892bfcf961bb75db2dc11d63f068189c4cbd48c2cd2"},{"module":"Data.Empty.Polymorphic","origin":"library","sha256":"2b8e9b1b5ad7b7d4c10b95553a96b897b2d3e6957dc1ee75f7cb8ab9fd43008a"},{"module":"Data.Fin.Base","origin":"library","sha256":"684b3764d445b4017bfbe34740198908a7d800e6abca15e38d50c7645ff704e4"},{"module":"Data.Fin.Patterns","origin":"library","sha256":"543640fa272d7d6363d3b3f0524dd5fb8c60133927d4962411629b6ac86ec2de"},{"module":"Data.Fin.Properties","origin":"library","sha256":"144e64dddd37f2bba0f6f207fdb62ba31fef1adb6292eac54770ed1003078771"},{"module":"Data.Irrelevant","origin":"library","sha256":"5f225770f471847144eb3908fecb1d4b0a06e7d7b1cb3a12bdebd840bf17a783"},{"module":"Data.List.Base","origin":"library","sha256":"d8149ac2eb98f05d9d8ddcbffa799bf26b3081edb734c5b7c0cf521ea52ced97"},{"module":"Data.List.Effectful","origin":"library","sha256":"169244f8a8a7e058bb7d5d76f77c2cf0b60539af85730843aeace899cbed37a2"},{"module":"Data.List.Extrema","origin":"library","sha256":"e177981547d339231dcd10d10c5739179d10f2685043f38e771046f740a038e9"},{"module":"Data.List.Extrema.Core","origin":"library","sha256":"d94c99fe03d45344867070f8cbaec3396c9bc623b66c4154127d1d17c9474ab2"},{"module":"Data.List.Membership.Propositional","origin":"library","sha256":"4f40d3237e3f85cb4165a0dc4622a99b964403db2463165a5c277134bcdaee10"},{"module":"Data.List.Membership.Propositional.Properties","origin":"library","sha256":"3a5c7f7aae22171961d1b028f41cd6c3a673c38a215f288f67450d217a762a90"},{"module":"Data.List.Membership.Propositional.Properties.Core","origin":"library","sha256":"f71b07e94dafb2aafd0e3deb2a7092e1e9697f039fff6c200fe6a5ad14c0b352"},{"module":"Data.List.Membership.Setoid","origin":"library","sha256":"9d15100ce32a99263f87ac66490f0826045cb163f04905bfe4076c0f38ebf373"},{"module":"Data.List.Membership.Setoid.Properties","origin":"library","sha256":"937d8518680da216f3aadde070f58fb7789df451ab9040bffdd8a5d84e3daf86"},{"module":"Data.List.Properties","origin":"library","sha256":"bb93f278aaad99dadb311bc8bad7a987594c48da412995221640c1788167d8e9"},{"module":"Data.List.Relation.Binary.Equality.Propositional","origin":"library","sha256":"5fe88f05ba8f6dd6236692949f21935663f3ab5fb7710ff76f30bca383a8a7f1"},{"module":"Data.List.Relation.Binary.Equality.Setoid","origin":"library","sha256":"44788ba07985593a5f491cb859f75c7dbec2d9bdd48435393b91d63a16a3980c"},{"module":"Data.List.Relation.Binary.Pointwise","origin":"library","sha256":"ccb0a9863bb037d1c02ce8e2eab900ce0cc14d5ede28c4fcf2157909499b5088"},{"module":"Data.List.Relation.Binary.Pointwise.Base","origin":"library","sha256":"9397d4e3340a178f8e8eb39f0d3d635047c590e3e56a9965b9346caaa48b9150"},{"module":"Data.List.Relation.Binary.Pointwise.Properties","origin":"library","sha256":"6749b77fb75551b2d8543a795ed130dc7772409dd1cce9e3c8b8d534242f0c01"},{"module":"Data.List.Relation.Binary.Subset.Propositional","origin":"library","sha256":"d4dc33e2ad8f9411f4c898a3f87279b814b7a32462987296183220a31ef2f5d4"},{"module":"Data.List.Relation.Binary.Subset.Setoid","origin":"library","sha256":"1442b2de2d6aefa3a3f3081377191ef48341f5b2aad295a685b8dfe78f0a4f64"},{"module":"Data.List.Relation.Unary.All","origin":"library","sha256":"a20287dd2f08aebfe5275130aef43c80f2dc67fd799797b4cf591ffc1eba911e"},{"module":"Data.List.Relation.Unary.All.Properties","origin":"library","sha256":"500345f52292b5fb4e183a7fa61eeba4921de5406fda8be7fae9d8a48d93c1b3"},{"module":"Data.List.Relation.Unary.AllPairs","origin":"library","sha256":"199353c7f1fea606d1172cab175da06e630bd0857ab39c343631a5b77f42d6e4"},{"module":"Data.List.Relation.Unary.AllPairs.Core","origin":"library","sha256":"7973bfc87cc4d5437cec13968245f84cd2d1ed904041f73c89fe00bfd2363af5"},{"module":"Data.List.Relation.Unary.Any","origin":"library","sha256":"4a5fd2d3e611db9dd899a24c4780d32b054fe7f826ddab0c7d3943264358bcbd"},{"module":"Data.List.Relation.Unary.Any.Properties","origin":"library","sha256":"1d2025158c384501ae9525e831925916f7dc245d2bca70fd511e198e7298d8eb"},{"module":"Data.List.Relation.Unary.Unique.Setoid","origin":"library","sha256":"bee725c98909dca4de6f0011ce76ba5f11be3fbfc81d452c9078e1fe5d3e96fc"},{"module":"Data.Maybe.Base","origin":"library","sha256":"bc28af0cccc19abd81f14e07bbb252a446d097c5a3be47c577dc459926b97c07"},{"module":"Data.Maybe.Relation.Unary.All","origin":"library","sha256":"e11263b6fc8ebf455811cae444b063bd0cd1a224d43533c1f41466752d687bde"},{"module":"Data.Maybe.Relation.Unary.Any","origin":"library","sha256":"d13a5bf5f3e86e587dae439bcc37e25f74842b944ef38525bcec40c0ca440a5e"},{"module":"Data.Nat","origin":"library","sha256":"4f947b8db93635abe0c3b9df82dac8663b38bdb6b19fc7129e2e98a9d49e60ea"},{"module":"Data.Nat.Base","origin":"library","sha256":"0d730c3d8a344c6a38b39ade22bc134f776c1de3e4afef4ec459a65a9814163d"},{"module":"Data.Nat.DivMod","origin":"library","sha256":"fc0e0f1aec03f92f40d1414736db28bb187763ac6c088a3d4249aef866bcf5cd"},{"module":"Data.Nat.DivMod.Core","origin":"library","sha256":"54890eace6f970b6809b4d54f48096ae80430f68cc899fe612eeb3a8950982d4"},{"module":"Data.Nat.Divisibility","origin":"library","sha256":"e0ef5d67aa955922e6cf638ea70b0588e0a658ec6df22dd92d9dd2c8c7ae8224"},{"module":"Data.Nat.Divisibility.Core","origin":"library","sha256":"327dc4a32d56b31b3e7f4300e4e854469055531b36f5cedf96e3376230a1ba67"},{"module":"Data.Nat.GeneralisedArithmetic","origin":"library","sha256":"fa4d41a3b14e0c7128bc3a1ad18eb19891d7610702ea89733f24d127de82f2e9"},{"module":"Data.Nat.Induction","origin":"library","sha256":"b768ba2a504ee3286612227b73e45ff4f1d92f5e6c4845577f1f5710e736741d"},{"module":"Data.Nat.Properties","origin":"library","sha256":"f68418e88255e207050e24d3f5fc5af13af4e0e9a44cf3f9b0586e95853c82f1"},{"module":"Data.Parity.Base","origin":"library","sha256":"93d9ab9884c5e2f419bdd9b2c3d98bdca11381475e8ce473783a0d73af679b17"},{"module":"Data.Product","origin":"library","sha256":"4af8b364f025b3e90991717e6fc03547c11588e88ebd776346ef90c7f83fb6ee"},{"module":"Data.Product.Algebra","origin":"library","sha256":"aa9c82d46e5fafe6bb9a1229ded9fda0c97a21697bd3dd3868a7cacc00d536dc"},{"module":"Data.Product.Base","origin":"library","sha256":"e2585b0cc6d0c2486cf1f30bd98a3855b00666e8aa8bc0aee5be8253c952a99c"},{"module":"Data.Product.Function.Dependent.Propositional","origin":"library","sha256":"006a6ed0c7d8df5898bb4acdd305fa79d7962bfbeef75e85391865c7ab71607f"},{"module":"Data.Product.Function.NonDependent.Propositional","origin":"library","sha256":"8dc88c4e65a53f93e65165b06d568d58c081b29830aa4afcbdb06ba5762b389d"},{"module":"Data.Product.Function.NonDependent.Setoid","origin":"library","sha256":"fb864f70bc1826d4b7913e244876726418267d4287e4af6398e691244b0a5571"},{"module":"Data.Product.Properties","origin":"library","sha256":"ba3d82fb3204913126f44ed57fc2a5819d267c8255f67c0f3f464b80eb909c46"},{"module":"Data.Product.Relation.Binary.Pointwise.NonDependent","origin":"library","sha256":"9ef9124ce289748a9a0367369cc53201f87703fa69cfcbd1d690ddcc57260e0f"},{"module":"Data.Product.Relation.Unary.All","origin":"library","sha256":"e7b8db12b0b07f25a4d4f9c867865c5fc1105700197d92d88cb6db96033da008"},{"module":"Data.Sign.Base","origin":"library","sha256":"6743e6b68e4746d73a3cdf0f0df48d55209ef3e8634af8275de81510e37e2996"},{"module":"Data.Sum","origin":"library","sha256":"7d5827fbbf0c998bbfa905fcaf1ba19e61db25fa578d13e6454c0e15dc67f675"},{"module":"Data.Sum.Algebra","origin":"library","sha256":"195846faf01c4745a4c574b9fbca3107883233b9f8fd46a0ea1272053d58a836"},{"module":"Data.Sum.Base","origin":"library","sha256":"2733ba66eaed94cc0f0b21f2a9ed0533f8a31b5bd487e40384632f1d6204fcfd"},{"module":"Data.Sum.Function.Propositional","origin":"library","sha256":"9f6d3668607fcc5d058e8a23dfc55e817e3e602640ab707082ba6ec40527eeb9"},{"module":"Data.Sum.Function.Setoid","origin":"library","sha256":"6c0163c61256a482d7654210abc32d92e96ce8c0f74bc604838c94a6d8459c10"},{"module":"Data.Sum.Properties","origin":"library","sha256":"003840fe29a2b4061d27c02fe45cfbc2c0491964aa500b01bc083fd550a1a4eb"},{"module":"Data.Sum.Relation.Binary.Pointwise","origin":"library","sha256":"b5e7cba494eb2906049c2d67e652f71fb2e9939be70b25090e5a5444bc0becec"},{"module":"Data.These.Base","origin":"library","sha256":"7f2d088485b960b9ec36cf1923e7b8f07eeb0c57c3fb58e4d05f5e437de84031"},{"module":"Data.Unit","origin":"library","sha256":"320fc4c784fbb6ad847f41ae317f60da346002a119cbca178b2caaa787c2b26c"},{"module":"Data.Unit.Base","origin":"library","sha256":"38cc799f18b6f106336ace8ae66c5a171251c0eb3b6bf32124e33c45d441b2fb"},{"module":"Data.Unit.Polymorphic","origin":"library","sha256":"59060da4fa9b4d71d50ca1330662ff93f691c9b0e606b4a7f6ed9ab58ec6d9b0"},{"module":"Data.Unit.Polymorphic.Base","origin":"library","sha256":"002ae814be1dafd6f6c4193a2254ee19f7793ffef7dcf1d29f9794db0b19f2a8"},{"module":"Data.Unit.Polymorphic.Properties","origin":"library","sha256":"dddc5bdea96be1c01e2952b104c2a04405d2367d6f74f1c104311d05dc12569d"},{"module":"Data.Unit.Properties","origin":"library","sha256":"bb9a390596f27739aa9d9c46ef666e42917df4f5000f675ef1042abe3fe2fc62"},{"module":"Data.Vec","origin":"library","sha256":"79fd35e68ccb8722d3bead8259961ff58fff4b7e9b60a95dc3daa6cb54bad567"},{"module":"Data.Vec.Base","origin":"library","sha256":"73e1151d72d0a4c43496e86bb840ff4f69304c4813a22835937f6017f9accc2e"},{"module":"Data.Vec.Bounded.Base","origin":"library","sha256":"8469f114552ea6ddbb3ef5c0ce3d538a304afd1ae0fbbd54e129891eeff25d2d"},{"module":"Data.Vec.Membership.Propositional","origin":"library","sha256":"14d130719a6b78dcabe1fb18e022a9029f257e2cab8536f284e8fdfdaacf4c61"},{"module":"Data.Vec.Membership.Setoid","origin":"library","sha256":"8ae75229b11fc0f660013833427b9f76f419213417d02b77d832e45b771988a3"},{"module":"Data.Vec.Relation.Unary.All","origin":"library","sha256":"747d8ed58dab65dbbd897cc100156bf6006457cff23a3d46d2ee187fba0f4b84"},{"module":"Data.Vec.Relation.Unary.Any","origin":"library","sha256":"08ffde09605128b3a79a1121e83924d3ee563067d93e231805285c63e50e50be"},{"module":"Echidna.Receipt","origin":"first-party","sha256":"6741bae9360b0b3064ef67b073c06f2831775b70eeb01e1d6e998bc74f02c6e2"},{"module":"Effect.Applicative","origin":"library","sha256":"329c5a59e13bb7449d4fc096a2be47563d53a7082a8ebe81f2b1c61062892d1a"},{"module":"Effect.Choice","origin":"library","sha256":"dc42c9aa4feadfeb76377fdfe1cd1fe5c94830aa941bf88986b11333e4b521ca"},{"module":"Effect.Empty","origin":"library","sha256":"9adc04cbc9b02109047f4f04ed440659d65c766a7b652cd5f6c0af5519d9f8c2"},{"module":"Effect.Functor","origin":"library","sha256":"45fd600321ef1272d2979b3dd85467b91b17630ce69bdbe0e9059381d1c495b4"},{"module":"Effect.Monad","origin":"library","sha256":"dd3b60f2e84fb9ffbfd5053d30caa041ab9749b38c637713b3cad8c477be72bf"},{"module":"Function.Base","origin":"library","sha256":"b021bf843c1974a5d50a1a3362f2d6447018629331a3dc2bb0d9ea85ec029e84"},{"module":"Function.Bundles","origin":"library","sha256":"10a990323e8128199017fe5bfe1ead05a2c18cd3e441b47d6903ef1ec96cfa66"},{"module":"Function.Consequences","origin":"library","sha256":"5cb682d31dc4340e805074791971c6a1dfb49b9d9c931d3e2a9fd2b53b27c11d"},{"module":"Function.Consequences.Propositional","origin":"library","sha256":"8789e6dbfb50651eb93390cb938f8be825c704ffbac99b585810b379308a7702"},{"module":"Function.Consequences.Setoid","origin":"library","sha256":"3ebed8b4ab2d51527e98a3fa50927b5ee75d2a429ecaea4401f7d5e8e38bfb51"},{"module":"Function.Construct.Composition","origin":"library","sha256":"c1caf4f975f57948be134c6fbd1a4b08a933bf2eadfb00ba0645c163302552bd"},{"module":"Function.Construct.Identity","origin":"library","sha256":"afbc000aafc7ef4a2d9a8a431cceaf87d565310d654d60af65f573f04faaba48"},{"module":"Function.Construct.Symmetry","origin":"library","sha256":"e42e0277b255b56a19eefcc7754505de81af865e8aaf7873c10f3e8bec4f0bb9"},{"module":"Function.Core","origin":"library","sha256":"306e35bc28d015d0c3807bde740d1070d79a606c4df81e3d2f67690367958fb0"},{"module":"Function.Definitions","origin":"library","sha256":"6ce79a18384fdae5e01210d1a75a0b4e76004bb07b61024fdc8c5f0cdee17ee5"},{"module":"Function.Dependent.Bundles","origin":"library","sha256":"75bd0bfe77b56a5f1e419c911394dbb18ea395df59560a35d4eab4e8363afdee"},{"module":"Function.Indexed.Relation.Binary.Equality","origin":"library","sha256":"5a9207f7b734362802621b6e58ca763becc510cc8c21f3fee1936d019264d2de"},{"module":"Function.Metric.Bundles","origin":"library","sha256":"e9be9de709f21375d874245cf1812f964abc98cc0f4893e46ec34360296b8160"},{"module":"Function.Metric.Core","origin":"library","sha256":"77fbc11ef41b2d0902505dae9ff9d18b9b09cf1a47e0525acd43c57911463e24"},{"module":"Function.Metric.Definitions","origin":"library","sha256":"4fd018bd96f6ba92a338916b536605987d715a149a509ce2351883d47cc726e1"},{"module":"Function.Metric.Nat","origin":"library","sha256":"2d2938867367ca5fefc0449ebe8b7aafd7149dfac8f98ce81a24238fc8b7a5de"},{"module":"Function.Metric.Nat.Bundles","origin":"library","sha256":"be03a9ea8596b75c7cdffb0e839b314bcc4a258054346ef48414bbf3ac25350d"},{"module":"Function.Metric.Nat.Core","origin":"library","sha256":"d53ba974cdf065994ec1035ef88049b6c411aa8521291076ddd229b61e008d4a"},{"module":"Function.Metric.Nat.Definitions","origin":"library","sha256":"358c5ab7adfb0a87300647be0c706f34ae6a6b4c540b1394cf5620b82eca9171"},{"module":"Function.Metric.Nat.Structures","origin":"library","sha256":"09cbfd1026d06d914d211b9fd77787ac0fd86d0b0bab98743ca72d8d12e6e5e8"},{"module":"Function.Metric.Structures","origin":"library","sha256":"6fc2c084b6d38a88cc800abb935335fb475931636b071db78a0d4a9de30f7ce4"},{"module":"Function.Properties.Bijection","origin":"library","sha256":"a970f070c861154784b4edb6bbeea0f859d93553a50f859dee8a4f7439d17565"},{"module":"Function.Properties.Inverse","origin":"library","sha256":"e0ec3e0ed86cc551a501b20c81312963bf0602fa232054c1b0ff1415edf97d09"},{"module":"Function.Properties.Inverse.HalfAdjointEquivalence","origin":"library","sha256":"94e285d8f62a8fc4810d4ff918f69aac51c5711bc89b75228ce45e33f82b477c"},{"module":"Function.Properties.RightInverse","origin":"library","sha256":"07210f0a8c381f69ef78075d25c6abb281c1ad22f5733e7aaf1f8ebd1ec41062"},{"module":"Function.Properties.Surjection","origin":"library","sha256":"5f98ec8208937948df2c9e31a8d95b7464959c077ff3b35bd2f94ed855c01581"},{"module":"Function.Related.Propositional","origin":"library","sha256":"6ab8ab57b90c9d75f038d25eb27542fff81aaa17e87995f1b3eb5773e2bf96c4"},{"module":"Function.Related.TypeIsomorphisms","origin":"library","sha256":"600690000a6e5ce57fb756587bd512f06ea3bb4a3ef64d9d51349ab13ac8522a"},{"module":"Function.Structures","origin":"library","sha256":"c84e2367ab099bbf55662e537fa6fec597a2fe56393d28e2beade67271e89091"},{"module":"Induction","origin":"library","sha256":"4638093055dc290aa9ad7bd128ac2bed705f00a02f98eb1a390d173b5472aaee"},{"module":"Induction.WellFounded","origin":"library","sha256":"ec6d272aafaf25d841813233833c17f9b62e063fc81d8afbde6851924e461943"},{"module":"Level","origin":"library","sha256":"1168f8373370c10aec0f20bae0cc43db9a34331a49deb4c72efd2574a638a278"},{"module":"Relation.Binary","origin":"library","sha256":"0aafa1229fd4093c924e19f6d64e518a998f352d725af856d4342f3ecd5b0b7d"},{"module":"Relation.Binary.Bundles","origin":"library","sha256":"fd4b0a832bf9f372d2739668c7e0988e0242519686b69616dc67043923ad88c3"},{"module":"Relation.Binary.Consequences","origin":"library","sha256":"d5f1d178492b9e485a3efdcb16dd18fe623896371e2cae3662d8fde1ff94a455"},{"module":"Relation.Binary.Construct.Composition","origin":"library","sha256":"829ca14501f085b08a0504a61c7874cd20cce07ffc883027ef3465e4f44cf347"},{"module":"Relation.Binary.Construct.Flip.EqAndOrd","origin":"library","sha256":"2ac3cd0c1dfec3cb7470f638172c6c4a0c37492ac7625faebe88d8081aed5576"},{"module":"Relation.Binary.Construct.Intersection","origin":"library","sha256":"8dce90a37b1086e18a5844a373ecba240c3740bce099ca2cb1798db734c59d3e"},{"module":"Relation.Binary.Construct.NaturalOrder.Left","origin":"library","sha256":"ecd11c100db5128f1e5a80dcbf365dc5791fdbb6282d189044ca98e1ca945b87"},{"module":"Relation.Binary.Construct.NonStrictToStrict","origin":"library","sha256":"15701c27241a2c7d182cb8c4cbb677196921a995a9fae11a9b4f1f6b494f2d40"},{"module":"Relation.Binary.Construct.On","origin":"library","sha256":"dc3e20ecea3052a02a56229073806bd421e9afdd51d410daee5b8ba43edcd965"},{"module":"Relation.Binary.Core","origin":"library","sha256":"09eda35f4c2f795542f0a2468ade41793e9c9e07889553989e03d343902fcb81"},{"module":"Relation.Binary.Definitions","origin":"library","sha256":"c61495efb42702588229a67461c451dd660bd5d686c244ee1895b9d563547783"},{"module":"Relation.Binary.Indexed.Heterogeneous","origin":"library","sha256":"31fea63ecce5f5f63e13e667a04bd4062f2bfafd9d8215514144e6c28d5b813f"},{"module":"Relation.Binary.Indexed.Heterogeneous.Bundles","origin":"library","sha256":"91210765ebc0293ad041007a0703d93f70d127bdcb045aefeb5e208d1e8b3c06"},{"module":"Relation.Binary.Indexed.Heterogeneous.Construct.Trivial","origin":"library","sha256":"bad2cb0132c973b728690a6467c70bb97aec0aec748eeb7e40a5a640cad45624"},{"module":"Relation.Binary.Indexed.Heterogeneous.Core","origin":"library","sha256":"623b155a1a393ffba78cc893cfba7ce55fec3d49b0ddcd56940b3bd811c28205"},{"module":"Relation.Binary.Indexed.Heterogeneous.Definitions","origin":"library","sha256":"997789408b78b154c81039248354a53dba1c8bcfb873f95636c2dea566089faf"},{"module":"Relation.Binary.Indexed.Heterogeneous.Structures","origin":"library","sha256":"8c48074820f087b9cc507cf7a7db9134f98094a8d82cbc5d391f4ed6e0a7ef84"},{"module":"Relation.Binary.Lattice","origin":"library","sha256":"fd16f6140ae748bb42d2427b8616699d3189d7c2833d2c9d4a968780dae05c26"},{"module":"Relation.Binary.Lattice.Bundles","origin":"library","sha256":"6cdddaed92e07bb7ba4ee39d5e529729c396dcbe3c0f64c469e1ae6d3fa268a9"},{"module":"Relation.Binary.Lattice.Definitions","origin":"library","sha256":"93e0469e47b8ac5bf976432ac83844fcde6e72b71a31cc5700ca1eb595760ce2"},{"module":"Relation.Binary.Lattice.Structures","origin":"library","sha256":"3ab1e5fedbad8cfae67bb5e9dfe012da8c3a4855ae7008ea193e82ec1548bcb5"},{"module":"Relation.Binary.Morphism.Definitions","origin":"library","sha256":"c85beed5112ece49ef091767ce2f8c70581e079bcb2a58d07d18ca06f1389f54"},{"module":"Relation.Binary.Morphism.Structures","origin":"library","sha256":"8aa178e3a7593274250db79c716b4380a458b925f928f234fdb1242b6ad8ef30"},{"module":"Relation.Binary.Properties.DecTotalOrder","origin":"library","sha256":"9410bdcd82e3e7757c1aeac5ae8cad77907ef71d7f5fc7d18695a8cf1b09a657"},{"module":"Relation.Binary.Properties.Poset","origin":"library","sha256":"27eae427096c8eb26d25feb2a5f6053ac210f63d44b09f04c4f71ecc45dbb805"},{"module":"Relation.Binary.Properties.Preorder","origin":"library","sha256":"33eacd3ad2d59770a6dd7fc151a7dd51d4d78c0bb0a7617f90dce7701ae9190e"},{"module":"Relation.Binary.Properties.Setoid","origin":"library","sha256":"ba05a90fbede6b120c7aefe56944f0c5c772f908a1f60d1644ec4c70c9a93293"},{"module":"Relation.Binary.Properties.TotalOrder","origin":"library","sha256":"4043bd7493adbb40e52b432e00c48c07c54d2574c0997bfeb8989e8b764e6f05"},{"module":"Relation.Binary.PropositionalEquality","origin":"library","sha256":"e854dcea3dd081440fecf39ae9124ef1695607f232fd2452a896a1d3cc64e645"},{"module":"Relation.Binary.PropositionalEquality.Algebra","origin":"library","sha256":"7575a469a6bb49a210266444989693340209c015ee28c49a4627ee63895ed46c"},{"module":"Relation.Binary.PropositionalEquality.Core","origin":"library","sha256":"480da0675a0d8ddddcae5c4f74c5526a5da88790fef387aa8b8213dabf842200"},{"module":"Relation.Binary.PropositionalEquality.Properties","origin":"library","sha256":"4ed071c430e9244d3be9b9ca847d74232826c0fed7bf3035da0a6d4a8c7b2137"},{"module":"Relation.Binary.Reasoning.Base.Double","origin":"library","sha256":"11dd426aff0ac8176e6ce929075985c97b2b291c4081d8a7e4620bf6b3489bb3"},{"module":"Relation.Binary.Reasoning.Base.Single","origin":"library","sha256":"489173b58679a1df8b584ca5b86bc392ab9dcbaff40c0c596d9ae952cb935c1b"},{"module":"Relation.Binary.Reasoning.Base.Triple","origin":"library","sha256":"2b4a8f6a4e390a16a48c2c9d14f1fde4b6d861f9dad82d4b144f9a6e74d43e16"},{"module":"Relation.Binary.Reasoning.Preorder","origin":"library","sha256":"82eb3f11d5df9160a068f07a7285c86183875d7df43c373145ea7aaccb3d3f38"},{"module":"Relation.Binary.Reasoning.Setoid","origin":"library","sha256":"9c5553d148470d809a3986b5f1377de6acaca1a45b39df2165d8e0d288fa5049"},{"module":"Relation.Binary.Reasoning.Syntax","origin":"library","sha256":"a7a831d62ed2a3c7d5d0f29521162fbf264d34a48b6c91e9ac9f6168c2067ceb"},{"module":"Relation.Binary.Structures","origin":"library","sha256":"12ccbc4bd7da510ed8edf17018eb10b3d827e08ba1842a623c3370c2cb6ef396"},{"module":"Relation.Binary.Structures.Biased","origin":"library","sha256":"2178213579d5821d3a67fdde7600c32dacd571d1a57c82dc76504e42a814219f"},{"module":"Relation.Nullary","origin":"library","sha256":"56f7f4a54b8d655b0c90dacfd65d29cfc2d7e73d8666bd30a934ae25818a5019"},{"module":"Relation.Nullary.Decidable","origin":"library","sha256":"51c4e7dd26928e770380a6d1b7e01418fd1ab2575f80cf7aaf6db4e49f6947d0"},{"module":"Relation.Nullary.Decidable.Core","origin":"library","sha256":"0082f72e3d2bd247d56d46abf3f70936a08d32c69c3a18cb68f744c8fefb67b8"},{"module":"Relation.Nullary.Indexed","origin":"library","sha256":"fc2ab3ff0e19e4fdc124959c3c1d3a659411100a5b673f5602858cb98b1c8947"},{"module":"Relation.Nullary.Negation","origin":"library","sha256":"2a13db6c365bd54a4d82306dd1fd13b8192539e49dc873ccb1ac5159d6c1b28f"},{"module":"Relation.Nullary.Negation.Core","origin":"library","sha256":"b848e89c226674f8462c9c5aced87e5aa3fe03fdf9cbaffd0c28e9f87ff6c910"},{"module":"Relation.Nullary.Recomputable","origin":"library","sha256":"cacf1a1d98ceed1571bac2ca9a3c1f9967ea6c91fd0dc0ed35b5fc74657b7ce0"},{"module":"Relation.Nullary.Reflects","origin":"library","sha256":"73ec20b5e43a3903b68b994cd0815b9d0c3dcc9e57dae39b4d8b487904a7eea1"},{"module":"Relation.Unary","origin":"library","sha256":"4960f1b9004f19834cbc0271b80a64281a99ba715ffa125f73df80f205745a71"},{"module":"Relation.Unary.PredicateTransformer","origin":"library","sha256":"0d542136370cd7917163dc62278ad7df0e66c0e1c4426e590dbff78ea1b462aa"},{"module":"Relation.Unary.Properties","origin":"library","sha256":"98196ae2887abd71ff2ee3120418e6549dd21792048e431a11e2026169eb0d24"}]},"kind":"agda-cone-receipt","policy":"standards 3-practice/PROOF-POLICY.adoc §8.2, §8.4","postulate_scan":{"findings":[],"kernel_primitives":[{"line":26,"module":"Agda.Primitive","text":"postulate"},{"line":34,"module":"Agda.Primitive","text":"postulate"}],"method":"comment-aware: nested block and line comments removed, pragmas kept; string literals not lexed","result":"clean"},"schema_version":1,"source":{"commit":"4c3ea688bf19c361f6339f66f853090253df0d7b","entrypoint":"src/Echidna/Receipt.agda","repository":"https://github.com/hyperpolymath/echidna","uncommitted_changes_under_entry_dir":false},"toolchain":{"agda":"Agda version 2.7.0.1","agda_executable_sha256":"6de41437c14c05c9fe576d724cc67386444c0fa9fee662a08250fefb91bee8b6","flags":["--safe","--without-K","--cubical-compatible"],"stdlib_archive_sha256":"72ca3ea25094efa0439e106f0d949330414232ec4cc5c3c3316e7e70dd06d431"}} diff --git a/scripts/ci/agda-cone-receipt.sh b/scripts/ci/agda-cone-receipt.sh new file mode 100755 index 00000000..042a4f2f --- /dev/null +++ b/scripts/ci/agda-cone-receipt.sh @@ -0,0 +1,138 @@ +#!/usr/bin/env bash +# SPDX-License-Identifier: MPL-2.0 +# Copyright (c) 2026 Jonathan D.A. Jewell +# +# agda-cone-receipt.sh ENTRY.agda — the PROOF-POLICY §8.2 receipt for the +# theory theorems in ENTRY: the Agda version, the standard-library pin, the +# flags in force, the import cone with a SHA-256 per file, and a +# comment-aware scan of that cone for postulates, unsafe pragmas and +# primTrustMe (§8.4). Writes one JCS object to stdout. +# +# Run from meta-checker/ after scripts/ci/check-agda.sh, in the environment +# scripts/ci/setup-agda.sh prepares (AGDA_LIBRARIES_FILE, Agda_datadir). +# AGDA_STDLIB_SHA256 names the pinned stdlib archive digest. +# +# The scan reads Agda source with nested {- -} block comments and -- line +# comments removed and {-# #-} pragmas kept. It does not lex string +# literals; a literal holding "{-" would hide text from it, and --safe is +# still the check that refuses escape hatches. The scan is the record §8.4 +# asks for, not a replacement for --safe. +# +# Postulates in the Agda data directory (Agda.Primitive's universe-level +# primitives) belong to the Agda kernel's trust base. They are listed in the +# receipt, not counted as findings. +# +# Exit codes: 0 receipt written and the scan is clean, 1 a finding outside +# the kernel's own primitives, 2 cannot run. +set -euo pipefail +export LC_ALL=C.UTF-8 + +# strip : source with comments removed and pragmas kept. +strip() { + awk ' + { line = $0; out = ""; i = 1; n = length(line) + while (i <= n) { + two = substr(line, i, 2); three = substr(line, i, 3) + if (depth == 0 && inpragma == 0 && three == "{-#") { inpragma = 1; out = out three; i += 3; continue } + if (inpragma == 1 && three == "#-}") { inpragma = 0; out = out three; i += 3; continue } + if (inpragma == 1) { out = out substr(line, i, 1); i++; continue } + if (depth == 0 && two == "--") break + if (two == "{-") { depth++; i += 2; continue } + if (depth > 0 && two == "-}") { depth--; i += 2; continue } + if (depth == 0) out = out substr(line, i, 1) + i++ + } + print out }' "$1" +} + +# scan: the escape hatches the receipt records, one "line:text" per hit. +scan() { + { strip "$1" | grep -nE '(^|[[:space:](){};])postulate($|[[:space:](){};])|\{-#[[:space:]]*(TERMINATING|NON_TERMINATING|NO_POSITIVITY_CHECK|NO_UNIVERSE_CHECK|NON_COVERING)|primTrustMe' || true; } +} + +# Sourced by scripts/ci/test-agda-cone-receipt.sh for strip and scan only. +# shellcheck disable=SC2317 # exit runs only when executed rather than sourced +if [[ "${AGDA_CONE_RECEIPT_FUNCTIONS_ONLY:-}" == 1 ]]; then return 0 2>/dev/null || exit 0; fi + +entry=${1:?usage: agda-cone-receipt.sh ENTRY.agda} +flags=(--safe --without-K --cubical-compatible) +if ! command -v agda >/dev/null 2>&1 || [[ ! -f "${AGDA_LIBRARIES_FILE:-}" ]]; then + echo "agda-cone-receipt: pinned Agda setup missing" >&2; exit 2 +fi +command -v jq >/dev/null 2>&1 || { echo "agda-cone-receipt: jq missing" >&2; exit 2; } + +tmp=$(mktemp -d) +trap 'rm -rf "$tmp"' EXIT + +agda --no-default-libraries --library-file "$AGDA_LIBRARIES_FILE" "${flags[@]}" \ + --dependency-graph="$tmp/cone.dot" "$entry" > "$tmp/agda.log" 2>&1 \ + || { cat "$tmp/agda.log" >&2; echo "agda-cone-receipt: agda failed" >&2; exit 2; } + +data_dir=$(agda --print-agda-data-dir) +# Include roots: the Agda data directory's lib/prim, then every library's +# include directories from the library file (one .agda-lib path per line). +roots=("$data_dir/lib/prim") +while IFS= read -r lib; do + [[ -n "$lib" ]] || continue + libdir=$(dirname -- "$lib") + while IFS= read -r inc; do + roots+=("$libdir/$inc") + done < <(awk '/^include:/ { sub(/^include:[[:space:]]*/, ""); n = split($0, a, /[[:space:]]+/); for (i = 1; i <= n; i++) if (a[i] != "") print a[i] }' "$lib") +done < "$AGDA_LIBRARIES_FILE" + +# Module names from the dot file's node labels. +grep -oE 'label="[^"]+"' "$tmp/cone.dot" | sed -E 's/^label="//; s/"$//' | sort -u > "$tmp/modules" +[[ -s "$tmp/modules" ]] || { echo "agda-cone-receipt: empty dependency graph" >&2; exit 2; } + +: > "$tmp/cone.jsonl"; : > "$tmp/findings.jsonl"; : > "$tmp/kernel.jsonl" +while IFS= read -r module; do + rel="${module//.//}" + file="" + for root in "${roots[@]}"; do + for ext in agda lagda lagda.md; do + [[ -f "$root/$rel.$ext" ]] && { file="$root/$rel.$ext"; break 2; } + done + done + [[ -n "$file" ]] || { echo "agda-cone-receipt: cannot locate module $module" >&2; exit 2; } + file=$(realpath -- "$file") + case "$file" in + "$(realpath -- "$data_dir")"/*) origin=agda-kernel ;; + "$(realpath -- "$PWD")"/*) origin=first-party ;; + *) origin=library ;; + esac + digest=$(sha256sum "$file" | cut -d' ' -f1) + jq -cn --arg m "$module" --arg o "$origin" --arg d "$digest" '{module: $m, origin: $o, sha256: $d}' >> "$tmp/cone.jsonl" + scan "$file" \ + | while IFS=: read -r ln text; do + if [[ "$origin" == agda-kernel ]]; then target="$tmp/kernel.jsonl"; else target="$tmp/findings.jsonl"; fi + jq -cn --arg m "$module" --argjson l "$ln" --arg t "$text" '{module: $m, line: $l, text: ($t | gsub("^\\s+|\\s+$"; ""))}' >> "$target" + done +done < "$tmp/modules" + +commit=$(git rev-parse HEAD) +dirty=$(git status --porcelain -- . | head -1) +agda_bin=$(command -v agda) +jq -cnS \ + --arg commit "$commit" --arg dirty "${dirty:+yes}" --arg entry "$entry" \ + --arg agda "$(agda --version)" --arg agda_sha "$(sha256sum "$agda_bin" | cut -d' ' -f1)" \ + --arg stdlib_sha "${AGDA_STDLIB_SHA256:-unrecorded}" \ + --argjson flags "$(printf '%s\n' "${flags[@]}" | jq -R . | jq -s .)" \ + --slurpfile cone "$tmp/cone.jsonl" --slurpfile findings "$tmp/findings.jsonl" \ + --slurpfile kernel "$tmp/kernel.jsonl" ' + { + schema_version: 1, + kind: "agda-cone-receipt", + policy: "standards 3-practice/PROOF-POLICY.adoc §8.2, §8.4", + source: {repository: "https://github.com/hyperpolymath/echidna", commit: $commit, + uncommitted_changes_under_entry_dir: ($dirty == "yes"), entrypoint: $entry}, + toolchain: {agda: $agda, agda_executable_sha256: $agda_sha, + stdlib_archive_sha256: $stdlib_sha, flags: $flags}, + import_cone: {count: ($cone | length), modules: $cone}, + postulate_scan: { + method: "comment-aware: nested block and line comments removed, pragmas kept; string literals not lexed", + kernel_primitives: $kernel, + findings: $findings, + result: (if ($findings | length) == 0 then "clean" else "findings" end) + } + }' +[[ ! -s "$tmp/findings.jsonl" ]] diff --git a/scripts/ci/test-agda-cone-receipt.sh b/scripts/ci/test-agda-cone-receipt.sh new file mode 100755 index 00000000..4998508f --- /dev/null +++ b/scripts/ci/test-agda-cone-receipt.sh @@ -0,0 +1,32 @@ +#!/usr/bin/env bash +# SPDX-License-Identifier: MPL-2.0 +# Copyright (c) 2026 Jonathan D.A. Jewell +# Fixture test for the comment-aware scan in agda-cone-receipt.sh: comments +# (line, block, nested) hide nothing they should not, pragmas stay visible, +# and only the keyword `postulate` counts, not identifiers that contain it. +set -euo pipefail +here=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd) +# shellcheck source=scripts/ci/agda-cone-receipt.sh +AGDA_CONE_RECEIPT_FUNCTIONS_ONLY=1 . "$here/agda-cone-receipt.sh" +tmp=$(mktemp -d) +trap 'rm -rf "$tmp"' EXIT +cat > "$tmp/Fx.agda" <<'AGDA' +module Fx where +-- postulate in a line comment +{- postulate in a block {- nested postulate -} still comment postulate -} +x = 1 -- trailing postulate +{-# TERMINATING #-} +postulate + ax : Set +postulates-name : Set +f = primTrustMe +{-# OPTIONS --safe #-} +AGDA +got=$(scan "$tmp/Fx.agda" | cut -d: -f1 | tr '\n' ' ') +want="5 6 9 " +if [[ "$got" == "$want" ]]; then + echo "agda-cone-receipt scan: ok (hits on lines $got)" +else + echo "::error::agda-cone-receipt scan: hits on lines '$got', want '$want'" + exit 1 +fi