Repository navigation
site-build: the image in the execution cache's key; comments re-wrapped - #85
Merged
Merged
Conversation
The follow-up the review of #84 asked for. A site's cache was keyed on the file its environment hashes and its extra_packages, not on the image, so a new image kept the key and its pages were not executed again (dp's cache had the same gap). The key now also carries a hash of the image's own /etc/quantecon-container, which names the image and its build time. The images are built only when their Dockerfiles change (QuantEcon/actions' build-containers.yml has no schedule), so a new hash means a new image, not a rebuild of the same one. A leg whose image lacks the file fails with an error rather than building with an incomplete key. Every site's next build is cold once. Also: site-build.yml's comment lines that #84 left past the wrap width are re-wrapped, as is one line of _base/environment-update.yml's header; _base/README.md says the series were brought to the baseline, and their --upgrade lines removed, by 2026-11-20 (and that plotly-orca can leave the list in a pull request of its own); sites/README.md gives the new key. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WT8bMacV9Lmy1VLUc6XJoL
There was a problem hiding this comment.
🟢 Approval recommended
There are no active review issues blocking approval of the image-aware site execution cache changes.
No open issues 🎉
What changed in this PR
This follow-up to #84 makes site execution caches sensitive to container image changes, so updated images trigger fresh page execution.
Changes:
- Add a hash of
/etc/quantecon-containerto cache keys and restore prefixes; fail if the image record is missing or empty. - Document the new cache behavior and completed upstream environment alignment.
- Rewrap workflow and environment comments without changing package pins.
| File | Description |
|---|---|
sites/README.md |
Document image-aware cache keys and remaining invalidation limits. |
.github/workflows/site-build.yml |
Validate and hash the image record for cache keys; update and rewrap comments. |
_base/README.md |
Record completed baseline alignment and defer plotly-orca removal. |
_base/environment-update.yml |
Rewrap header comments; leave package pins unchanged. |
Review effort: Balanced (adaptive)
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.
What
The follow-up the review of #84 asked for (the organiser's reviewer, 2026-11-22).
.github/workflows/site-build.ymljb1-<key>-<tag><env hash>-<packages hash>-<image hash>-<run>, the image hash being the first 16 hex digits of the SHA-256 of the image's/etc/quantecon-container(its name and build time), printed in the step's log; a leg whose image lacks that file fails with an error; the header comments say so, and the lines #84 left past the wrap width are re-wrapped_base/environment-update.yml_base/README.md--upgradelines removed, by 2026-11-20;plotly-orcacan leave the list in a pull request of its ownsites/README.mdWhy the image belongs in the key. Until now a site's cache was keyed on the file its environment hashes and on its
extra_packages, not on the image. A new image kept the key, so its pages were not executed again (dp's cache had the same gap, noted in the comments). QuantEcon/actions builds the images only when their Dockerfiles change:build-containers.ymlhas no schedule, since both Dockerfiles pin their base by digest. So a newbuild_datemeans a new image, and the key changes only when the environment does. The last such change was QuantEcon/actions#346 on 2026-11-19, which added Chrome.Cost. Every site's next build is cold once, intro's and dp's included: about 10 and 30 minutes on
ubuntu-latest.Checks
tools/tests: 329 passed, 1 skipped.site-build.ymlor_base/environment-update.ymlruns past 80 columns.🤖 Generated with Claude Code
https://claude.ai/code/session_01WT8bMacV9Lmy1VLUc6XJoL