Skip to content

ci: fix flaky fast-tier notebook timeout#26

Merged
jonfroehlich merged 2 commits into
masterfrom
fix-fast-tier-nbmake-timeout
Jun 26, 2026
Merged

ci: fix flaky fast-tier notebook timeout#26
jonfroehlich merged 2 commits into
masterfrom
fix-fast-tier-nbmake-timeout

Conversation

@jonfroehlich

@jonfroehlich jonfroehlich commented Jun 24, 2026

Copy link
Copy Markdown
Member

Problem

The Notebook smoke tests (fast tier) job intermittently fails with a per-cell timeout. The culprit is a pre-existing cell in Tutorials/Signals - Frequency Analysis.ipynb: a brute-force "DFT by correlation" demo that sweeps ~5,500 frequencies (1 Hz step) over an 11 kHz audio chord. Its saved runtime is ~2 min even on a fast machine; on a slow/contended GitHub runner it crept past the old 900 s cap and timed out (PR #25's run).

Confirmed flaky: re-running the failed job on un-fixed master passed in 3m24s. The same suite has been observed at ~3 min, ~16 min, and ~32 min purely due to runner variance.

Fix (CI config only — no notebook changes)

  • --nbmake-timeout=900 → 1800 — generous headroom; the ~2 min DFT cell finishes well under 1800 s even on a slow runner. This is the real fix.
  • Kept -n auto (an initial pass tried -n 2, but that cut parallelism and pushed the suite to ~32 min on a slow runner without helping correctness).

Optional follow-up

The underlying cell is genuinely slow. It could be made fast and robust by passing a coarser xcorr_freq_step_size to that one demo (the helper already supports it and other cells use it; at a 0–5.5 kHz axis the plot looks identical). Can do separately if wanted.

🤖 Generated with Claude Code

jonfroehlich and others added 2 commits June 24, 2026 15:56
The fast-tier smoke tests intermittently fail when the Frequency Analysis
tutorial's brute-force "DFT by correlation" demo (a ~2 min O(n^2) sweep over
an 11 kHz audio chord) creeps past the 900 s per-cell cap on a slow/contended
shared runner. Raise --nbmake-timeout to 1800 s and cap xdist at -n 2 so the
CPU-bound cells aren't oversubscribed. No notebook content changes.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
A first pass also dropped xdist to -n 2, but that cut parallelism and pushed
the suite to ~32 min on a slow runner. The 1800 s per-cell timeout is what
actually fixes the flaky failure (the brute-force DFT cell finishes well under
it), so revert to -n auto to keep wall time reasonable.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@jonfroehlich jonfroehlich merged commit 2619f77 into master Jun 26, 2026
2 checks passed
@jonfroehlich jonfroehlich deleted the fix-fast-tier-nbmake-timeout branch June 26, 2026 16:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant