Repository navigation
Conversation
The test is killed at the 60 s per-test deadline on Fast test (arm_darwin). It was added by ClickHouse#112913, so this is a regression from that PR. The interrupted-rerun probe keeps its sub-probe inside the probe directory, and the stub client waits for a "go" sentinel file by polling, 600 iterations of 0.05 s. The driver's `wait "$int_pid"` returns as soon as the run.sh shell dies from the SIGTERM, but the stub is a grandchild and is never waited for, so the following `rm -rf` deletes the sentinel the live stub is still polling for. It is created and destroyed inside one poll gap, so the stub never sees it, spins to its 30 s cap and outlives the test. That happens once per row, 12 times per run, each orphan burning 600 sleep spawns. Replace both file-sentinel poll loops with blocking bounded reads on FIFOs. A FIFO write reaches the blocked reader immediately and does not depend on the file still existing when the reader next looks, so the teardown can no longer strand anybody. Removing the polling rather than making it cheaper is what makes the spawn count deterministic. `echo go` stays after `kill -TERM` so the signal still lands inside the rerun. Both reads keep a 60 s timeout with `|| true`, and both FIFO ends are held open read-write before the child starts so neither side sees a spurious EOF. Measured locally, 3 runs per arm: orphans surviving the test 11-12 to 0, sleep spawns 1888-3686 to 0, total execve 2897-4863 (non-deterministic) to 1189 (identical on every run). Over 50 consecutive runs: reference clean 50/50, 0 orphans, 0 sleep spawns. The .reference file is unchanged, so every assertion is bit-identical, and the payload oracle still reddens when "${CASE_ARGS[@]}" is dropped from a driver's rerun line. The wall-clock gain on a 96-core Linux box is small, 5.4 s to 4.9 s, because the spin is absorbed there. No Darwin runner was available, so the arm_darwin improvement is unmeasured locally. The timeout was not raised and the test was not skipped. Only bash 3.2 constructs are used, since arm_darwin is the target runner.
Internal second-model review (1 finding, adjudicated)Reviewed cold by a second model against the frozen PR description, then adjudicated against the
DISAGREE on attribution, on three measurements:
The new shape also makes a declined wait strictly less likely: a write into a FIFO held open So this is a pre-existing gap in a row the change neither touches nor weakens, and the proposed 💡 My own notes (no change): this becomes the first Session id: cron:clickhouse-review-slot-8:20260808-194200 |
Pre-PR validation gate (click to expand)
Session id: cron:clickhouse-impl-slot-7:20260808-174300 |
|
cc @CheSema, could you review this? The interrupted-rerun probe in this test waited on a sentinel file that its own |
|
Workflow [PR], commit [3c73f6c] Summary: ❌
AI ReviewSummaryThis PR converts the interrupted-rerun probe in Missing context / blind spots
Final Verdict✅ No actionable findings. |
CI finish ledger - 3c73f6cCI is fully finished on this head: 175 check-runs, 0 queued/in progress,
Session id: cron:our-pr-ci-monitor:20260809-023000 |
|
Closing as obsolete: the arm_darwin timeout was fixed by #114005, which moved the stub-client replay into |
Related: #112913
Related: #110202
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
...
Description
03008_deduplication_diagnostics_opt_inis killed at the 60 s per-test deadline onFast test (arm_darwin). No open issue tracks it; @alexey-milovidov asked me to fix it in#110202 (comment). The test was added by
my own #112913, so this is a regression I introduced, not a pre-existing flake.
Root cause. The interrupted-rerun probe keeps its sub-probe inside the probe directory, and the stub
client waits for a
gosentinel file by polling (600 iterations of 0.05 s). The driver'swait "$int_pid"returns as soon as therun.shshell dies from the SIGTERM, but the stub is agrandchild and is never waited for, so the following
rm -rfdeletes the sentinel the live stub isstill polling for. It is created and destroyed inside one poll gap, so the stub never sees it, spins
to its cap and is left behind. That happens once per row, 12 times per run, each orphan burning 600
sleepspawns over 30 s.This replaces both file-sentinel poll loops with blocking bounded reads on FIFOs, keeping
echo goafter
kill -TERMso the signal still lands inside the rerun. A FIFO write reaches the blockedreader immediately, so the teardown can no longer strand anybody.
Measured locally, 3 runs each: orphans surviving the test 11-12 to 0,
sleepspawns 1888-3686 to 0,total
execve2897-4863 (non-deterministic) to 1189 (identical every run). Over 50 runs: referenceclean 50/50, 0 orphans, 0
sleepspawns..referenceis unchanged and the mutation arm stillreddens.
The wall-clock gain here is small (5.4 s to 4.9 s) because 96 cores absorb the spin. I have no
Darwin runner, so the arm_darwin improvement is unmeasured from here and CI on this PR is the real
measurement. I did not raise the timeout or skip the test.