Files
workinf_Blender_Wasm/tools/web/check-rc-known-limitations.mjs
mes123456 192b13901d fix(web): reject stale sequencer transition timelines
setSequencerTransitions parsed the submitted timeline without comparing
timeline.revision, so a stale submission replaced the sequencer timeline
instead of conflicting. It now compares timeline.revision against the
current SceneIR and reports REVISION_CONFLICT, which is the check
setSequencerStrips already makes. The revision contract moves the command
out of the unchecked set, and the authoring probe takes its timeline from
a snapshot read after its edits and records a stale submission next to an
accepted one.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-12-02 20:12:37 +08:00

57 lines
2.8 KiB
JavaScript

import assert from "node:assert/strict";
import fs from "node:fs";
import path from "node:path";
import { fileURLToPath } from "node:url";
const repoRoot = path.resolve(path.dirname(fileURLToPath(import.meta.url)), "../..");
const limitationsPath = path.join(repoRoot, "docs/web/KNOWN_LIMITATIONS.md");
const limitations = fs.readFileSync(limitationsPath, "utf8");
const notes = fs.readFileSync(path.join(repoRoot, "docs/web/RELEASE_NOTES.md"), "utf8");
const engine = JSON.parse(fs.readFileSync(path.join(repoRoot, "web/app/public/engine-manifest.json"), "utf8"));
assert.ok(notes.includes("[Known limitations](KNOWN_LIMITATIONS.md)"), "release notes do not link known limitations");
for (const variant of engine.variants) {
assert.equal(variant.memory.initialPages, 256);
assert.equal(variant.memory.maximumPages, 32_768);
}
for (const required of [
"Chromium is the only V1 browser baseline",
"crossOriginIsolated",
"SharedArrayBuffer",
"PTHREAD_REQUIRED",
"SINGLE_REQUIRED",
"ENGINE_VARIANT_INTEGRITY_FAILED",
"REFRESH_REQUIRED",
"256 initial WebAssembly pages (16 MiB)",
"32,768-page ceiling (2 GiB)",
"bound to the exact scheme, host and port",
"reserves no minimum capacity",
"64 MiB",
"16,384 pixels per dimension",
"256 requested",
"VDB input is bounded to 512 MiB",
"NanoVDB bundle to 1 GiB",
"residency to at most 512 MiB",
"Automatic viewport page-fault feedback",
"The armature headed regression is resolved, and its earlier diagnosis was wrong",
"the armature object was never missing from the Outliner",
"The Rendering workspace Outliner gap is closed by desktop parity",
"Revision-conflict handling is per command in the engine Worker",
"`setNLAStack` still carries a revision field but does not reject a stale",
"fcurve or keyframe counts, so no count assertion is made",
]) {
assert.ok(limitations.includes(required), `known limitations omit: ${required}`);
}
const renderAssets = fs.readFileSync(path.join(repoRoot, "web/protocol/render-assets.ts"), "utf8");
assert.match(renderAssets, /MAX_GPU_TEXTURE_BYTES = 64 \* 1024 \* 1024/);
assert.match(renderAssets, /MAX_GPU_TEXTURE_DIMENSION = 16_384/);
assert.match(renderAssets, /MAX_GPU_TEXTURE_ASSETS = 256/);
const volume = fs.readFileSync(path.join(repoRoot, "web/protocol/volume-vdb.ts"), "utf8");
assert.match(volume, /VDB_MAX_RESOURCE_BYTES = 512 \* 1024 \* 1024/);
assert.match(volume, /NANOVDB_MAX_BUNDLE_BYTES = 1024 \* 1024 \* 1024/);
assert.match(volume, /NANOVDB_MAX_GPU_RESIDENT_BYTES = 512 \* 1024 \* 1024/);
for (const link of ["V1_SCOPE.md", "parity-ledger.json", "DEPLOYMENT.md", "operations-diagnostics.json"]) {
assert.ok(limitations.includes(`](${link})`), `known limitations omit link: ${link}`);
}
process.stdout.write(`rc-known-limitations-ok variants=${engine.variants.length} wasmMaximumPages=${engine.variants[0].memory.maximumPages}\n`);