test: add E2E structural validation and CI workflow for typed-wasm#7
Merged
Conversation
… config Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
hyperpolymath
added a commit
that referenced
this pull request
May 19, 2026
…, SPDX-only) (#36) Not a relicence; owner-sanctioned carve-out. A8(1). Refs LICENCE-DEBT-LEDGER-2026-05-18. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
4 tasks
hyperpolymath
added a commit
that referenced
this pull request
Jun 3, 2026
…t (refs #126 — source-line resolution defers to #129) (#159) ## Summary Closes the prose-readability slice of #126: reword all `#[error(...)]` templates and replace `tw-verify`'s `{:?}` debug-dump with a grouped, location-anchored bulleted list. ## Changes **lib.rs — error message rewording (Display-only; no API breaks)** Pattern: `L<n> (<aspect>): <subject is X but should be Y>`. | Variant | Old (excerpt) | New (excerpt) | |---|---|---| | `LinearUsedMultiple` | "Level 10 violation: function 0, param 0 — Linear (own) param loaded 5 times on some path" | "L10 (linearity): function #0 parameter #0 is a Linear (own) resource but is used 5 times on some control-flow path; Linear resources must be consumed exactly once (possible duplication)" | | `ExclBorrowAliased` | "Level 7 violation: function 0, param 0 — ExclBorrow (mut) param aliased (2 simultaneous references)" | "L7 (aliasing): function #0 parameter #0 is an ExclBorrow (&mut) reference but 2 simultaneous borrows occur on some control-flow path; at most one is permitted" | | `ModuleNotIsolated` | "Level 13 violation: {reason}" | "L13 (module isolation): {reason}" | | `LinearImportCalledMultiple` | "Level 10 boundary violation: caller fn 7 calls import 'consume' 2 time(s)…" | "L10 (linearity, cross-module): caller function #7 calls Linear import 'consume' 2 times on some control-flow path; Linear imports must be called at most once on every path" | | `MissingDependentRegions` | "Level 2 violation: typedwasm.access-sites section emitted without companion typedwasm.regions section (MissingDependentCarrier)" | "L2 (region binding): typedwasm.access-sites section is present but the companion typedwasm.regions section is missing — access-site (region, field) keys have nothing to resolve against" | Same treatment for `LinearNotUsed`, `LinearDroppedOnSomePath`, `LinearImportDroppedOnSomePath`, `CapabilitiesError::*`, `AccessSiteError::*`. **VerifyError Vec-wrappers**: replaced raw `{:?}` debug with a `display_first_then_ellipsis` helper that renders as `"3 L7/L10/L13 ownership violation(s) — <first error's full Display>; … and 2 more"`. **bin/tw-verify.rs — grouped output** Replaces the previous flat `{:?}` / `{e}` printouts with grouping: - `OwnershipError`s are bucketed by `func_idx` (with `(module-scope)` bucket for L13). Per bucket, errors are sorted by `param_idx` and printed as ` - <message>`. - `CrossError`s are bucketed by `caller_func_idx`. - L2 / L15 errors get an explicit `FAIL <pass> ({n} violation(s))` header + bulleted list. Sample output (before / after) — see commit message for details. ## Out of scope Source-line resolution ("at `.twasm` line N") **defers to #129** (source maps). The verifier still has only wasm-level indices today; the `#0` parameter / `#N` function notation makes that boundary explicit in the prose. ## Test plan - [x] `cargo test -p typed-wasm-verify` — 65 lib tests pass (62 baseline + 3 new Display tests) - [x] `cargo test -p typed-wasm-verify --all-features` — 80 lib + 10 cross-compat + 5 cross-compat-real all green - [x] `cargo clippy -p typed-wasm-verify --all-features --tests` — no new warnings (the pre-existing `collapsible-match` at `verify.rs:323` remains; not mine) - [x] No test compared raw error strings (all use `matches!` on variants), so rewording is backwards-compatible for the test suite Refs #126. Source-line resolution defers to #129. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
hyperpolymath
added a commit
that referenced
this pull request
Jun 16, 2026
…template residue Safe-auto items from the repo tidy-up audit (#7): - docs/proof-debt.md + docs/wiki/Proof-Debt-Status.md: "22/22 modules" / "22 Idris2 modules" → 24 (verified: find src/abi -name '*.idr' | wc -l = 24; AFFIRMATION.adoc already records 24 — these were the laggards). - .github/CODEOWNERS: remove the dead "Replace hyperpolymath with..." scaffold comment (the substantive owner rules below it are correct). Purely factual / dead-comment edits; no renames, dates, or licence/owner lines touched. Larger findings are owner-gated and listed separately. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
tests/e2e.sh— 53-check structural E2E validation script covering: all 12 type-safety levels documented in LEVEL-STATUS.md, spec documents (grammar + level spec), all Idris2 ABI.idrfiles (L1-L12), Zig FFI files, ReScript parser files, configuration files (ipkg, selur-compose.toml, deno.lock), RSR required files, SPDX headers, and Node.js smoke test invocation.github/workflows/e2e.yml— three-job CI workflow: fast structural check, Node.js smoke test, and full Idris2 + Zig build-then-E2ETest plan
E2E_BUILD=0 bash tests/e2e.shpasses locally (53 passed, 0 failed)node tests/e2e/e2e-smoke.mjspasses locallystructuralCI job passessmokeCI job passesbuild-e2eCI job succeeds with Idris2 + Zig🤖 Generated with Claude Code