Repository navigation
Cache pinned Corepack package managers separately - #12
Merged
Merged
Conversation
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.
Summary
I added a separate cache for pinned pnpm and Yarn executables. In PwrGit's Windows job, the dependency store restored successfully, but Corepack failed downloading pnpm itself. With a warm Corepack cache, activation can reuse that executable.
I restore an action-managed COREPACK_HOME before activation and save it immediately after successful preparation, before dependency installation. The key includes OS, architecture, and the full manager version including any integrity hash, independently of the lockfile and dependency cache suffix. Activation and version verification still run. Mutable selectors remain uncached, and lookup-only dependency hits still skip Corepack setup.
Validation
Compatibility controls
I added default-on
cache-corepack, withcache-corepack: "false"as an opt-out. I preserve a caller-supplied nonemptyCOREPACK_HOMEand skip action-managed Corepack restore/save for that directory. Homes exported by previous invocations in the same job remain action-managed. Activation and dependency caching keep their existing behavior.I ran all 97 local tests successfully, including execution of the inline resolver with opt-out/custom-home environments and repeated-invocation helper coverage. Cross-platform CI is rerunning for commit
3552259. The earlier offline harness and real PwrGit cold/warm runs validatedf5895f6, before these compatibility controls.