subagent transcript
session 18e25685 · workflow wf_23df5b1c
delegated task
You are an adversarial verifier for a FreeCAD-wasm code review. A reviewer claims: SEVERITY: high CATEGORY: stale-version-lock FILE: /home/magik6k/lca
▸ Magik
You are an adversarial verifier for a FreeCAD-wasm code review. A reviewer claims:
SEVERITY: high
CATEGORY: stale-version-lock
FILE: /home/magik6k/lcad-wasm/freecad-port/toolchain/versions.lock
SUMMARY: versions.lock pins the abandoned emsdk 4.0.7 / prebuilt-Qt posture, not the current shipping ASYNCIFY+JS-EH / emsdk 4.0.12 / source-built qt-asyncify config.
DETAIL/EVIDENCE: toolchain/versions.lock:5 pins `emsdk = 4.0.7` with a rationale about preserving the prebuilt-Qt embind ABI, and line 12 documents Qt as 'prebuilt via aqtinstall'. But the active toolchain is emsdk 4.0.12 (emsdk/upstream/emscripten/emscripten-version.txt = "4.0.12"; PATH/comments in rebuild-deps-*.sh assume 4.0.12), and Qt is now SOURCE-built with asyncify into /opt/toolchains/qt-asyncify (configure-stage2.sh:10). STATUS.md:23 itself says 'Built on emsdk 4.0.12, qt-asyncify, JS-EH deps'. The lock file's 4.0.7 rationale is moot (source-built Qt has no prebuilt-ABI constraint), and the lock captures NONE of the current defining choices: emsdk 4.0.12, QT_EMSCRIPTEN_ASYNCIFY=1 source Qt, -fexceptions (JS-EH) deps, -sASYNCIFY link, or the trampoline patch. The compile posture note at versions.lock:36-39 also still describes the Stage-1 headless JS-exceptions posture. Anyone rebuilding from versions.lock reproduces the OLD, non-working combination.
RECOMMENDATION: Rewrite versions.lock to describe the current shipping config (emsdk 4.0.12, source qt-asyncify 6.11.1 with QT_EMSCRIPTEN_ASYNCIFY=1, deps built -fexceptions, -sASYNCIFY, forced JS trampoline) and record the exact emsdk commit/tag actually activated.
Independently verify by reading the actual file(s) and running git/grep as needed (repo at /home/magik6k/lcad-wasm/freecad-port/FreeCAD, toolchain at /opt/toolchains, deploy at /home/magik6k/lcad-wasm/freecad-port/deploy-gui). Default to REFUTED if you cannot confirm the evidence. Adjust severity to what the evidence actually supports.
Fable
thinking
I should check the actual files to confirm this.
Fable
⚙ Read {"file_path": "/home/magik6k/lcad-wasm/freecad-port/toolchain/versions.lock"}
Fable
⚙ Bash {"command": "cat /opt/toolchains/emsdk/upstream/emscripten/emscripten-version.txt 2>/dev/null; echo \"---STATUS---\"; sed -n '1,40p' /home/magik6k/lcad-wasm/freecad-port/STATUS.md 2>/dev/null"}
Fable
thinking
Looking at the lock file, emsdk is pinned to 4.0.7, but there's a discrepancy where line 28 shows "activated 4.0.12" and the actual emscripten-version.txt confirms 4.0.12. The STATUS.md indicates the build used emsdk 4.0.12 with qt-asyncify, so I need to check the qt-asyncify source build and the configure and rebuild scripts to understand this version mismatch.
Fable
⚙ Bash {"command": "ls -d /opt/toolchains/qt-asyncify 2>/dev/null && echo \"qt-asyncify EXISTS\"; echo \"---configure-stage2---\"; sed -n '1,20p' /home/magik6k/lcad-wasm/freecad-port/toolchain/configure-stage2.sh 2>/dev/null; echo \"---find config…
Fable
⚙ Bash {"command": "grep -rn \"4.0.12\\|4.0.7\\|ASYNCIFY\\|QT_EMSCRIPTEN_ASYNCIFY\\|qt-asyncify\" /home/magik6k/lcad-wasm/freecad-port/toolchain/*.sh 2>/dev/null | head -50"}
Fable
thinking
I'm looking for the rebuild-deps scripts that were mentioned in the claim.
Fable
⚙ Bash {"command": "find /home/magik6k/lcad-wasm/freecad-port -name 'rebuild-deps*' 2>/dev/null; echo \"---all sh in toolchain---\"; ls /home/magik6k/lcad-wasm/freecad-port/toolchain/*.sh 2>/dev/null; echo \"---grep 4.0.12 across toolchain dir---\…
Fable
thinking
I'm searching the repository more broadly for those rebuild-deps scripts since they don't appear to be where expected.
Fable
⚙ Bash {"command": "find /home/magik6k/lcad-wasm -name 'rebuild-deps*' 2>/dev/null; echo \"---grep rebuild-deps mentions---\"; grep -rln \"rebuild-deps\" /home/magik6k/lcad-wasm/freecad-port 2>/dev/null | head; echo \"---configure-stage1 head---\"…
Fable
thinking
The rebuild-deps scripts mentioned in the evidence don't actually exist, which is a minor discrepancy but doesn't undermine the main findings. The key claims check out: versions.lock confirms emsdk 4.0.7 is pinned with prebuilt-Qt embind ABI reasoning, Qt is documented as prebuilt through aqtinstall, and the active toolchain is running emsdk 4.0.12 based on the emscripten-version.txt file.
I'm also verifying the Stage-1 compile configuration and the STATUS.md documentation about the build environment. There's an internal contradiction in versions.lock though — it pins emsdk 4.0.7 at line 4 but shows "activated 4.0.12" at line 28, and the actual active version is confirmed as 4.0.12. The loc …
Fable
I've verified the key evidence. Let me confirm the exact STATUS.md line 23 and that no ASYNCIFY appears in the lock.
Fable
⚙ Bash {"command": "grep -n \"Built on emsdk\" /home/magik6k/lcad-wasm/freecad-port/STATUS.md; echo \"---ASYNCIFY in lock?---\"; grep -in \"asyncify\\|4.0.12\" /home/magik6k/lcad-wasm/freecad-port/toolchain/versions.lock; echo \"---wc lock---\"; w…
Fable
thinking
I'm verifying the configuration across the build system: the versions lock file pins emsdk to 4.0.7 with Qt built as a prebuilt binary through aqtinstall, while the active emsdk is actually 4.0.12, and Qt has been source-built with asyncify support in the toolchain directory at the configure stage.
The STATUS.md file confirms this was built on emsdk 4.0.12 with qt-asyncify and JavaScript exception handling dependencies, and the compile posture notes describe the Stage-1 JS-exceptions setup. However, the lock file itself is internally contradictory—it pins 4.0.7 at the headline but then requires and activates 4.0.12 elsewhere, meaning the lock is stale and doesn't capture the actual asyncify …
Fable
All core evidence confirmed by direct inspection:
- `versions.lock:4` pins `emsdk = 4.0.7` with a rationale about preserving the prebuilt-Qt embind/emval ABI (lines 4-11).
- `versions.lock:12-15` documents Qt 6.11.1 as "prebuilt via aqtinstall" and explicitly says a source build is "only needed when we enable JSPI (Stage 3)".
- The active toolchain emsdk is 4.0.12 (`emscripten-version.txt = "4.0.12"`).
- Qt is source-built with asyncify into `/opt/toolchains/qt-asyncify` (exists on disk), used by `configure-stage2.sh:10`.
- `STATUS.md:23` states "Built on emsdk 4.0.12, qt-asyncify, JS-EH deps."
- The lock's compile/link posture note (lines 36-38) still describes the Stage-1 headless `-fexceptions` + JS-exceptions posture; the file contains NO mention of ASYNCIFY, QT_EMSCRIPTEN_ASYNCIFY, `-sASYNCIFY`, source-built Qt, or the JS trampoline patch.
Two minor caveats that don't undermine the core claim:
- The claim's reference to "rebuild-deps-*.sh" scripts is wrong — no such files exist in the repo (auxiliary evidence only).
- The lock is actually internally *contradictory* rather than purely pinning 4.0.7: line 18 notes "requires emsdk >= 4.0.12" and line 28 says "emsdk (activated 4.0.12)". So the headline pin (4.0.7) and Qt-prebuilt posture are stale, but the file does scatter 4.0.12 references, which slightly softens the "reproduces the old combination" impact.
The factual heart of the finding holds: the lock's defining pins (emsdk 4.0.7, prebuilt aqtinstall Qt, Stage-1 JS-EH posture) do not match the current shipping config and capture none of the asyncify/source-Qt/trampoline choices. This is a real stale-lock documentation defect, but it is a reproducibility/docs issue rather than a runtime correctness or security bug, and the lock already hints at 4.0.12 in places — so "high" is overstated. Medium is appropriate.
Fable
⚙ StructuredOutput {"verdict": "CONFIRMED", "reason": "Direct inspection confirms the substance: versions.lock:4 pins emsdk=4.0.7 with a prebuilt-Qt embind/emval ABI rationale, and line 12-15 documents Qt as prebuilt via aqtinstall (source build \"only needed…