Skip to content

ci: stop setup-node caching in the SwiftPM job - #1260

Merged
Naturalclar merged 1 commit into
masterfrom
fix/spm-job-cache
Nov 22, 2026
Merged

Naturalclar merged 1 commit into
masterfrom
fix/spm-job-cache

Conversation

@Naturalclar

Copy link
Copy Markdown
Member

Problem

Since #1257, the SwiftPM package job fails on every PR that changes yarn.lock (#1251, #1249, #1239). In those runs node scripts/check-spm.mjs passes ("SwiftPM package checks passed."), and the job fails afterwards in setup-node's post step:

##[error]Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved.

actions/setup-node@v5 turns on caching for the package manager named in package.json's packageManager field. This job deliberately skips yarn install, so the Yarn cache folder is never created. When the cache is found nothing gets saved, which is why #1257 itself was green. When yarn.lock changes the cache key misses, setup-node tries to save a folder that doesn't exist, and the job fails.

Fix

Set package-manager-cache: false on that job's setup-node step. The job doesn't use the cache anyway.

Verification

This PR doesn't change yarn.lock, so its own run can't show the failing case. After it merges, @dependabot rebase on #1251 should turn SwiftPM package green.

🤖 Generated with Claude Code

setup-node@v5 caches the packageManager from package.json automatically.
The SwiftPM job never runs `yarn install`, so the Yarn cache folder never
exists. On a cache miss, which happens on any PR that changes yarn.lock,
the post-step save fails with "Path Validation Error" even though
check-spm.mjs passed. Disable the package-manager cache for that job.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Naturalclar
Naturalclar merged commit 33bc567 into master Nov 22, 2026
6 checks passed
@Naturalclar
Naturalclar deleted the fix/spm-job-cache branch November 22, 2026 04:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant