[eric] ci: parallelize + cache the e2e gate to cut push wall-clock under ~10 min

- split the single windows e2e job into parallel jobs: gate (pure-node
  selftests, no build), verify (build + verify-all), playwright (build +
  renderer suite). verify and playwright run concurrently so wall-clock is
  max(verify, playwright), not their sum
- build the UNPACKED app on the gate path (electron-builder --dir via a new
  -DirOnly switch in build-app-win.ps1), skipping the ~2min NSIS LZMA
  compression. verify-all drives win-unpacked\OpenSwarm.exe; afterPack +
  locale paks still run in the pack phase, and verify-update-feed skips
  cleanly when no installer feed is present
- cache the heavy build inputs (bundled Python env, uv, MCP bundles) + npm
  across runs, keyed on their source manifests; the build script already skips
  any input already on disk, so warm builds are fast
- move the destructive installer cycle to its own job gated off routine pushes
  (runs on PR-to-main / dispatch; release-windows.yml covers v* tags)
- apply the same caching to dogfood (shares cache keys, so the two warm each other)
This commit is contained in:
Eric
2026-05-28 23:55:32 -07:00
parent 99f1e56497
commit 2b4d90edaa
3 changed files with 182 additions and 91 deletions
+11 -1
View File
@@ -11,6 +11,10 @@
param(
[switch]$Sign,
[switch]$Publish,
# Fast CI gate path: build only the unpacked win-unpacked\ dir (no NSIS
# installer, no LZMA compression of the ~1GB tree - the slowest packaging
# phase). verify-all + Playwright drive the unpacked OpenSwarm.exe directly.
[switch]$DirOnly,
# Phase 7 A/B: build a Squirrel.Windows installer instead of the default
# NSIS one, from the SAME staged tree / SAME commit. Opt-in only; NSIS stays
# the default and shipped target until Squirrel is proven faster AND its
@@ -434,7 +438,13 @@ try {
$env:CSC_IDENTITY_AUTO_DISCOVERY = 'false'
}
if ($Publish) {
if ($DirOnly) {
# Unpacked-only build for the fast CI gate. afterPack (router node_modules)
# and locale-pak filtering still run during the pack phase, so the produced
# win-unpacked\OpenSwarm.exe is fully functional; only the NSIS installer +
# update feed are skipped (verify-update-feed skips cleanly when absent).
& npx electron-builder --win --x64 --dir @TargetOverride --publish never
} elseif ($Publish) {
# Safety check: warn if the matching Mac release isn't on GitHub yet.
# Mac and Windows publishes don't conflict (different asset names,
# different latest*.yml manifests), but a Windows-only release means