ci: set cache-mode on release workflows - #205
Draft
claude[bot] wants to merge 1 commit into
Draft
Conversation
Add the workflow-level `cache-mode: none` key so release and docs-publish runs never read from or write to the Actions cache. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MYe3WCXtgiqomNuVQdi4Yd
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.
Requested by David Sanders · Slack thread
Before: The
Releaseworkflow (push tomain) has no cache policy of its own. Theactions/setup-nodestep opts out withpackage-manager-cache: false, but that is a per-step choice; any step, action, or reusable workflow added later could read from or write to the Actions cache during a release run, and nothing in the workflow would stop it.After: The workflow carries a top-level
cache-mode: none, so the runner denies every cache read and write for the whole run regardless of per-step settings. Becauserelease.ymlcallstest.ymlviauses:, thenonecap also applies to those test jobs during release runs (PR runs oftest.ymlare unaffected and keep caching). A step that tries to use the cache logs a message and continues: a skipped restore behaves as a cache miss and a skipped save is a no-op, so the run does not fail.GitHub added the workflow- and job-level
cache-modekey to control Actions cache access (changelog, syntax reference), and release paths should never depend on cache contents.How: Adds
cache-mode: none(with a one-line comment) after the top-levelpermissions:block in.github/workflows/release.yml. No other lines change; the existingpackage-manager-cache: falsesetting stays in place. PR CI does not exercise this workflow, so the first release after merge is the real test. The file parses cleanly and zizmor 1.30.1 accepts the new key; actionlint 1.7.12 does not yet recognisecache-modeat the workflow level (its schema predates the feature), which is worth knowing if actionlint is ever added to CI here.🤖 Generated with Claude Code
https://claude.ai/code/session_01MYe3WCXtgiqomNuVQdi4Yd