You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 4750483
Browse filesBrowse the repository at this point in the historyBrowse files
test_launcher_e2e: make the launch: idle-respawn case real
"ResolveAndConnect respawns an idle-shutdown launch: worker" had no
checks: a comment, `(void)location; // SKIPPED`, and so a pass on every
run. It was written in beafc4c, when ResolveAndConnect could only launch
with LaunchConfig's 300 s idle timeout, far too long to wait out in a
test. LaunchOverrides landed the same day (c3143fa) and now carries
idle_timeout and state_dir through ResolveAndConnect, but the
placeholder was never revisited. Nothing else covered the path it names:
the unix:// case asserts an IOException (nothing respawns those), and
"retries once when the cached path goes stale" clears the cache and
reconnects to a live worker, so its retry never fires.
The case now drives real processes. It resolves a `launch:` location
with a 1 s idle timeout in an isolated state dir, records the worker's
PID from the kernel (SO_PEERCRED on Linux, LOCAL_PEERPID on macOS),
disconnects, waits for the worker to idle-shut-down and unlink its
socket, asserts the cache still hands out that dead path, and calls
ResolveAndConnect again. It must connect, to a different PID at the same
per-hash path. The cache entry is dropped on every exit so its override
pin cannot leak into later cases as a BinderException.
With ResolveAndConnect's invalidate-and-relaunch retry temporarily
replaced by a rethrow, the case fails with the IOException for the dead
socket; restored, it passes (first worker 4019193, respawned 4019201).
All 50 [launcher] cases pass. The macOS branch was syntax-checked only.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
0 commit comments