ReviewOS

zig-utils/zig-js

CI: watchdog lifecycle subcases independently under TSan

#93
Closed chris opened this 9 days ago ·
9 days ago

Problem

The tsan-threadfuzz-lifecycle job for main commit 94078ba7 failed in run https://github.com/zig-utils/zig-js/actions/runs/29352841839 after the lifecycle seed exceeded the 120-second watchdog.

The lifecycle profile currently arms one timeout across 56 independently reproducible subcases. Under TSan, their aggregate runtime can exceed the watchdog even when no individual case is hung. The forced std.process.exit(124) then makes TSan report already-finished but not-yet-joined JS thread handles as secondary thread leaks.

This is inconsistent with the broad profiles, which already reset the same seed window before each subcase through runWatchedSeedCase.

Scope

  • Run every lifecycle subcase through the existing per-subcase watchdog helper.
  • Keep the seed and profile in timeout diagnostics so every failure remains directly reproducible.
  • Do not weaken or lengthen the 120-second per-case hang detector.

Acceptance criteria

  • Focused lifecycle seed 1 completes under TSan without watchdog termination or TSan warnings.
  • The full tsan-threadfuzz-lifecycle publication job is green.
  • Umbrella publication issues #63 and #71 are updated with the resulting CI evidence.
9 days ago

Implemented and pushed in 1e7298b4.

The lifecycle profile now runs each of its 56 independently reproducible cases through the existing runWatchedSeedCase window. The watchdog remains 120 seconds per case; only the accidental aggregate seed timeout was removed.

Focused validation on the exact failing profile:

THREADFUZZ_SEED_TIMEOUT_MS=120000 zig build threadfuzz -Dtsan=true -Dfuzz-lifecycle=true -Dfuzz-iters=1
threadfuzz lifecycle: 56 programs from seed 1, 0 failures, wall-ms 46784

Fresh publication run: https://github.com/zig-utils/zig-js/actions/runs/29353934622

Leaving this open until the tsan-threadfuzz-lifecycle job and full gate finish green.

9 days ago

Confirmed by the fresh publication job: tsan-threadfuzz-lifecycle passed on 1e7298b4 with 112 programs from seed 1, 0 failures, wall-ms 130263, and no watchdog/TSan diagnostics.

Job: https://github.com/zig-utils/zig-js/actions/runs/29353934622/job/87156822910

All acceptance criteria for this focused CI fix are met.

Sign in to comment on this issue.