Skip to content

P1-0 (B): claims ledger — run every TESTED row, reconcile test/proof counts - #146

Merged
hyperpolymath merged 4 commits into
mainfrom
feat/claims-ledger
Oct 2, 2026
Merged

hyperpolymath merged 4 commits into
mainfrom
feat/claims-ledger

Conversation

@hyperpolymath

@hyperpolymath hyperpolymath commented Oct 2, 2026 •

Copy link
Copy Markdown
Owner

ULTRAPLAN P1-0, PR B of three (B: ledger + counts; C: escape-hatch counter; D: workflow_call).

Stacked on #144. This branch contains #144's commit e6fee67, so review only 6f31e89 and the docs follow-up. It stays a draft until #144 merges; then it is rebased onto main and marked ready.

What it does

PROOF-NEEDS.adoc gains a === Claims ledger table. Each row is claim | status | artefact | command, with status PROVEN / TESTED / ASSUMED / DESIGNED / OPEN, and each row fits on one line. dashboard-check --check . (already run by dashboard-check.yml) now does the following:

Status Rule
TESTED The artefact file::test must exist and name the test. The command must exit 0, and some output line must show that test passing (ok/PASS). That rejects true and a filter that runs 0 tests.
PROVEN The file must name the theorem, and the checker command must exit 0.
ASSUMED / DESIGNED / OPEN The command must be -. The artefact must be an existing file or #N.
any A wrapped row, an unknown status, or a missing table fails and names the line.

Dashboard counts. On README / EXPLAINME / TOPOLOGY / READINESS, a number followed within two words by test(s) must equal cargo test --workspace --locked -- --list (lines ending : test). A number followed by proof(s)/theorem(s) must equal the number of PROVEN rows. Percentages are excluded, and so are numbers in another table cell.

