From c2ddb70b9eaadc5833a67ffe0d1b9893e4e476db Mon Sep 17 00:00:00 2001 From: Jon Froehlich Date: Wed, 24 Jun 2026 15:56:23 -0700 Subject: [PATCH 1/2] ci: give the fast notebook tier more headroom (fix flaky timeout) 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 --- .github/workflows/ci.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ae38656..499a257 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -46,5 +46,14 @@ jobs: # nbmake executes each notebook in its own directory, so the repo-relative # data loads (./Logs, data/audio/...) resolve. Intentional error cells are # tagged `raises-exception` in the notebooks and are honored automatically. + # + # Notes on the flags: + # --nbmake-timeout=1800 The Frequency Analysis tutorial has a brute-force + # "DFT by correlation" demo over an 11 kHz audio chord (~2 min even on a + # fast machine). On a slow/contended shared runner it can creep past the + # old 900 s cap, so we give it generous headroom. + # -n 2 Cap xdist at two workers. Oversubscribing a shared runner makes the + # CPU-bound DFT cells slower (closer to the timeout), so we trade a little + # parallelism for reliability. - name: Execute fast notebooks (Tutorials + StepTracker) - run: pytest --nbmake --nbmake-timeout=900 -n auto Tutorials/ Projects/StepTracker/ + run: pytest --nbmake --nbmake-timeout=1800 -n 2 Tutorials/ Projects/StepTracker/ From 7d4d20c6879086b04dea9980431d3b04478ea676 Mon Sep 17 00:00:00 2001 From: Jon Froehlich Date: Wed, 24 Jun 2026 16:30:39 -0700 Subject: [PATCH 2/2] ci: keep -n auto for the fast tier (timeout bump is the real fix) 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 --- .github/workflows/ci.yml | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 499a257..7664f23 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -47,13 +47,11 @@ jobs: # data loads (./Logs, data/audio/...) resolve. Intentional error cells are # tagged `raises-exception` in the notebooks and are honored automatically. # - # Notes on the flags: - # --nbmake-timeout=1800 The Frequency Analysis tutorial has a brute-force - # "DFT by correlation" demo over an 11 kHz audio chord (~2 min even on a - # fast machine). On a slow/contended shared runner it can creep past the - # old 900 s cap, so we give it generous headroom. - # -n 2 Cap xdist at two workers. Oversubscribing a shared runner makes the - # CPU-bound DFT cells slower (closer to the timeout), so we trade a little - # parallelism for reliability. + # --nbmake-timeout=1800: the Frequency Analysis tutorial has a brute-force + # "DFT by correlation" demo over an 11 kHz audio chord (~2 min even on a fast + # machine). Shared runners vary a lot (this suite has run anywhere from ~3 to + # ~16 min), and on a slow one that cell crept past the old 900 s cap. 1800 s + # gives generous headroom; -n auto keeps the suite parallel so wall time stays + # reasonable. - name: Execute fast notebooks (Tutorials + StepTracker) - run: pytest --nbmake --nbmake-timeout=1800 -n 2 Tutorials/ Projects/StepTracker/ + run: pytest --nbmake --nbmake-timeout=1800 -n auto Tutorials/ Projects/StepTracker/