mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-12-05 19:25:00 +03:00
Replace the interactive control check in the dual-shell verifier with a legacy workspace readiness check for @affine/mobile 0.27.5. The verifier requires a valid workspace document route and a visible editor container with a mounted editor host. It also requires the legacy shell cookie and no synthetic legacy shell object. One page check covers these conditions, and it uses the same route parser as Node. The verifier runs this page check again after each IndexedDB read and before it returns. A shell that leaves the document route or unmounts the editor before it stores data fails. The verifier loads yjs on demand so Node tests run without installed packages. It reads only target document records from local IndexedDB and verifies root catalog and page block state. Rows must agree with the nbstore schema, and the updates store must have its docId index. When a fresh profile stops at the workspace home route, it reads one document ID from the catalog. It then locks that workspace and document and navigates once to the document route. A redirect to a different document fails the check. The legacy CLI path now reopens the mounted document in a new tab of the same Chromium profile. That tab blocks the welcome template, so the shell must load the workspace from IndexedDB. The local workspace database count must stay the same. A server that cannot serve the document route directly fails the check. Limit Chromium browser test file concurrency to two in CI so three browser suites do not overload four runner CPUs during SwiftShader startup. Add a zero-dependency Node script that scans WebAssembly Section 11 data segments for eleven harness snapshot ID prefixes. The script also scans Rust sources under blocksuite/crates to confirm that every watched prefix stays active. The source scan ignores test modules and their child modules. Wire the source check into packages/frontend/scripts/check-invariants.sh. Wire the binary check into .github/workflows/native-playground.yml after wasm-opt.