Repository navigation
Conversation
The store cache was restored with one lookup that passed both the lockfile prefix and the lockfile-agnostic fallback prefix. GitHub tries every key in the current scope before the default branch's, so an older store in a pull request's scope was restored instead of an entry for the current lockfile on the default branch. Look up the lockfile prefix on its own first, and the fallback prefix only on a miss. Closes #102 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
PR Summary by QodoRestore the current lockfile’s store before trying the fallback
AI Description
Diagram
High-Level Assessment
Files changed (4)
|
[Medium impact] The PR appears safe to merge. Reviews (1) · Last reviewed commit: "fix: look up the current lockfile's stor..." · Reviewed by Greptile |
Closes #102.
Problem
The store cache was restored with a single
restoreCachecall that passed both the lockfile prefix and the lockfile-agnostic fallback prefix. GitHub tries every key in the current scope before it moves on to the default branch. So an older store under the fallback prefix in the pull request's own scope (or its base branch) was restored in preference to an entry for the current lockfile on the default branch. The job then installed the difference and uploaded a duplicate entry.Fix
Restore in two lookups: first with only the lockfile prefix, which searches every accessible scope for the current lockfile, then, only on a miss, with the fallback prefix. The extra request happens only when no entry exists for the lockfile.
getRestoreKeyshad no other caller, so it is removed along with its unit test.Tests
restoreCachewith prefix matching, so the "different lockfile" case is served by the fallback lookup rather than by the first one.🤖 Generated with Claude Code
Summary by CodeRabbit