MarshallOfSound

#53607: test: stop aborted Squirrel.Mac updater runs cleanly

Merged
Created: Sep 5, 2026, 5:26:47 PM
Merged: Sep 6, 2026, 3:32:28 AM
4 comments
Target: main

Follow-up to #53536. That change stops an overrunning updater run, but stopping it could itself fail: stopRun SIGKILLed the fixture app and immediately removed the slot's update directory, and the app still had files there open for a moment, so rm threw ENOTEMPTY. That error replaced the run's own, and the retry then queued behind the other slot with no bound on the wait. On a slow Intel runner one such test could take a shard past its 60 minute step timeout, which is what happened on the release-branch backports.

  • Each fixture app is spawned as its own process group (detached: true), so it, its helpers and any ditto it started are killed with one kill(-pgid). The psList path-prefix scan is gone. ShipIt is a launchd job rather than our child, so it is still stopped by removing its job.
  • stopRun waits for the killed groups to be gone before touching the filesystem, retries the removal for a few seconds, and never throws. A slot it cannot clean is retired so the next run does not inherit it. The suite's after hook uses the same retrying removal.
  • A retry waits at most its budget for a slot, then retires one, instead of waiting silently behind a stuck lookahead run.

Verified locally on the same build: the normal suite passes with no retries; the grep'd abort test, which is the case that failed on CI, now passes with no after-hook failure; and a run with a forced 6s budget reports the budget error for every aborted run, with no ENOTEMPTY and no processes, launchd jobs or ditto left behind.

Notes: none

Backports

43-x-y
Merged
PR Number
#53618
Merged At
Sep 6, 2026, 4:24:47 AM
Released In
Not yet
Release Date
Not yet
44-x-y
Merged
PR Number
#53619
Merged At
Sep 6, 2026, 4:24:48 AM
Released In
Not yet
Release Date
Not yet
45-x-y
Merged
PR Number
#53617
Merged At
Sep 6, 2026, 4:24:56 AM
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