ci: run tests on a bun build that has the spawnSync fix

Merged
SA
1mo ago
+7-0

About 7% of Test jobs hang. The watchdog from #8305 showed why: a bun test process sits at ~100% CPU with one exited child it never collected. That is bun spinning in a synchronous spawn (Bun.spawnSync, execSync, execFileSync); the per-test timeout cannot end it. oven-sh/bun#44581 fixes it (merged 2026-10-05) and is not in a release yet. 1.4.2 is still the latest.

Change

The Test job installs bun@1.4.2-canary.20261007.1 from npm (commit bd599f5af, three commits after the fix) and puts it first on PATH, after dependencies are installed with the pinned 1.4.2. Every other job, and everything we ship, stays on 1.4.2. The npm version is immutable, so the build does not move.

Evidence

Measured on #8310 by running the Test job many times per push:

bunTest jobsHangsOther failures
1.4.2 (pinned)12094
1.4.3-canary.1 (5749c3129, setup-bun canary)12003
1.4.2-canary.20261007.1 (bd599f5af, this PR)6001

The canary failures were the known workspace-fs watcher and i18n provider flakes and one host-service test. All 9 hangs and the 4 other failures on 1.4.2 were in desktop; the 4 were spawn tests that hit the 5 s timeout, which is the same bug in a milder form.

Cost

Tests run on a pre-release bun that differs from the one we ship. Remove the step when .bun-version moves to a release that has the fix. The watchdog from #8305 stays for now so a hang from any other cause still ends at 6 minutes with a dump.


Summary by cubic

Fixes the ~7% of Test jobs that hung when bun 1.4.2 spun forever in a synchronous spawn, which the per-test timeout could not end. The Test job now installs bun@1.4.2-canary.20261007.1 (contains the oven-sh/bun#44581 fix) after dependencies are installed with the pinned 1.4.2, and puts it first on PATH. Everything else stays on 1.4.2. Remove this step once .bun-version moves to a release with the fix.

Summary by CodeRabbit

  • Chores
    • Updated the automated test environment to use a Bun version with a fix for a test-running issue.
    • This change affects the project’s build and test process; it does not change end-user features or app behavior.