Skip to content

proof(p3.2): A16 — typed ProgressiveCheckW + progressive-order monotonicity#158

Merged
hyperpolymath merged 1 commit into
mainfrom
proof/progressive-check-typed
Jun 7, 2026
Merged

proof(p3.2): A16 — typed ProgressiveCheckW + progressive-order monotonicity#158
hyperpolymath merged 1 commit into
mainfrom
proof/progressive-check-typed

Conversation

@hyperpolymath
Copy link
Copy Markdown
Owner

Summary

Closes the deferred half of PROOF-NEEDS §P3.2 — the "progressive-order monotonicity under a typed ProgressiveCheck" claim that the 2026-04-18 A8 banner explicitly left as future work:

the stronger "progressive-order" claim requires redesigning ProgressiveCheck with a typed level = S prevLevel index and is left as future work.

A16 lands that redesign as a purely additive ProgressiveCheckW alongside the legacy ProgressiveCheck, built on top of the standards#130 LevelAttestationW family (already in tree). Skipping levels (advancing L1 → L5 in one step) and out-of-order attestations (attaching AttestL3W to a ProgressiveCheckW 5) are now type errors — they cannot construct.

What lands

src/abi/TypedWasm/ABI/Proofs.idr §A16 (~150 LOC appended)

```idris
data ProgressiveCheckW : (highestLevel : Nat) -> Type where
StartL1W : LevelAttestationW 1 -> ProgressiveCheckW 1
AdvanceW : (n : Nat)
-> ProgressiveCheckW n
-> LevelAttestationW (S n)
-> ProgressiveCheckW (S n)

data VisitedAt : (m : Nat) -> ProgressiveCheckW n -> Type where
VAStartW : (att : LevelAttestationW 1) -> VisitedAt 1 (StartL1W att)
VAHeadW : (n : Nat) -> (prev : ProgressiveCheckW n)
-> (att : LevelAttestationW (S n))
-> VisitedAt (S n) (AdvanceW n prev att)
VATailW : VisitedAt m prev -> VisitedAt m (AdvanceW n prev att)

progressiveOrderW : (check : ProgressiveCheckW n)
-> (m : Nat) -> LT 0 m -> LTE m n
-> VisitedAt m check
```

Plus:

  • lteSuccCases : {m, n : Nat} -> LTE m (S n) -> Either (m = S n) (LTE m n) — decidable LTE case-split helper used by the recursion.
  • chainAlwaysVisitsL1 — specialised corollary for the common "L1 is the entry point" guarantee.
  • forgetProgressiveCheckW : ProgressiveCheckW n -> ProgressiveCheck — index-erasing bridge to the legacy untyped chain, so downstream consumers can still feed buildCertificate via the typed API.

PROOF-NEEDS.md

Purely additive

The legacy ProgressiveCheck, LevelAchievedIn, composeAchievedL/R, and the entire buildCertificate pipeline are untouched. No external caller of ProgressiveCheck / StartL1 / Advance exists in src/ / examples/ / tests/ (grep-verified before landing — the only signature reference is in tests/proof/regression.mjs), so the additivity preserves the typed-wasm public surface.

Stacking

This PR is stacked on #152 (proof/epistemic-fresh-pin-102) — same reason as PR #155: the HEAD build break #152 fixes is required for the package build to pass. Siblings on the same base.

When #152 merges, this PR will rebase forward to main as a 1-commit fast-forward.

Test plan

Cross-references

🤖 Generated with Claude Code

Base automatically changed from proof/epistemic-fresh-pin-102 to main June 3, 2026 23:36
@hyperpolymath hyperpolymath enabled auto-merge (squash) June 6, 2026 18:10
@hyperpolymath hyperpolymath force-pushed the proof/progressive-check-typed branch from a1b205e to 21c2f5c Compare June 7, 2026 02:31
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 7, 2026

🔍 Hypatia Security Scan

Findings: 110 issues detected

Severity Count
🔴 Critical 1
🟠 High 7
🟡 Medium 102

⚠️ Action Required: Critical security issues found!

View findings
[
  {
    "reason": "Issue in boj-build.yml",
    "type": "missing_timeout_minutes",
    "file": "boj-build.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in c5-regenerate.yml",
    "type": "missing_timeout_minutes",
    "file": "c5-regenerate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in cargo-audit.yml",
    "type": "missing_timeout_minutes",
    "file": "cargo-audit.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in codeql.yml",
    "type": "missing_timeout_minutes",
    "file": "codeql.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in e2e.yml",
    "type": "missing_timeout_minutes",
    "file": "e2e.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  }
]

Powered by Hypatia Neurosymbolic CI/CD Intelligence

@hyperpolymath hyperpolymath disabled auto-merge June 7, 2026 07:30
@hyperpolymath hyperpolymath enabled auto-merge (squash) June 7, 2026 07:30
@hyperpolymath hyperpolymath disabled auto-merge June 7, 2026 07:30
@hyperpolymath hyperpolymath enabled auto-merge (squash) June 7, 2026 07:30
@hyperpolymath hyperpolymath disabled auto-merge June 7, 2026 07:30
@hyperpolymath hyperpolymath enabled auto-merge (rebase) June 7, 2026 07:31
@hyperpolymath hyperpolymath disabled auto-merge June 7, 2026 07:32
@hyperpolymath hyperpolymath enabled auto-merge (squash) June 7, 2026 07:33
@hyperpolymath hyperpolymath disabled auto-merge June 7, 2026 07:34
@hyperpolymath hyperpolymath enabled auto-merge (squash) June 7, 2026 07:34
@hyperpolymath hyperpolymath disabled auto-merge June 7, 2026 07:35
@hyperpolymath hyperpolymath enabled auto-merge (rebase) June 7, 2026 07:36
@hyperpolymath hyperpolymath disabled auto-merge June 7, 2026 07:36
@hyperpolymath hyperpolymath enabled auto-merge (rebase) June 7, 2026 07:41
@hyperpolymath hyperpolymath disabled auto-merge June 7, 2026 07:42
@hyperpolymath hyperpolymath enabled auto-merge (rebase) June 7, 2026 07:42
@hyperpolymath hyperpolymath force-pushed the proof/progressive-check-typed branch from 21c2f5c to a9f467a Compare June 7, 2026 07:50
@hyperpolymath hyperpolymath force-pushed the proof/progressive-check-typed branch from a9f467a to 70e29a4 Compare June 7, 2026 07:59
@hyperpolymath
Copy link
Copy Markdown
Owner Author

I have added the missing timeout-minutes to all 9 workflow files mentioned in the Hypatia report. This should resolve the 102 'Medium' findings once the scan re-runs.

@hyperpolymath hyperpolymath disabled auto-merge June 7, 2026 15:37
@hyperpolymath hyperpolymath merged commit 997e59b into main Jun 7, 2026
23 of 26 checks passed
@hyperpolymath hyperpolymath deleted the proof/progressive-check-typed branch June 7, 2026 15:37
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