Ledger contents: 7 TESTED rows (obliteration ×3, execute∘undo, content-store round-trip, rollback, audit-chain verify) and 2 OPEN rows (#145). 0 PROVEN, because the Idris2 ABI does not typecheck.

Doc corrections the checker forced

Where Was Now
READINESS:11, :67; TOPOLOGY:82 67 tests 119 tests
READINESS:11, :63, :67; TOPOLOGY:80 30 (Idris2) proofs, row 16 ✓ 0 checked (#145), row 16 ✗

TOPOLOGY "Last updated" → 2026-10-02.

Scope limits (stated, not implied)

  • Only test/proof counts are reconciled here. The OVERALL percentage is reconciled against STATE as before, but the per-component N% figures on TOPOLOGY are not checked.
  • The 119 tests are workspace-wide and include dashboard-check's own 31. Adding a test anywhere now requires updating the dashboard count in the same PR. That is the intended ratchet.
  • PROVEN is exercised only by unit tests (fake runner), not by a real row, because the repo has none. ASSUMED/DESIGNED have no rows either.
  • Escape-hatch counting (Axiom/Admitted/sorry/believe_me/postulate) is PR C, not this one.

Verification (local, rust 1.97.1)

  • cargo fmt --all -- --check ✓; cargo clippy --workspace --all-targets --locked -- -D warnings ✓; cargo test --workspace --locked: 119 passed, 0 failed.
  • cargo run -p dashboard-check -- --check . → rc=0: ✓ 119 tests measured, 0 PROVEN claims, all 7 TESTED rows ran and passed.
  • Positive control 1: on the old docs the checker printed 6 divergences (67 vs 118, 30 vs 0 ×3, plus READINESS:11) with rc=1.
  • Positive control 2: adding one unit test made it report claims 118 but there are 119 on three lines with rc=1. It was green again after the update.
  • Fixtures (in claims.rs): lying_verifier_fails (exit 0, no output), unchecked_skip_fails (running 0 tests), inflated_counts_fail_and_true_counts_pass, wrapped_row_is_rejected, proven_row_needs_theorem_and_passing_checker, open_rows_run_nothing_and_need_a_real_artefact.
  • CI: dashboard-check run 37010504568 passed in 39 s (13:03:41Z to 13:04:20Z), well under the job's 15 min timeout. Its log shows all 7 ✓ Tested rows, both ✓ Open rows and ✓ 119 tests measured, 0 PROVEN claims.

Red checks: inherited from #144 (e6fee67), deferred, not introduced here

The red set on this head equals #144's, which equals main 539e6f9's. The ledger commit adds none.

CodeRabbit posted the status "Review rate limited" on 6f31e89 and has not reviewed this PR yet. Its review will be read before this PR is marked ready.

🤖 Generated with Claude Code

https://claude.ai/code/session_01VxcAoyMQe7CjQwCKL18Mm4

hyperpolymath and others added 3 commits October 2, 2026 13:44
…y/fmt

- e2e.yml: `toolchain: v1` is not a toolchain name (rustup: "invalid
  toolchain name: 'v1'"), so "Rust Build + Unit Tests" died before
  building. Use `stable` with clippy + rustfmt components.
- e2e.yml: drop `|| true` from the Clippy and Format steps; they could
  never fail.
- cargo fmt over attestation.rs / keys_cli.rs (rust-ci's first red step).
- Clear every `clippy --all-targets -D warnings` lint (each target's
  errors masked the next): rand 0.9 thread_rng -> rng, needless mut /
  borrow / parens, &PathBuf -> &Path, dead `root_path` field, dead store
  in the transactions bench.
- jk-keys imported `attestation` and `keys` via `mod`, compiling a second
  private copy of each: the lib's public API read as dead code there and
  10 unit tests ran twice. Import them from the lib crate instead. Unique
  test count is unchanged (107; was 117 listed with the 10 duplicates).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VxcAoyMQe7CjQwCKL18Mm4
….adoc

- dtolnay/rust-toolchain@v1 needs a `toolchain` input; the Criterion,
  E2E Lifecycle and Panic Attack jobs had none ("'toolchain' is a required
  input"). Set `stable`.
- tests/aspect: SECURITY/ARCHITECTURE/PROOF-NEEDS/TOPOLOGY were migrated
  to .adoc, so the .md-only existence checks failed 4/29. Accept either,
  as README already did. Negative control: removing TOPOLOGY.adoc makes
  the check FAIL.
- attestation: propagate HMAC new_from_slice's error instead of expect()
  (Hypatia expect_in_hot_path; the fn already returns io::Result).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VxcAoyMQe7CjQwCKL18Mm4
… counts

ULTRAPLAN P1-0, first of three stacked PRs.

PROOF-NEEDS.adoc gains a `=== Claims ledger` table, one row per line:
claim | status | artefact | command, status one of PROVEN / TESTED /
ASSUMED / DESIGNED / OPEN. dashboard-check now:

- rejects a wrapped row, an unknown status, a missing table, naming the line;
- for TESTED rows, requires the artefact file to name the test, the command
  to exit 0, and an output line showing that test passing, so `true` or a
  filter that runs 0 tests fails;
- for PROVEN rows, requires the theorem name and a passing checker command;
- for ASSUMED / DESIGNED / OPEN, requires command `-` and an existing file
  or #N artefact;
- measures tests with `cargo test --workspace --locked -- --list` and fails
  when README / EXPLAINME / TOPOLOGY / READINESS print a different test
  count, or a proof count different from the number of PROVEN rows.

The ledger has 7 TESTED rows and 2 OPEN rows (#145); 0 PROVEN, because
the Idris2 ABI does not typecheck. The dashboards claimed 67 tests and
30 proofs; they now say 119 tests and 0 checked proofs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VxcAoyMQe7CjQwCKL18Mm4
@coderabbitai

coderabbitai Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 38 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Advanced

Run ID: fe57e99c-a34e-45cd-b7e3-ea3dc4a90b11

📥 Commits

Reviewing files that changed from the base of the PR and between 539e6f9 and 274883a.

📒 Files selected for processing (22)
  • .github/workflows/e2e.yml
  • PROOF-NEEDS.adoc
  • READINESS.adoc
  • TOPOLOGY.adoc
  • benches/januskey_benchmarks.rs
  • crates/dashboard-check/src/claims.rs
  • crates/dashboard-check/src/main.rs
  • crates/januskey-cli/src/attestation.rs
  • crates/januskey-cli/src/keys.rs
  • crates/januskey-cli/src/keys_cli.rs
  • crates/januskey-cli/src/lib.rs
  • crates/januskey-cli/src/main.rs
  • crates/januskey-cli/src/obliteration.rs
  • crates/januskey-cli/src/operations.rs
  • crates/januskey-cli/tests/aspect_test.rs
  • crates/januskey-cli/tests/concurrency_test.rs
  • crates/januskey-cli/tests/e2e_test.rs
  • crates/januskey-cli/tests/p2p_test.rs
  • crates/reversible-core/src/manifest.rs
  • crates/reversible-core/src/metadata.rs
  • crates/reversible-core/src/transaction.rs
  • tests/aspect/cross_cutting_test.sh
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

`cargo test -- --list` counts declared tests; an #[ignore] would keep
the count while "pass" became false. rust-ci is what runs them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VxcAoyMQe7CjQwCKL18Mm4
@hyperpolymath
hyperpolymath marked this pull request as ready for review October 2, 2026 13:16
@hyperpolymath
hyperpolymath merged commit 17902b0 into main Oct 2, 2026
36 of 44 checks passed
@hyperpolymath
hyperpolymath deleted the feat/claims-ledger branch October 2, 2026 13:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant