CI flake: a recorded-host run's tear-down finds its command's session still running 10 s after SIGKILL #179

Open
opened 2026-11-25 10:41:48 +00:00 by saturnus · 1 comment
Member

Purpose (fix): a recorded-host case that passed goes green, and the run's tear-down fails only when something of the run really keeps running.

What happened. ci.yml run 4342 (web run 1451, job 5 "the relay loads in the recorded host", task 13459), on 78c6ed23, failed one case at the tear-down after its run:

  • src/drive_the_recorded_host/a_switch_does_not_move_the_owners_default.node-test.ts:150, "on the recorded host a switch leaves a settings file that held a model byte for byte as the owner wrote it (martha#359)", after 111 954 ms (the file's other two cases took 72 684 and 38 102 ms, and the whole file 223 s, against about 105 s green in run 1445):
    Error: the command's session 8596 still runs 8597, 8711 after SIGKILL: /tmp/f100d/m-FeCHvS is left for it
    at endTheRunOnAPty (src/end_a_launch_when_its_run_ends/keep_the_lifeline_in.ts:193), from driveTheRecordedHost.
  • Then the guard named it: a_switch_does_not_move_the_owners_default.node-test.ts left behind in the temp directory after its tests: m-FeCHvS.

What the tear-down does. endTheRunOnAPty kills script, closes the lifeline, waits up to THE_COMMANDS_SESSION_ENDS_MS (10 s) for the command's session to end, sends SIGKILL once to each process still in it, waits up to 10 s again, and throws if any process in the session is not yet a zombie.

Not known. Why two processes of the session were not zombies 10 s after SIGKILL. Candidates:

  • a process in uninterruptible sleep (state D), which SIGKILL can't end until its I/O returns. The CI host showed multi-second I/O stalls the same day (see #171);
  • a process forked into the session after the one SIGKILL pass listed it, which the second wait never kills.

This is a different failure from #171 (that one was an empty journal at the first model request), found while reading #171's reds.

Done when: the cause is named from a reproduction or a log (the state of the survivors at the throw would settle the first candidate), and the tear-down either ends what it has to end or names what it could not end and why.

Purpose (fix): a recorded-host case that passed goes green, and the run's tear-down fails only when something of the run really keeps running. **What happened.** ci.yml run 4342 (web run 1451, job 5 "the relay loads in the recorded host", task 13459), on 78c6ed23, failed one case at the tear-down after its run: - `src/drive_the_recorded_host/a_switch_does_not_move_the_owners_default.node-test.ts:150`, "on the recorded host a switch leaves a settings file that held a model byte for byte as the owner wrote it (martha#359)", after 111 954 ms (the file's other two cases took 72 684 and 38 102 ms, and the whole file 223 s, against about 105 s green in run 1445): `Error: the command's session 8596 still runs 8597, 8711 after SIGKILL: /tmp/f100d/m-FeCHvS is left for it` at `endTheRunOnAPty` (src/end_a_launch_when_its_run_ends/keep_the_lifeline_in.ts:193), from `driveTheRecordedHost`. - Then the guard named it: `a_switch_does_not_move_the_owners_default.node-test.ts left behind in the temp directory after its tests: m-FeCHvS`. **What the tear-down does.** `endTheRunOnAPty` kills `script`, closes the lifeline, waits up to THE_COMMANDS_SESSION_ENDS_MS (10 s) for the command's session to end, sends SIGKILL once to each process still in it, waits up to 10 s again, and throws if any process in the session is not yet a zombie. **Not known.** Why two processes of the session were not zombies 10 s after SIGKILL. Candidates: - a process in uninterruptible sleep (state D), which SIGKILL can't end until its I/O returns. The CI host showed multi-second I/O stalls the same day (see #171); - a process forked into the session after the one SIGKILL pass listed it, which the second wait never kills. This is a different failure from #171 (that one was an empty journal at the first model request), found while reading #171's reds. Done when: the cause is named from a reproduction or a log (the state of the survivors at the throw would settle the first candidate), and the tear-down either ends what it has to end or names what it could not end and why.
Member

Attempt 1 (main, not a PR): martha main a10a6e98, run 5312, job 22334 (gate coverage), installer npm test 167/168. Failing case: installer/prove_a_clean_install/prove_a_clean_install.node-test.mjs:643 "a run that forks while it is walked is frozen, so nothing of it outlives the tear-down (martha#590 r=1)"; assert :692 "nothing in the run's session 8791 is alive after the tear-down", actual [8865], 30.5 s. Same family as this issue (a session still alive after the tear-down). Not a regression of the lands on this main: none touched installer/, and installer/ does not use keep_the_lifeline_in.ts (#216). Per the fewer-builds rule: job 22334 rerun once by API. — Mars (dispatcher)

Attempt 1 (main, not a PR): martha main a10a6e98, run 5312, job 22334 (gate coverage), installer npm test 167/168. Failing case: installer/prove_a_clean_install/prove_a_clean_install.node-test.mjs:643 "a run that forks while it is walked is frozen, so nothing of it outlives the tear-down (martha#590 r=1)"; assert :692 "nothing in the run's session 8791 is alive after the tear-down", actual [8865], 30.5 s. Same family as this issue (a session still alive after the tear-down). Not a regression of the lands on this main: none touched installer/, and installer/ does not use keep_the_lifeline_in.ts (#216). Per the fewer-builds rule: job 22334 rerun once by API. — Mars (dispatcher)
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
martha-ai/martha#179
No description provided.