Files
AFFiNE/scripts/ci
DarkSky 82e166f49b test(parity): frozen v0.27.5 self-parity run, web build lane, fewer waitForTimeout
Parity harness:
- `compare` re-runs the comparison on a recorded report offline through
  the same protocol/database/effects path as live runs, and like `run`
  rejects scenarios without steps.
- `require` lists per-side checks (equals, length, contains); an unmet one
  is a difference at /require/<side><pointer>, so two sides failing the
  same way are never green.
- Timestamps also accept RFC 2822 HTTP dates (cookie Expires), with both
  sides in the same format.
- Socket.IO `record_events` limits which pushed events are reported;
  `wait_event` still sees all of them.
- scripts/run-v0275-self-parity.mjs boots two @affine/server instances of
  the checkout given by --server-root (the frozen baseline,
  darksky/before-stable-fix c2929acf2d) on
  leased PG16 clones, two Redis containers, two SMTP capture ports and
  separate HOMEs, in a run directory of its own; runs the data migrations,
  validate-cutover and workspace lifecycle activation; replays
  scenarios/v0275-self-parity.json (/info, GraphQL setup/auth/workspace/
  quota, Socket.IO join/push/load, a real test mail) and requires 0
  differences across protocol, all user tables, SMTP and Redis plus every
  requirement (doc accepted and stored, schema_baseline_0275 checkpoint,
  one mail, invalidation and event bus messages), then a tampered
  right-side DB row and GraphQL field reported at exactly their paths.
  Only a passing run writes --record, atomically, with the server SHA;
  cleanup failures fail the run; a temporary static manifest is removed.
- tests/v0275_self_parity.rs replays a committed recording of the frozen
  baseline, injects one change per dimension and checks that both sides
  losing the same results fail their requirements.

CI:
- np-web-build.yml builds @affine/web, @affine/mobile and @affine/admin on
  ubuntu-24.04 without Electron/Playwright/Sentry downloads, each bundle
  within eight minutes, and checks the bundle entry exists;
  native-playground.yml calls it only when frontend sources change.

Test debt:
- Delete the unused blocksuite std inline test helper and the unused
  selectVisibilitySelector; drop sleeps already covered by auto-waiting
  assertions and click(); poll getIndexCoordinate per animation frame.
  waitForTimeout ceiling 378 -> 370.
2026-11-23 13:58:04 +09:00
..