Repository navigation
impl(027): increment 5, the WebAssembly package - #130
Conversation
973f512 to
d3ddd6f
Compare
090ae0c to
12dfcd0
Compare
AI review (findings)Group 1 of 2Reviewing the group 1 files for bugs, security problems, and inconsistencies.
The acceptability check for the JS callback's return value is: Ok(a) if (a.length() as usize) <= max_bytes.saturating_add(1) => {
Resolution::Bytes(a.to_vec())
}The doc comment directly above the struct says: "a throw, a non-byte value or an oversized answer is inaccessible, as for the CLI's store." But the condition admits arrays of size
The check was extended to also reject labels present in if self.outputs.borrow().contains_key(label) || self.inputs.contains_key(label) {
return Err(IoFail { ..., detail: "already exists; outputs are never overwritten".into() });
}When the label is found in
The deleted in-test No issues found in the conformance JSON case updates, Cargo manifests, TypeScript declarations, or the {"head": "12dfcd01d233455853fe2f963315af7fcc67e2a7", "verdict": "findings", "findings": [{"path": "integrations/rustev-wasm/src/lib.rs", "line": 211, "summary": "Callback::resolve accepts arrays up to max_bytes+1 as Resolution::Bytes, contradicting the doc comment that says oversized answers are inaccessible; condition should be <= max_bytes."}, {"path": "crates/rustev-surface/src/host.rs", "line": 107, "summary": "ensure_absent error detail says 'outputs are never overwritten' but the guard now also fires when the label matches an input, making the message factually wrong in that branch."}]}Group 2 of 2Reviewing group 2: manifest/case JSON updates, new descriptor fixtures, updated replay bundles, new JS tooling ( Manifest/case JSON (
Descriptor fixtures:
No bugs, security issues, or meaningful inconsistencies found. {"head": "12dfcd01d233455853fe2f963315af7fcc67e2a7", "verdict": "no-findings", "findings": []}Subject: d3ddd6f...12dfcd0, diff digest 4d866bd52791f3d4ccbb0431574f63bf19b68e9d488372608abad24c2dffa1af, 2 call(s). An AI comment is not an approval. |
d3ddd6f to
4970460
Compare
12dfcd0 to
cfc621e
Compare
4970460 to
ff4477d
Compare
cfc621e to
c77d571
Compare
AI review (findings)Group 1 of 2Reviewing the group 1 changed files for bugs, security problems, and inconsistencies.
CARGO_TARGET := $(shell cargo metadata --format-version 1 --no-deps 2>/dev/null | sed -n 's/.*"target_directory":"\([^"]*\)".*/\1/p')
BINDINGS_OUT := $(CARGO_TARGET)/bindingsIf
A safe fix is a fallback:
Everything else looks correct and consistent with the spec: the {"head": "c77d57143f147612455fab8f1b6a0f2ef95c639e", "verdict": "findings", "findings": [{"path": "Makefile", "line": 94, "summary": "CARGO_TARGET is derived via sed on cargo metadata with stderr suppressed; if the shell command produces nothing, BINDINGS_OUT becomes /bindings, causing rm -rf /bindings/rustev-wasm and writes to /wasm-measurement.json on subsequent targets."}, {"path": "crates/rustev-surface/src/host.rs", "line": 74, "summary": "outputs is pub RefCell on a pub struct, so a caller that borrows outputs directly while also calling create() or write_all() will trigger a runtime RefCell borrow panic; the field should be private."}]}Group 2 of 2Reviewing the diff for group 2, focused on the new JS tooling and fixture changes. Finding:
default:
throw new Error(`${c.id}: the WebAssembly surface has no command ${a.command}`);Six cases now list
Everything else looks consistent: the {"head": "c77d57143f147612455fab8f1b6a0f2ef95c639e", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/run.mjs", "line": 106, "summary": "runWasm has no case for the 'run' command, so the six wasm-surface cases that use command:run throw an uncaught error and crash the conformance runner instead of recording failures."}]}Subject: ff4477d...c77d571, diff digest 65c95d5dd1a60177e8b4728de0595852b81a1d8cd855e734dffc3bb80785200a, 2 call(s). An AI comment is not an approval. |
ff4477d to
1ad8617
Compare
c77d571 to
45f834b
Compare
1ad8617 to
d5bd2a0
Compare
45f834b to
c2a7e85
Compare
d5bd2a0 to
88a7b22
Compare
c2a7e85 to
9e68054
Compare
AI review (findings)Group 1 of 2
{"head": "9e68054e12cf506af7138263a4c3bfeec922fb4d", "verdict": "findings", "findings": [{"path": "integrations/rustev-wasm/package.json", "line": 5, "summary": "\"private\": true prevents npm publish, contradicting the spec's stated delivery mechanism of shipping the module only through npm."}, {"path": "crates/rustev-surface/src/host.rs", "line": 121, "summary": "join() now returns just `name` when dir is empty, silently changing behaviour from the replaced test-only Memory which always produced \"{dir}/{name}\"; the change is likely correct but is untested and diverges from the prior contract."}]}Group 2 of 2Reviewing this group (conformance JS tooling, fixture descriptor files, bundle updates, manifest additions, Rust lib.rs change). Finding 1 —
Finding 2 —
No other significant issues: the import-allowlist check in {"head": "9e68054e12cf506af7138263a4c3bfeec922fb4d", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/package-lock.json", "line": null, "summary": "lodash is resolved at version 4.18.1, which has never been published to npm (4.x peaked at 4.17.21 with no releases since 2021), indicating a fabricated or private-registry lockfile entry that cannot install from the public registry."}, {"path": "tools/rustev-conformance/js/run.mjs", "line": 112, "summary": "runWasm() calls glue.check/compile/show/replay with no try/catch, so any exception thrown by the WebAssembly module crashes the entire conformance runner rather than recording the case as failed and continuing."}]}Subject: 88a7b22...9e68054, diff digest 6ca2043067d183750a329be9793169c1492c164b79f45da2ccfdc48bf5656e36, 2 call(s). An AI comment is not an approval. |
9e68054 to
d7996f4
Compare
88a7b22 to
ff6d015
Compare
d7996f4 to
cf86dd0
Compare
ff6d015 to
76ad8ab
Compare
cf86dd0 to
df762d0
Compare
AI review (findings)Group 1 of 2Reviewing the diff for the WebAssembly binding increment (spec 027-5). Overall: The implementation is structurally sound. The Specific findings: harvest.rs, line ~220: host.rs, lib.rs, No security vulnerabilities found. The {"head": "df762d09f564d24e0cb1e9f379268b4da9c9ae9f", "verdict": "findings", "findings": [{"path": "crates/rustev-cli/tests/common/harvest.rs", "line": 220, "summary": "Unconditional unwrap on Document::canonical(b.descriptor()) during harvest mode will panic instead of skipping if canonicalization fails for any loaded rules backend."}, {"path": "crates/rustev-surface/src/host.rs", "line": 72, "summary": "Memory.inputs is pub, allowing callers to mutate the inputs map after ensure_absent has already checked it, which could silently alter what a subsequent create call observes in the same Memory instance."}]}Group 2 of 2Reviewing the changes in group 2. The bulk of the diff is mechanical: new Finding 1 – Nonexistent
Finding 2 – In if (r === null) {
failures.push(`${c.id}: the WebAssembly surface has no command ${flags(c.argv).command}`);The code comment even says "the harvest never names {"head": "df762d09f564d24e0cb1e9f379268b4da9c9ae9f", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/package-lock.json", "line": null, "summary": "Pins [email protected], a version that does not exist in the npm registry (latest 4.x is 4.17.21), creating a supply-chain risk if that slot is ever claimed."}, {"path": "tools/rustev-conformance/cases/cli/support.run.json", "line": null, "summary": "Adds 'wasm' to the surfaces of a 'run' command case; the WASM conformance runner has no 'run' command and will unconditionally report this case as a failure."}]}Subject: 76ad8ab...df762d0, diff digest 6605d9691b4c7e963a9c7989f54baa8d7398481d8ef8b898922177b2d4ba3321, 2 call(s). An AI comment is not an approval. |
76ad8ab to
7c30621
Compare
bc678f4 to
6054b28
Compare
847339d to
86bf20d
Compare
c7999ec to
116fbd7
Compare
86bf20d to
04eed4d
Compare
AI review (findings)Group 1 of 2Looking at the changed code in group 1:
@$(WASM_OPT) --version | grep -q "^$(WASM_OPT_PIN)" || ...
WASM_OPT_PIN := wasm-opt version 116
The file-system host fails on a conflicting path with an OS error; the new
Inside
The spec text explicitly states the raw-size gate (
&JsValue::from_f64(max_bytes as f64),For {"head": "04eed4d46ef09689a539f72307ff0580dcd658f2", "verdict": "findings", "findings": [{"path": "Makefile", "line": 108, "summary": "wasm-opt version pin uses prefix matching (grep '^wasm-opt version 116') instead of an exact check, so a future binary reporting e.g. 'wasm-opt version 1160' would silently satisfy the pin."}, {"path": "crates/rustev-surface/src/host.rs", "line": 104, "summary": "Memory::ensure_absent rejects labels that name an input, which is not part of the Host trait contract and diverges silently from the file-system host; callers written against the file host will see unexpected IoFail."}, {"path": "specs/027-node-and-wasm-bindings/spec.md", "line": 892, "summary": "The spec documents that make bindings will always fail the raw-size gate (module is 5.6% over budget), meaning any CI job running that target cannot pass until spec 046 is ratified."}]}Group 2 of 2Reviewing the JS tooling, manifest updates, fixture files, and Rust struct additions.
if (!allowed.modules.includes(i.module) || !allowed.names.includes(base))An import from an allowed module with a name that happens to appear in the names list (even if that pairing was never reviewed) would pass silently. The allowlist intent is to gate specific Everything else looks consistent: the {"head": "04eed4d46ef09689a539f72307ff0580dcd658f2", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/run.mjs", "line": 89, "summary": "Accessing `o.normalize.length` throws TypeError when the `normalize` field is absent from a manifest output object; should guard with `(o.normalize ?? []).length`."},{"path": "tools/rustev-conformance/js/wasm-check.mjs", "line": 66, "summary": "Import allowlist check validates module and name independently rather than as (module, name) pairs, so an unanticipated import combining two individually-allowed values would not be caught."}]}Subject: 116fbd7...04eed4d, diff digest 960a1aaf8bfb83f7c054456fcc51c834b9f7c3ed612fc033848761641ada55e6, 2 call(s). An AI comment is not an approval. |
116fbd7 to
a7f99df
Compare
04eed4d to
2a8eeeb
Compare
AI review (no-findings)Group 1 of 2Reviewing the diff group 1 carefully across all files.
The production } else if self.inputs.contains_key(label) {
"names an input; an output never replaces one"This is new behavior vs. the deleted test-local version (which only checked outputs). The
Old (deleted) test-local version produced
The
Ok(a) if (a.length() as usize) <= max_bytes.saturating_add(1) => {
assert!(
Path::new(name)
.components()
.all(|c| matches!(c, std::path::Component::Normal(_))),
"--rules {name:?} is not a plain relative path"
);Correctly prevents
Both the Spec 027 — documented size budget exceedance The raw WASM budget of 2,097,152 bytes is acknowledged to be exceeded by ~5.6%, Conformance case SHA256 updates The No bugs, security issues, or material inconsistencies found. {"head": "2a8eeeb1fe1cb8ab9936454ee78e1152d040312d", "verdict": "no-findings", "findings": []}Group 2 of 2The diff adds WebAssembly surface support to the conformance harness: new descriptor fixtures, updated bundle fixtures (timing-only changes), a JS conformance runner, a WASM check tool, and a type generator. Below are my observations.
Manifest changes —
No bugs, security problems, or meaningful inconsistencies found. {"head": "2a8eeeb1fe1cb8ab9936454ee78e1152d040312d", "verdict": "no-findings", "findings": []}Subject: a7f99df...2a8eeeb, diff digest 666d03e84d011e206abdaf1df91731844df9f2eed762b1aed2aa66b7b57c5b00, 2 call(s). An AI comment is not an approval. |
a7f99df to
b22983d
Compare
2a8eeeb to
4712dee
Compare
AI review (findings)Group 1 of 2Reviewing the diff for bugs, security problems, and inconsistencies. Findings
The
&JsValue::from_f64(max_bytes as f64),
assert!(
Path::new(name)
.components()
.all(|c| matches!(c, std::path::Component::Normal(_))),
"--rules {name:?} is not a plain relative path"
);
The new {"head": "4712dee31863fd4d8f0dc4c2bc71ec00753ea83f", "verdict": "findings", "findings": [{"path": "Makefile", "line": 93, "summary": "CARGO_TARGET is evaluated before the Node version check, so a missing Node installation produces the misleading error 'cargo metadata named no target directory' rather than the clear 'need Node 20 or later' message."}, {"path": "integrations/rustev-wasm/src/lib.rs", "line": 205, "summary": "max_bytes as f64 loses precision for values above 2^53-1, potentially allowing an oversized document to pass the length guard in Callback::resolve."}, {"path": "crates/rustev-cli/tests/common/harvest.rs", "line": 215, "summary": "Using assert! for the path-traversal check panics the entire test binary rather than failing just the offending case, leaving partial harvest state on disk."}]}Group 2 of 2Looking at the diff, the changes add WebAssembly surface support to the conformance harness: new descriptor fixtures, updated bundle files, JS tooling (
"node_modules/lodash": {
"version": "4.18.1",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.18.1.tgz",
"integrity": "sha512-dMInicTPVE8d1e5otfwmmjlxkZoUpiVLwyeTdUsi/Caj/gfzzblBcCE5sRHV/AsjuCmxWrte2TNGSYuCeCq+0Q=="The 4.x series of lodash has been at No other bugs or security issues found. The {"head": "4712dee31863fd4d8f0dc4c2bc71ec00753ea83f", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/package-lock.json", "line": 69, "summary": "lodash is locked at 4.18.1, a version beyond the known stable 4.17.21; verify the integrity hash against the npm registry before merging to rule out a fabricated or substituted entry."}]}Subject: b22983d...4712dee, diff digest d5ebacebcf56bbe8b7cb9ab0ae5e7c3ca93091dc98ad1951e661097e72acb3c0, 2 call(s). An AI comment is not an approval. |
4712dee to
7ca58d5
Compare
b22983d to
ed80241
Compare
AI review (findings)Group 1 of 2Reviewing the diff, which introduces the WebAssembly integration (
The
The
Conformance cases Bundle sha256s changed for Spec note (acknowledged, not a code bug) The spec explicitly documents that the 2 MiB raw WASM size budget is exceeded (~5.6%) and that No bugs or security issues found. {"head": "a9bd08168caa9191dd847deb66874fdbf088de24", "verdict": "no-findings", "findings": []}Group 2 of 2Reviewing the changed files in group 2.
The per-case try/catch (lines ~134–137) only wraps const golden = pinned(o.golden, o.sha256); // can throw
if (!Buffer.from(r.out).equals(golden)) { // can throw if r.out is absent
failures.push(`... got ${Buffer.from(r.out)...}`);
}
Everything else looks consistent:
{"head": "a9bd08168caa9191dd847deb66874fdbf088de24", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/run.mjs", "line": 150, "summary": "The output-verification loop (pinned() and Buffer.from(r.out)) runs outside the per-case try/catch, so any thrown exception aborts the entire conformance run rather than recording a single-case failure."}]}Subject: 8ad51a0...a9bd081, diff digest cef37fff368db25409eb7da966152fa889b710ce7de286e3ce23c25ef694ec99, 2 call(s). An AI comment is not an approval. |
AI review (findings)Group 1 of 2Reviewing the diff for the WebAssembly package implementation (spec 027, increment 5).
The
Conformance cases
No bugs, security issues, or inconsistencies found. {"head": "64388f5b46be2fa8a0192d7c84cc396bc3cca0a5", "verdict": "no-findings", "findings": []}Group 2 of 2Reviewing the group 2 files: manifest updates, new fixture descriptors, updated bundle fixtures, new JS tooling, and conformance lib additions.
Descriptor JSON files — All 22 new Bundle files — The changes are minor timing adjustments (a few
{"head": "64388f5b46be2fa8a0192d7c84cc396bc3cca0a5", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/run.mjs", "line": 104, "summary": "Number(a.one('now-ms')) silently produces NaN when --now-ms is absent from a replay case's argv, passing an invalid timestamp to glue.replay() instead of failing explicitly."}]}Subject: 752fd43...64388f5, diff digest 3da3ea146f28ac5b9a99a25b156941015a5157eedc98bbbc1bb27f388993d347, 2 call(s). An AI comment is not an approval. |
AI review (findings)Group 1 of 2Reviewing the diff for bugs, security problems, and inconsistencies.
The
Path validation
Version pin regex Conformance case JSON files Cases with no No bugs, security issues, or inconsistencies found. {"head": "886c1a6d7ae427d09c10426697eea8dba31b608e", "verdict": "no-findings", "findings": []}Group 2 of 2Reviewing the group 2 changes: manifest additions, new descriptor fixtures, updated bundles, new JavaScript tooling, and the release-set exclusion.
The descriptor fixture files, the manifest SHA-256 updates for the two bundles, the Rust {"head": "886c1a6d7ae427d09c10426697eea8dba31b608e", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/package-lock.json", "line": null, "summary": "Pins [email protected], a version that has never been published to npm (latest 4.x is 4.17.21), making npm ci fail and the JS tooling uninstallable."}, {"path": "tools/rustev-conformance/js/run.mjs", "line": 162, "summary": "runCase increments `ran` before checking for a null return, so a case whose command the WASM surface does not support both inflates the run count and records a spurious failure instead of being silently skipped."}, {"path": "tools/rustev-conformance/js/wasm-check.mjs", "line": 63, "summary": "The import allowlist checks module names and base names independently rather than as pairs, so any novel import whose module and base name each appear separately on the list passes without being reviewed as a pair."}]}Subject: f054fda...886c1a6, diff digest 403b590815365aa4280d934e8cedf9998f249e871b743fbcecabb59129f84f39, 2 call(s). An AI comment is not an approval. |
AI review (findings)Group 1 of 2Review
|
AI review (no-findings)Group 1 of 2Reviewing the PR, which implements the WebAssembly surface (Increment 5 of spec 027).
The The
The path-traversal guard on assert!(
Path::new(name).components()
.all(|c| matches!(c, std::path::Component::Normal(_))),
"--rules {name:?} is not a plain relative path"
);correctly prevents
The
The lazy Conformance case JSON files
Known exceeded budget The spec update explicitly documents the raw WASM size exceeding the declared budget by 5.6%, with No bugs or security issues found. {"head": "89a6ffdfbba9cd2541c36ac2916b926c1d7ce7be", "verdict": "no-findings", "findings": []}Group 2 of 2Reviewing the PR: new WASM conformance tooling (spec 027), fixture updates, and manifest/struct additions. I'll check for bugs, security issues, and cross-file inconsistencies.
The core WASM conformance runner looks sound:
Manifest / fixtures
No bugs, security issues, or inconsistencies found. {"head": "89a6ffdfbba9cd2541c36ac2916b926c1d7ce7be", "verdict": "no-findings", "findings": []}Subject: 707f974...89a6ffd, diff digest 8e52635cb749f9a5b84df114d5fb005ce6d445392b1611af2f4013d63d886307, 2 call(s). An AI comment is not an approval. |
AI review (findings)Group 1 of 2Reviewing the diff carefully across the changed files in group 1.
Conformance case JSON files:
No bugs, security issues, or inconsistencies found. {"head": "4159d3c75b8155178eb364c9e7f97c8d2f97bc41", "verdict": "no-findings", "findings": []}Group 2 of 2Reviewing the JS tooling, updated fixtures, and manifest changes for the WASM conformance surface.
The conformance runner is sound. One design note confirmed correct: the manifest only adds
Import-allowlist enforcement is straightforward. The stripping regex (
The
Manifest and descriptor fixtures Descriptor files are byte-identical across all cases sharing the same rules backend ( {"head": "4159d3c75b8155178eb364c9e7f97c8d2f97bc41", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/package-lock.json", "line": null, "summary": "Lodash 4.18.1 is declared as a resolved dependency but was not a published npm version as of the knowledge cutoff (Aug 2025); verify the package exists and the integrity hash matches before merging."}]}Subject: 5764d8b...4159d3c, diff digest 8e52635cb749f9a5b84df114d5fb005ce6d445392b1611af2f4013d63d886307, 2 call(s). An AI comment is not an approval. |
AI review (findings)Group 1 of 2Reviewing the diff for bugs, security issues, and inconsistencies.
The new
The all-or-none rollback in
The range check
The
$(WASM_OPT) -Oz $(WASM_FEATURES) -o $(BINDINGS_OUT)/…/rustev_wasm_bg.wasm $(BINDINGS_OUT)/…/rustev_wasm_bg.wasmThe input and output paths are identical (in-place optimization). Modern Conformance case consistency The No actionable bugs or security issues found. {"head": "fcaa1e45f7694b15d919b7a1fed639b1022105df", "verdict": "no-findings", "findings": []}Group 2 of 2Reviewing the group 2 files: the manifest, new fixture descriptor files, updated bundles, the JS tooling (gen-types, run, wasm-check), the conformance Rust struct extension, and the release-set exclusion.
Everything else looks correct:
{"head": "fcaa1e45f7694b15d919b7a1fed639b1022105df", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/package-lock.json", "line": 146, "summary": "[email protected] is a newly-published version (2026-04-01) not in prior registry history; the package.json comment provides a provenance note, but the lockfile integrity hash should be independently verified against `npm view [email protected] dist.integrity` before merge to rule out supply-chain substitution."}]}Subject: 5764d8b...fcaa1e4, diff digest 070aebc620b039fef2a3d8a88133dd993cd31983cc8d01a6a8c3d75867b749aa, 2 call(s). An AI comment is not an approval. |
AI review (findings)Group 1 of 2Reviewing the diff for bugs, security issues, and inconsistencies across all group-1 files.
Conformance case JSON files:
{"head": "e437191aec171928c97f977e867a0bfcda5ef8d0", "verdict": "findings", "findings": [{"path": "Makefile", "line": null, "summary": "The `bindings` target expands `$(BINDINGS_OUT)` and `$(CARGO_TARGET)` unquoted in shell commands inside the `for` loop; a space in the Cargo target directory (e.g. from CARGO_TARGET_DIR) would silently misparse paths and corrupt the build artifacts."}, {"path": "specs/027-node-and-wasm-bindings/spec.md", "line": null, "summary": "Spec prose references \"lodging 4.18.1\" but no lodash release with that version exists on npm (latest 4.x is 4.17.21); if this is the actual pinned version in the lockfile, `npm ci` will fail."}]}Group 2 of 2Reviewing the group-2 files: manifest updates, descriptor fixtures, bundle updates, the new JS tooling, and the Rust
Derived SHA-256 values are internally consistent: all support-routing descriptor entries use Descriptor fixture files All 16 new Bundle files The only functional differences are timing values (
Namespace wrapping prevents name collisions between schemas. The
No bugs, security issues, or inconsistencies found. {"head": "e437191aec171928c97f977e867a0bfcda5ef8d0", "verdict": "no-findings", "findings": []}Subject: 5764d8b...e437191, diff digest 5d7297fabf8afd103b56faaa91fc7cfabc3eb9dec4d9a691ef530cd72c8ceda8, 2 call(s). An AI comment is not an approval. |
AI review (findings)Group 1 of 2Reviewing the group 1 files for bugs, security issues, and inconsistencies.
Conformance case files No bugs, security problems, or inconsistencies found. {"head": "f4ddc3b6aca27832d55423a2d5646502683c5990", "verdict": "no-findings", "findings": []}Group 2 of 2Reviewing the changed files in group 2.
The lockfile declares
The
The import normalisation Everything else in group 2 — the manifest {"head": "f4ddc3b6aca27832d55423a2d5646502683c5990", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/package-lock.json", "line": 47, "summary": "[email protected] is listed as a nested dependency but no 4.x release beyond 4.1.0 is known; an anomalous or fabricated lockfile entry is a supply-chain risk, and unlike [email protected] no verification note accompanies it."}, {"path": "tools/rustev-conformance/js/run.mjs", "line": 47, "summary": "scope() silently produces JSON with required fields (tenant, context_revision, principal_scope) omitted when their argv flags are absent, passing an invalid scope document to the WASM replay API."}, {"path": "tools/rustev-conformance/js/wasm-check.mjs", "line": 78, "summary": "The import hash-strip regex /_[0-9a-f]{16}$/ hard-codes a 16-hex-digit suffix; a future wasm-bindgen version with a different hash width will produce spurious allowlist failures for every import."}]}Subject: 5764d8b...f4ddc3b, diff digest d6b20b23cfb2ede9e57536e4da5425a1fef2477306810b51052ca501a1995679, 2 call(s). An AI comment is not an approval. |
AI review (findings)Group 1 of 2Reviewing the diff for bugs, security problems, and inconsistencies.
The production } else if self.inputs.contains_key(label) {
"names an input; an output never replaces one"This is intentional and correct, but the test file (
The harvest staleness detection asserts
The range check
Accepts arrays of length 0..= Makefile — The
No {"head": "befe66992927a547602ecb65179431b4fadb8fc9", "verdict": "findings", "findings": [{"path": "crates/rustev-surface/tests/memory_host.rs", "line": null, "summary": "The new production Memory::ensure_absent blocks writes whose label matches an input ('names an input; an output never replaces one'), but no test exercises this path — only the output-overwrite case is covered."}, {"path": "crates/rustev-cli/tests/common/harvest.rs", "line": null, "summary": "Harvest staleness detection asserts 'derived' but never validates 'surfaces'; a case file with a stale surfaces list silently passes re-harvest checks."}, {"path": "integrations/rustev-wasm/package.json", "line": null, "summary": "Missing 'type' field and no 'import'/'require' export conditions may cause module-format ambiguity for the web and bundler ESM targets in some toolchains."}]}Group 2 of 2Review group 2 of 2 Reviewing the JS tooling, fixture descriptor files, updated bundles, the manifest schema extension, and the release-set exclusion.
Bundle updates ( Everything else — Descriptor files are consistent (same artifact and backend-id as the embedded descriptors in the bundles). Manifest {"head": "befe66992927a547602ecb65179431b4fadb8fc9", "verdict": "findings", "findings": [{"path": "tools/rustev-conformance/js/package-lock.json", "line": null, "summary": "lodash is pinned at 4.18.1, a version not known to exist prior to August 2025; reviewers should run `npm audit signatures` and verify the package's provenance on the public registry before merging, as the lockfile integrity hash would only catch content tampering, not an entirely synthetic release."}]}Subject: 5764d8b...befe669, diff digest ddd460b7777284efc4589eb807ef09e85e8c44e9b5026a2d386b751446eca236, 2 call(s). An AI comment is not an approval. |
AI review (findings)Group 1 of 2Reviewing the diff for the WASM bindings increment of spec 027.
The
Version-pin checks (
The Size budget The spec itself documents (section 3.10.6) that the optimized Conformance fixtures
{"head": "a551d9dc8e318fec99f1c484371a4a4ce309cb8b", "verdict": "findings", "findings": [{"path": "Makefile", "line": 118, "summary": "make bindings fails at the raw-size gate (2,215,589 bytes > 2,097,152 byte budget) as the spec documents; any CI job invoking this target will fail until spec 046 raises the budget."}]}Group 2 of 2Reviewing the files in group 2 of this PR, which adds WebAssembly conformance infrastructure: manifest updates, new descriptor fixtures, updated bundle fixtures, JavaScript tooling, and
No bugs, security issues, or inconsistencies found. {"head": "a551d9dc8e318fec99f1c484371a4a4ce309cb8b", "verdict": "no-findings", "findings": []}Subject: 5764d8b...a551d9d, diff digest 6ca278258286b70703f0313b9f09b15157610041f55e55c24f00d4d2be234fcc, 2 call(s). An AI comment is not an approval. |
AI review (no-findings)Group 1 of 2Reviewing the changes focused on the new WASM integration, the
The old test-only
The rollback removes entries
The
The Makefile — Correctly separates vulnerability audits (
$(WASM_OPT) -Oz ... -o "...rustev_wasm_bg.wasm" "...rustev_wasm_bg.wasm"
Conformance case JSON consistency The 23 cases gaining No bugs, security issues, or inconsistencies found. {"head": "a17ad46681a3eff42ebd3ba9be83e33b4d1031de", "verdict": "no-findings", "findings": []}Group 2 of 2Reviewing the changes in group 2: the conformance manifest, new fixture descriptor files, updated bundle fixtures, and the new JavaScript tooling ( Manifest (
Fixtures: The two bundle files (
No bugs, security problems, or inconsistencies found. {"head": "a17ad46681a3eff42ebd3ba9be83e33b4d1031de", "verdict": "no-findings", "findings": []}Subject: 5764d8b...a17ad46, diff digest 654fdcb55153259df09634e69a5d81ce51e7d1b903d11406d932acdbbb2334b7, 2 call(s). An AI comment is not an approval. |
Spec 027, increment 5: the WebAssembly package. Stacked on #129.
integrations/rustev-wasm(publish = false, npm only; excluded from the crates.io release set):version,check,compile,show,replay,eval,gate,calibrateFit,calibrateQualifythroughrustev-surfacewith an in-memory host (rustev_surface::host::Memory, new, also used by the surface's tests). No runtime, backend, sink or clock; time is an argument; external items resolve through a synchronous host callback.make bindings: exact pins (wasm-bindgen-cli0.2.129 = crate,wasm-opt116),web/bundler/nodejstargets at-Oz(awasmcargo profile used only here), declaration drift check plus strict type-check, import allowlist, size and instantiation budgets with a measurement document, and the JavaScript conformance runner.rustev-documents.d.tsgenerated offline from the committed schemas byjson-schema-to-typescript16.0.0 (committed lockfile), type-checked by TypeScript 5.9.3 strict. Generated: 10k of this PR's lines.wasm-bindgenglue, each reviewed inwasm-imports.json.wasmsurface and records rules programs' derived descriptors; all 23 such cases print the CLI's golden bytes and exit codes on WebAssembly.make bindingsfails at the raw gate as 3.10.4 requires; the budget change is drafted as spec 046 for the owner. Chromium timing and the CI measurement come with thebindingsjob (increment 7).Review round 1 (2 findings): (1) the resolver passes up to
maxBytesplus one byte on purpose, so the library classes an item past its budgetoversizedexactly as for the CLI's store, which reads one byte past the maximum; the comment now says so (anything longer is inaccessible). (2) Fixed: the memory host names the case: an output that already exists, or a label that names an input. Declarations regenerated after #126's schema change (Timestamp range).Review round 2 (3 findings): (1) fixed:
make bindingsrefuses first when cargo metadata names no target directory, so no path is built from an empty prefix. (2) fixed:Memory's outputs are private, with anoutput(label)copy accessor; onlycreateandwrite_allborrow them, never across a call. (3) No case nameswasmon arun(the harvest givesruncasescliandnative;runis no WebAssembly command, 3.1.1), so none throws today; the runner now reports such a case as a failure instead of ending, and the code says why. Restacked on #129.Review round 3 (4 findings): (1)
"private": trueis deliberate until publication: spec 031 owns the npm release and makes the package publishable then, so no build of this increment can be published by accident; the spec record says so. (2) fixed: a test pinsjoin: an empty directory is the binding's top level, so the label is the name alone. (3) lodash 4.18.1 is published on the public registry (npm view [email protected] versionanswers 4.18.1) and the lockfile resolves it from registry.npmjs.org with its integrity hash. (4) fixed: a throwing module call fails its case and the runner continues.Review round 4 (4 findings): (1) fixed: a derived descriptor that does not canonicalize fails the harvest naming its program, never a silent gap. (2) fixed:
Memory's inputs are private like its outputs, read throughinputs(). (3) Repeated: lodash 4.18.1 is on the public registry (npm view [email protected] versionanswers 4.18.1); the lockfile resolves it from registry.npmjs.org with its integrity hash, so the slot is not unclaimed. (4) Noruncase nameswasm: the harvest gives a casewasmonly when its command is pure, and everyruncase's surfaces are["cli"]in this branch (nativejoins in #132). Restacked on #129.Review round 5 (6 findings): (1) Refusing an output that names an input is deliberate and matches the CLI: on a file system the input is a file at that path and the file host refuses to replace it, so every surface gives the same outcome; the code says so. (2) fixed:
CARGO_TARGETis read by parsing cargo's JSON, not by a regex. (3) fixed: the unreachable error arm is anexpectstating why (msadmits at most 2^53 - 1). (4) fixed: the harvest refuses a--rulesargument that is not a plain relative path before writing a descriptor under it. (5) fixed:wasm-check.mjsparses--chromium-ms, records the median and fails it against the 3.10.6 budget (the CI job of increment 7 supplies it). (6) Repeated and wrong: lodash 4.18.1 is published (npm view [email protected] version), andnpm ciinstalls it from the lockfile locally and in CI. Restacked on #129.Review round 6 (3 findings): (1) fixed: the message states the requirement (
must be a non-negative integer). (2) No case nameswasmon arun: every case whose command isrunlists["cli"]in this branch (checked over all case files), and the manifest aggregates them unchanged. (3) fixed: a flag without a value fails the case naming it; every flag of the harvested commands takes one value (checked over all case files).Review round 7 (1 finding, fixed):
CARGO_TARGETis evaluated lazily, once, on first use, so onlymake bindingsruns cargo metadata and node; other targets pay nothing.Review round 8 (2 findings, the same as rounds before): no
runcase nameswasm. The diff placed newderivedentries on theruncases next to thewasmsurface added to neighbouring pure cases. To leave nothing to misread, the harvest now records derived descriptors only for the cases the WebAssembly surface runs (plan check,plan compile,plan show,replay), so this PR no longer changes anyruncase: everyruncase keeps its surfaces["cli"]and gains nothing. wasm 23/23.Also fixed here (raised on #131, rounds 1 to 4): in the plan namespaces,
AddressOverride.toandRemediationDecl.forshowed thePartytype's description instead of their own rule. The schemas were right; the generator took whichever description a referenced type was first resolved with.gen-types.mjsnow wraps a reference that has its own description inallOf, so every field keeps its own text (to: nevercaller) and shared types become named (Party,Grade,Predicate) instead of inlined; shapes are unchanged andtsc --strictpasses.Review round 9 (2 findings, fixed): (1) the store resolver is
resolveItem, no longer shadowingpath.resolve. (2) a failed instantiation sample is recorded as a 3.10.5 failure and the measurement document is still written.Review round 10 (5 findings): (1) fixed: the wasm-opt pin matches the whole version token (
wasm-opt version 116then a space or the end), so1160fails it. (2) Repeated: refusing an output that names an input matches the file host, where the input is an existing file andensure_absentrefuses it the same way; the code says so. (3) Known and recorded: the raw size is over its 3.10.4 budget, which draft spec 046 addresses; until the owner decides, the gate reports it rather than the budget being weakened. (4) fixed: an output withoutnormalizeis read as having none. (5) The allowlist is every module name with every base name on purpose: the same reviewed glue is imported fromwbgor./rustev_wasm_bg.jsdepending on the target; the check says so.Review round 11 (4 findings): (1) fixed: make expands a recipe's lines before running the first, so the target directory is read before the Node check whatever the order; the refusal now names what it needs (cargo metadata and Node 20 or later on PATH). (2) Not a defect:
max_bytesgoes to the host only as a hint; the guard compares the returned length with it as integers, and on wasm32 ausizeis 32 bits, exact as an f64; the code says so. (3) A harvest that would write outside its fixtures is a broken test, not a case to skip: the test fails loudly, and the harvest rewrites its output on the next run. (4) Verified: the lockfile's integrity for lodash 4.18.1 equals the registry's (npm view [email protected] dist.integritygives the samesha512-dMIn...0Q==).Review round 12 (1 finding, fixed): each case, comparison included, runs in its own
runCaseunder the per-case catch, so a throw while reading a golden fails that case only.Review round 13 (1 finding, fixed): a replay case without
--now-msfails naming the flag (flags().need) instead of passingNaNon (which the Rust side would also refuse).Review round 14 (3 findings, all raised before): (1) lodash 4.18.1 is published, and its lockfile integrity equals the registry's (verified in round 13 and earlier). (2) A case that names the
wasmsurface for a command it lacks is a failure by design, counted as run: the suite must not silently skip a case it claims. (3) To settle it, the allowlist is now the exact reviewedmodule:namepairs (22, both targets' module names), checked as pairs.Review round 15 (3 findings): (1) fixed: a case file from an earlier harvest must record the same derived descriptors this harvest wrote, or the harvest fails and says to rebuild; run cases now carry the harvest's own
"derived": [], so every committed case file is reproduced byte for byte bymake conformance-harvest(the wall-clock replay bundles aside). (2) fixed: the flags a command cannot run without (definition,out,plan,bundle,now-ms) fail the case by name when absent. (3) No WebAssembly case pins a written output today (every one pins stdout), so nothing passed vacuously; a case that did is now compared against the artifact the command published under that name, never skipped.Review round 16 (1 finding, raised in earlier rounds too): lodash 4.18.1 was published on the public registry on 2026-04-01 (after the reviewer's knowledge cutoff), and the lockfile's integrity equals the registry's
sha512-dMIn...0Q==(npm view [email protected] time dist.integrity); it is json-schema-to-typescript 16.0.0's dependency andnpm ciinstalls it. The package now records this in its//note, so the diff carries the evidence.Review round 17 (1 finding): verified, and now verified on every build:
npm view [email protected] dist.integrityequals the lockfile'ssha512-dMIn...0Q==, andmake bindingsnow runsnpm audit signaturesafternpm ci, which checks every installed package's registry signature (locally: 16 packages with verified registry signatures, lodash 4.18.1 among them).Review round 18 (2 findings): (1) fixed: every path the
bindingsrecipe builds fromBINDINGS_OUTorCARGO_TARGETis quoted, so a target directory with a space is passed whole. (2) The spec says nothing about lodash (no "4.18.1" appears in it), and lodash 4.18.1 is published (2026-04-01) and now verified by registry signature on everymake bindings(npm audit signatures: 16 packages verified);npm ciinstalls it.Review round 19 (3 findings): (1) js-yaml 4.3.2 is published (
npm view [email protected] version dist.integrity), as is every package in the lockfile; the package's note now covers the whole tree rather than one package at a time:npm cichecks each package against its locked integrity, andmake bindingsverifies every installed package's registry signature (16 verified). (2) fixed: each scope mode's fields are required, so a replay case without them fails by name. (3) The hash width is fixed by the exact wasm-bindgen pin (0.2.129, 3.10.2); a new pin that changes it fails the allowlist loudly, which is wanted; the code says so.Review round 20 (4 findings): (1) fixed: a test pins that an output naming an input is refused. (2) fixed: a case file from an earlier harvest must also record the same surfaces. (3) fixed: each built target directory carries its module type (
webandbundlerES modules,nodeCommonJS, written bymake bindings), and the exports name the matching conditions (import,require); Node no longer warns that the module type is unspecified. (4) Already done as asked:make bindingsrunsnpm audit signaturesafternpm ci(16 packages with verified registry signatures, lodash 4.18.1 among them), which checks provenance, not only content.Review round 21 (1 finding, resolved): the owner ratified spec 046 (A-43, #136), raising the raw budget to 2,621,440 bytes and keeping the gzip and instantiation budgets and the gate;
wasm-optcould not close the gap (-Ozis the smallest at 2,216,152 bytes). The measurement check now applies the 046 budget, andmake bindingspasses end to end (wasm conformance 23/23). The spec 027 record says so.