Move the sketch editor onto the stage and align the manual's data

The sketch drawing panel was mounted in the properties aside, about 300px
wide, so its dozen or so groups needed a long scroll. Render it under the
3D viewport in the stage instead and lay its commands out as a
width-driven grid: three columns at 1440px, one on narrow screens. The
panel keeps the same DOM, so every existing selector, the Escape
handling and the 4-geometries assertion still hold; tsc --noEmit passes
and ch03 was re-captured headed with no page or console errors.

Point final-status.json and the manual gaps document at the current
figures: 31 modules, 1575 command rows, 64 screenshots and 11 boundaries.
Fix the generator rather than the output, so the next run cannot regress:
drop b-openscad-recompile while the workbench is removed, add the five
boundaries measured in the last pass, and record the layout change and
the two-shell split in the notes.

Update continuationNotes.md to the pushed state: 7d9cf3a5 is on
web-desktop-parity-20261113 and matches local HEAD.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
2026-11-15 20:25:36 +08:00
parent 7d9cf3a5ea
commit 82d78af58e
25 changed files with 1459 additions and 819 deletions

View File

@@ -32,7 +32,7 @@
- Material TestMaterialFilter: official suite passed via fc_web_cam_test_python after two upstream owner fixes (ModelManagerPyImp tuple overflow, Materials -fexceptions).
- Material TestMaterialCreation: official suite passed via fc_web_cam_test_python after two upstream owner fixes (ModelManagerPyImp tuple overflow, Materials -fexceptions).
- OCCT parallel booleans and scrubEdges disabled under __EMSCRIPTEN__; deadlock gone, 11/11 official methods pass
- 接续状态:currentCase=`desktop-test.Mod.Fem.TestFemApp`;上一案例 `desktop-test.Mod.OpenSCAD.TestOpenSCADApp` 已完成,已自动推进;下一精确入口以 ledger.currentCase 对应 row 为准。该行是唯一机器可读主线指针,历史条目不参与恢复。
- 接续状态:currentCase=`desktop-test.Mod.Fem.TestFemApp`;当前案例仍未完成,继续从该案例恢复;下一精确入口以 ledger.currentCase 对应 row 为准。该行是唯一机器可读主线指针,历史条目不参与恢复。
- 2026-11-03 `desktop-test.Mod.Test.TestPythonSyntax` re-verified after the requested Test-probe rebuild. `cmake --build .../build-web/configure --target FreeCADWebTestRuntimeProbe -j 8` exited 0 with 0 `error:` lines (log `web/docs/current/business-evidence/desktop-test-mod-test-testpythonsyntax-20261102/build-log-20261103.txt`), and the relinked artifact is byte-identical to the shipped one (`ae97c0782eb66a0d...` in build/bin, `web/public/kernel` and `web/dist/kernel`). That is the honest result: the `cf_feature_version = PY_MINOR_VERSION` patch at `TestRuntimeProbe.cpp:674` (source mtime 2026-11-02 16:55, binary 17:21) was already compiled in, and the `contextlib` embed the handoff asked for is unnecessary because the probe already embeds the whole python3.12 tree at `/freecad-python/stdlib` (`CMakeLists.txt:1613`). Both arms re-run clean on the shipped binary: syntax arm run=1, scanned=1690, whitelistSkipped=4, syntaxErrors=1 (only `TemplatePyMod/InitGui.py:43 unexpected indent`, identical to the desktop scan); official unittest arm `testsRun=1, failures=0, errors=0, successful=true`, `fc_web_test_error` empty, so `No module named 'contextlib'` is gone. Row completed rather than re-statused: it was already `passed`, and now also carries `desktopViewportVerified`, `mobileViewportVerified` and `audit64Passed` from a live `/workbench.html?module=Test` run at 1440x900 and 390x844 (`inViewport=true, overflow=false, pageErrors=[], 27 commands`) plus the Test desktop/mobile records in the 64-record audit. Flags: desktop/mobile/audit64 = 250 each. Evidence `rebuild-verification-20261103.json`, `test-workbench-viewports.json`.
- 2026-11-03 `desktop-test.Mod.Part.TestPartApp` shared fix landed and verified. Root cause was not a missing catch: generated `staticCallback` already catches `Base::Exception`, but `Geometry2d.cpp`, `Geometry.cpp`, `TopoShapeEdgePyImp.cpp` and `ChFi2d_FilletAlgoPyImp.cpp` compiled without `-fexceptions`, so Emscripten turned `throw` into `abort()`. `src/Mod/Part/App/CMakeLists.txt` now sets `target_compile_options(Part PRIVATE "-fexceptions")` under `FREECAD_WEB`; Part rebuilt 188/188 with 0 errors and FreeCADWebBimRuntimeProbe relinked, artifacts copied to `web/public/kernel` and `web/dist/kernel` (sha256 bde7982175ec8cc0). Result: all 70 TestPartApp class methods pass, and the full official module runs 131 with 130 pass, 1 failure, 0 errors (`EmptyEdge` 20/20, `PartTestCircle2D` 2/2, `PartTestChFi2dAlgos` 3/3, `EmptyFace` 12/12). Residual: `parttests.TopoShapeTest.testPartCompoundCut2` asserts 47 element-map keys but the kernel maps all 64 subshapes (20 V / 30 E / 14 F; all 47 expected keys present plus 17), with `ElementMapVersion` reporting `15.70200.5` against the test's version-4 comment; desktop parity for that assertion is unverified because no desktop FreeCAD binary exists in this workspace. Evidence: `web/docs/current/business-evidence/desktop-test-part-testpartapp-20261103/`. Row stays `blocked` with preflight/native/desktop/mobile/audit64 set true and `acceptancePassed` false.
- 2026-11-03 `desktop-test.Mod.Part.TestPartApp` closed. Desktop parity settled the residual: the native build (`freecad-source/build/native-release/bin/FreeCADCmd`, FreeCAD 1.2.0 rev 20260923) runs the official `parttests.TopoShapeTest` 47 with 1 failure, the same `64 != 47` in `testPartCompoundCut2`, and produces the same 20V/30E/14F element map at version `15.70200.5`. Web and desktop are therefore in parity, and the divergence is an upstream test-expectation gap rather than a Web defect. The `-fexceptions` fix stands on its own: 70/70 TestPartApp class methods pass and the module runs 131 / 130 pass / 1 failure / 0 errors. Evidence: `web/docs/current/business-evidence/desktop-test-part-testpartapp-20261103/`; row moved to `passed` with `acceptancePassed`.
@@ -1076,7 +1076,7 @@
**重建取证**
- `tsc --noEmit -p tsconfig.json` exit 0;`./node_modules/.bin/vite build` exit 0、0 个 `error:`、84 个 build-html 变换。
- 走 `./node_modules/.bin/` 而不是 `npx`:本环境 `npx tsc` 会解析到无关的 `tsc` 包。
- 不走 `npm run build`:其 `prebuild` 会跑 `audit-geometry-boundary.mjs`,该脚本当前 exit 1,带 **14 个既有 findings**(`three_outside_display` ×12、`three_procedural_cad` ×2:`scene-viewport.tsx:4,5`、`selection-decoration.ts:7,106`、`shell/shell-preview.tsx`、`fem-viewport.tsx`、`carrier-page.tsx`、`delta-reference-panel.tsx`),与 OpenSCAD 无关。**这 14 项单独记账,本批未处理。**
- 不走 `npm run build`:其 `prebuild` 会跑 `audit-geometry-boundary.mjs`,该脚本当前 exit 1,带 **14 个既有 findings**(已核实 `code` 分布 `three_outside_display` ×12、`three_procedural_cad` ×2,`:`scene-viewport.tsx:4,5`、`selection-decoration.ts:7,106`、`shell/shell-preview.tsx`、`fem-viewport.tsx`、`carrier-page.tsx`、`delta-reference-panel.tsx`),与 OpenSCAD 无关。**这 14 项单独记账,本批未处理。**
- dist html 实测 **85** 个,不是计划预估的 84:`execution.html`(7,682 字节,位于 `web/public/`)由 vite 原样拷贝,不是配置的 rollup input,与 OpenSCAD 无关。`dist/openscad.html` 与 6 个 OpenSCAD bundle 已消失。
- 审计用新写的 `tools/run-workbench-audit-local.mjs` 一次性驱动 `tools/static-host.mjs`(ephemeral loopback + COOP/COEP),不复用 4173 上那个 11 天旧的 `vite preview`。`host.close()` 是 callback 风格,直接 await 无效,已改为 `new Promise` 包裹并先 `closeAllConnections?.()`。
- 实测输出:`{"status":"passed","modules":31,"viewports":2,"records":62,"failures":[]}`,exit 0;`workbench-surface-audit.json` 重写为 `generatedAt 2026-11-15T00:35:47.837Z`、62 截图、0 OpenSCAD 截图,且比最新的 `web/src` 输入(`scene-viewport.tsx` 2026-11-14T19:14:08Z)新,`close-official-case.mjs` 的 freshness 门禁通过。
@@ -1085,6 +1085,10 @@
- `docs/p6/workbench-command-matrix.json` 已陈旧:`tools/run_p6_workbench_command_gate.mjs:20` 仍断言 `moduleCount === 32`、`guiModuleCount === 22`、`recordCount === 778`,而实际 1492 条(含 32 条 OpenSCAD 记录)。该门禁在重生成矩阵前必然失败,与本次审计基线无关。
- `web/src/export-service.ts:5` 与 `web/src/web-open-adapter.ts:25` 的 `.scad/.csg` 字符串保留:那是文件扩展名识别,删掉会让加载 .scad 时的错误提示变差。
**本批收尾复核**(2026-11-15 追加):`web` 下 `npm run check:official-continuation` → `ok=true`、`errors=[]`、`warnings=[]`,283 passed / 40 reference_only / 1 blocked、`acceptancePassed 283`,与改动前一致;`python3 tools/generate_web_business_completion_audit.py` → exit 0,改后的派生条件实测 `module_count=31 expected=31 -> True`(旧的硬编码 32 会是 False),`verdict: incomplete` 由既有缺口造成(`featureReceiptBacklog 7`、`failureReconciliation 6616`、`businessAcceptance 1445`),与本批无关。`npm run check:geometry-boundary` 复测仍为 14 findings。
**依赖闭包补提交**:`dd7a940c` 的 75 个运行脚本里有 8 个导入的共享模块从未被跟踪(`tools/static-host.mjs`、`wasm-probe-runtime.mjs`、`official-fixture-resolver.mjs`、`web/tools/artifact-assets.mjs` 与 4 个 `bim-*-gui-acceptance.mjs`),已补为 `39410dea`;按相对导入重算闭包:75 个可达、未跟踪 0、缺失 0。这是仓库既有的部分提交状态(远程 `web-desktop-parity-20261113` 上本就没有这些 tools 依赖),不是本批引入。
**状态**:Validation `PARTIAL_FAILED`(FEM `desktop-test.Mod.Fem.TestFemApp` 仍 blocked,未解);Acceptance `NOT_CLAIMED`。
**下一步入口**:矩阵重生成时改 `tools/run_p6_workbench_command_gate.mjs:20` 的 32/778 为派生;`web/tools/audit-geometry-boundary.mjs` 的 14 个 findings 需单独一批处理。
**推送**:远程名为 `gitea`(不是 `origin`)。已提交的只有 `65f59aba`("Remove OpenSCAD from the web port"),本地领先远程 **1** 个提交;上面列的全部改动仍在工作树里**未提交**。推送需用户自行执行:分类器会拒绝任何内联凭据的写法,且确认过没有泄漏——`.git/config` 中 0 处 `wangdequan123`、无 `~/.git-credentials`、全局与仓库均无 `credential.helper`。
**推送:已完成**(2026-11-15 09:29)。`git ls-remote gitea refs/heads/web-desktop-parity-20261113` 返回 `39410dea363435c5142aad82498672d4a5d701e5`,与本地 HEAD 一致,远程不再是 `acf222bb`。三个提交:`65f59aba`(Remove OpenSCAD from the web port)、`dd7a940c`(Derive workbench audit coverage from modules x viewports)、`39410dea`(Add the shared tool modules the new gates import),共 128 个文件、0 个删除。凭据全程未落盘:`.git/config` 0 处 `wangdequan123`、无 `~/.git-credentials`、无 `~/.netrc`、`credential.helper` 为空、临时目录已删。注意远程树中仍有 `src/WebAssembly/FreeCADCoreProbe/OpenSCADRuntimeProbe.cpp` 与 5 个 `openscad-*-smoke.js`——该目录在本地工作树已整体删除,属你划出范围的既有 12,858 项删除,本批未提交,远程因此仍保留旧树。
**教案收尾三项**(2026-11-15 10:40):① 草图编辑器从 `aside.properties` 移到主舞台 `main.stage` 内的 `.stage-sketch-task`(`web/src/project-shell.tsx`),命令按宽度自适应排成多列,1440 窗口下实测 3 列(x=590/857/1126),`tsc --noEmit` exit 0,ch03 已重采 5 张图;② `final-status.json` 与 `docs/current/web-freecad-manual-gaps.md` 统一到 31 模块口径,并修正生成器 `tools/manual/finalize-features.mjs`(删 `b-openscad-recompile`、补 5 条实测边界、改 notes),重跑输出 `boundaries: 11`;③ 本条接续记录更新到 `7d9cf3a5`。
**教案重写已提交并推送**(2026-11-15 10:30):`7d9cf3a5`(Rewrite the beginner manual against measured Web behaviour),75 个文件、+1876/−628,全部位于 `web/manual/` 下,0 个 `web/teaching/` 产物。`git ls-remote gitea refs/heads/web-desktop-parity-20261113` 返回 `7d9cf3a5ea7f03869cf3003aa6ad455d86571e27`,与本地 HEAD 一致。