ci: adopt the notebook SystemExit(0) skip-guard classifier (PyAutoHands#198) - #119
Merged
Merged
Conversation
Adopt PyAutoHands#198 in this repo's copy of `.github/scripts/run_smoke.py`. The optional-dependency skip guard (`sys.exit(0)`) is a clean exit 0 as a `.py` script, but raises SystemExit in a Jupyter kernel, so nbconvert exits non-zero and the notebook smoke entry was reported as a spurious FAIL. `run_notebook` now consults PyAutoHands's `build_util.is_clean_skip_exit` on the combined nbconvert output and records a PASS; `SystemExit: 1` and every other exception stay failures. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PzN9PZfG5zXMVku8ckSqkC
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.
Rolls the PyAutoHands#198 adoption into this repo's
run_smoke.pycopy: notebooks that exit via the optional-dependency skip guard (sys.exit(0)— e.g.searches/mcmc.ipynbwithout blackjax) now PASS instead of erroring the cell, matching the.pysemantics. Two-line change importingbuild_util.is_clean_skip_exit(PyAutoHands is already on PYTHONPATH here); the skip check short-circuits ahead of the regenerate-and-retry path; nonzero exits and real errors still FAIL (verified end-to-end with throwaway pass/fail notebooks through this repo's ownrun_notebook).Note: of the nine run_smoke.py copies, only the three user-facing workspaces (autofit/autolens/autogalaxy) have a notebook leg — sibling PRs land the same change there; the HowTo and
*_testrunners are scripts-only and need nothing.Generated by Claude Code