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
test: evidence-export descendant kill check can read the process before SIGKILL lands #412
The test kills the ffmpeg process group and settles when a descendant keeps stdout open in packages/core/test/evidence-export.test.ts failed once in a full bun run test:coverage run on a loaded local host:
AssertionError: expected false to be true
❯ packages/core/test/evidence-export.test.ts:633:52
expect(status === "" || status.includes(") Z ")).toBe(true);
The same test passed 5 times in a row when run alone on the same revision.
Likely cause: packages/core/src/evidence-export.ts:312 sends SIGKILL to the process group, and kill returns before the kernel ends the target. The test reads /proc/<pid>/stat of the sleep descendant once, right after the export settles. Under load, the descendant can still show S at that moment.
Found while running the full suite for #317, which does not touch evidence export.
Wait for the descendant to end, for example with expect.poll, instead of one read of /proc/<pid>/stat.
Keep the assertion that the export settles in under 2.5 s.
Activity