MarshallOfSound

#53536: test: stop overrunning Squirrel.Mac updater runs and free their slots

Merged
Created: Sep 4, 2026, 12:44:48 PM
Merged: Sep 4, 2026, 1:48:07 PM
7 comments
Target: main

Follow-up to #53437. On the Intel macOS runners, one slow updater test could fail all four of its attempts. The shard then hit the 60 minute step timeout. That happened on about 1 in 40 x64 shards.

Two things caused it:

  • A mocha timeout does not cancel the pooled run. The run kept its slot and its app and ShipIt processes, and the retry queued behind it.
  • The Intel runners take about 45s per update just for ShipIt's signature check. At 4 concurrent runs, the slowest run came within 15% of its budget on a fresh runner.

Changes, all in spec/api-autoupdater-darwin-spec.ts:

  • Each run gets an AbortSignal and a budget of twice its test timeout. The budget starts when the run gets a slot, so time spent queued does not count. The mocha timeout is now only a backstop.
  • An aborted run kills the processes it started, removes its ShipIt job, and clears its slot's downloaded updates. relaunched() rejects on abort. If a run does not unwind within 20s, its slot is replaced with a fresh one.
  • Runs default to concurrency 2 on x64. arm64 keeps its current default.
  • ELECTRON_SPEC_UPDATER_RUN_BUDGET_MS overrides the budget, to exercise the abort path.

Measured on a stress branch, against a main Testing build, on the CI runners (macos-15-large, first iteration on a fresh runner):

x64 Concurrency 4 Concurrency 2
Suite time 536s (1 run) median 619s (5 runs, 569s to 802s)
Slowest run 204s (85% of budget) 113s to 147s (47% to 61%)

No retries in 10 runs at concurrency 2. Locally, with a 6s budget, every run was aborted and cleaned up, and no processes or launchd jobs were left behind.

Notes: none

Backports

43-x-y
Merged
PR Number
#53542
Merged At
Sep 4, 2026, 3:52:46 PM
Released In
Not yet
Release Date
Not yet
44-x-y
Merged
PR Number
#53543
Merged At
Sep 4, 2026, 3:59:13 PM
Released In
Not yet
Release Date
Not yet
45-x-y
Merged
PR Number
#53544
Merged At
Sep 4, 2026, 3:52:53 PM
Released In
Not yet
Release Date
Not yet

Semver Impact

Major
Breaking changes
Minor
New features
Patch
Bug fixes
None
Docs, tests, etc.

Semantic Versioning helps users understand the impact of updates:

  • Major (X.y.z): Breaking changes that may require code modifications
  • Minor (x.Y.z): New features that maintain backward compatibility
  • Patch (x.y.Z): Bug fixes that don't change the API
  • None: Changes that don't affect using facing parts of Electron