Repository navigation
Description
What
Six Idris2 modules exist twice, with identical blob SHAs in both locations:
| Module | src/abi/ |
src/Hypatia/ABI/ |
|---|---|---|
FFI.idr · GRPC.idr · GraphQL.idr · REST.idr · RuleEngine.idr · Types.idr |
dead copy | live |
src/abi/hypatia-abi.ipkg sets sourcedir = "..", which resolves to src/,
so modules = Hypatia.ABI.Types compiles src/Hypatia/ABI/Types.idr. The
src/abi/*.idr copies are compiled by nothing.
They are not harmless. PR #811 found that
test/unified-api-adapter-contract_test.exs bound its golden source to the
dead src/abi/Types.idr — so the live ABI could drift and the guard would
stay green. That was instance 21 of the guard-asks-a-different-question trap,
and it was fixed in #811. The duplicates that made it possible are still here.
Blast radius — measured
~15 files name the dead path. Only the Elixir guard read it (now fixed);
the rest are prose and doc comments:
schema/README.adoc, ffi/zig/README.adoc, verification/PROOF-STATUS.adoc,
docs/operations/prover-wars-integration.adoc, ffi/connectors.json, doc
comments in ffi/zig/src/main.zig, ffi/zig/src/unified-api-adapter.zig,
clients/rust/hypatia-client/src/connector.rs, .../lib.rs, .../types.rs,
.../ffi.rs, verification/proofs/idris2/ConfidenceBounds.idr, a
data/verisim record, test/sensor_test.exs.
Acceptance criteria
- The six
src/abi/*.idrfiles are deleted. -
idris2 --build src/abi/hypatia-abi.ipkgstill succeeds — proving the
ipkg was compiling the live tree all along, which is the claim this issue
rests on. -
idris2 --build src/abi/hypatia-abi-gen.ipkgstill succeeds and
just abi-genstill produces a zero diff. - Every one of the ~15 references is repointed to
src/Hypatia/ABI/<Module>.idr. Verify by a repo-wide grep for
src/abi/.*\.idrreturning only the.ipkgfiles. -
grep -cbefore and after is recorded in the PR, so the denominator is
stated rather than "all references updated" being asserted. -
mix testand.github/workflows/abi-codegen-drift.ymlboth stay green.
Activity
fix(ffi/zig): migrate to the Zig 0.16 std, then gate it — tests, C AB…