publish_docs: skip notebook execution for tag builds - #1323
Draft
hschilling wants to merge 1 commit into
Draft
hschilling wants to merge 1 commit into
hschilling wants to merge 1 commit into
Conversation
Re-executing notebooks for historical tags is fragile: dependencies shift, test tolerances drift, and examples that were unreviewed at release time (examples_unreviewed/) may fail against newer environments. The committed cell outputs were correct when the tag was cut. Patch _config.yml in-place before building to set execute_notebooks=off so jupyter-book uses committed outputs. The src/ checkout is throwaway so mutating _config.yml is safe. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
hschilling
marked this pull request as draft
September 28, 2026 17:32
Kenneth-T-Moore
approved these changes
Sep 28, 2026
This branch has not been deployed
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.
Problem
workflow_dispatchruns ofpublish_docs.ymlfor historical tags (e.g.v1.0.0) fail during the doc build because_config.ymlsetsexecute_notebooks: force. Notebooks re-execute against today's environment, not the environment at release time, causing failures like:Since the build uses
-W --keep-going, these turn into a non-zero exit and the whole publish fails.Root cause
Re-executing notebooks for a historical tag is inherently fragile: dependencies shift, tolerances drift, and unreviewed examples may have never been stable. The committed cell outputs in the tag were correct when it was cut — those are what we want to publish.
Fix
In the Build docs step for tag builds, patch
_config.ymlin-place before building to setexecute_notebooks: "off". Jupyter Book then renders committed cell outputs instead of re-executing. The./src/checkout is throwaway so mutating_config.ymlis safe.🤖 Generated with Claude Code