Repository navigation
Make docs build independent of network and builder speed - #474
Merged
Merged
Conversation
Read the Docs builds (e.g. for #459) fail intermittently while executing the docs notebooks, unrelated to the PR under review: - tabular-data.ipynb downloads the California housing dataset via fetch_california_housing at build time; a failed or partial download aborts the build. - quick-start.ipynb runs %timeit on resample_iterations with automatic loop counts (17.6 s locally), close to the 60 s nbsphinx cell timeout on slower RTD builders. Generate a synthetic house prices dataset instead of downloading, bound %timeit to one loop per repeat, raise nbsphinx_timeout to 300 s, and block network access in the docs notebooks CI job so a notebook that downloads data fails in CI instead of only on RTD. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MvmKb6kjQzUUXx7GBEvDo4
|
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MvmKb6kjQzUUXx7GBEvDo4
GitHub Actions rejected xskillscore_testing.yml because HTTP_PROXY and http_proxy (and the HTTPS/NO_PROXY pairs) are duplicate keys in a case-insensitive env mapping, so no test jobs ran. Python's urllib and requests honour the uppercase names, so keep only those. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MvmKb6kjQzUUXx7GBEvDo4
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #474 +/- ##
==========================================
+ Coverage 94.78% 94.86% +0.07%
==========================================
Files 27 27
Lines 2973 3016 +43
==========================================
+ Hits 2818 2861 +43
Misses 155 155 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Read the Docs builds keep failing intermittently on unrelated PRs, most recently #459 (Cramér's V). That PR's code is fine: its API page builds cleanly. The failures come from
nbsphinx_execute = "always", which re-runs the docs notebooks on every RTD build, and two of them depend on things outside our control:tabular-data.ipynbdownloads the California housing dataset withfetch_california_housing()at build time. A failed or partial download aborts the whole build. This is thecal_housing.pkzfailure reported on Add Cramer's V contingency metric #459, and I reproduced it locally with network blocked.quick-start.ipynbcell 73 runs%timeitonresample_iterationswith automatic loop counts. It took 17.6 s locally, against a 60 s per-cellnbsphinx_timeout. Add Cramer's V contingency metric #459 also reported a kernel timeout in this notebook. That slower RTD builders push this cell over the limit is an inference; I did not measure on RTD.The GHA "Test notebooks in docs" job stays green because its runners are fast and have stable network, so these failures only ever show up on RTD.
Changes:
tabular-data.ipynb: generate a synthetic house prices dataset locally instead of downloading. The column names (AveRooms,y) and the walkthrough stay the same.quick-start.ipynb:%timeit -n 1 -r 3. The cell now runs in under 1 s (was 17.6 s).docs/source/conf.py:nbsphinx_timeoutraised from 60 to 300 s per cell as headroom. A hanging cell still fails..github/workflows/xskillscore_testing.yml: the docs notebooks job now builds with HTTP(S) routed to a dead proxy, so a notebook that downloads data fails on the PR instead of later, at random, on RTD. intersphinx inventories also fail to load, but that only emits warnings.Type of change
How Has This Been Tested?
Run locally (Python 3.13,
sphinx <9, deps fromci/doc.yml):tabular-data.ipynbfails withURLError: Connection refused, which shows the CI guard catches this.make -j4 htmlwith notebook execution succeeds on this branch.tabular-data.ipynbcell 22 (groupby.apply), at 7.2 s.pre-commit runpasses on all changed files.The RTD build on this PR is the real end-to-end check.
🤖 Generated with Claude Code
https://claude.ai/code/session_01MvmKb6kjQzUUXx7GBEvDo4