-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Path Validation Error: Path(s) specified in the action for caching does not exist #1137
Comments
Hi @yashsway 👋, |
We're seeing this too for the first time today on yarn berry projects with |
Unexpectedly getting the same with a project with a yarn v1 lockfile and |
Hi Team,
This is my github action:-
Runner: Github Hosted We are installing the required dependencies too , and this issue started to occur few days back. |
Hello @yashsway The error "Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved" occurs because the caching action cannot find the specified paths. This typically happens when the necessary directories or files do not exist at the time the caching action is executed. Explanation and Steps to Resolve: Ensure Dependencies are Installed Before Caching: Updated workflow: env:
By ensuring that the dependencies are installed before the caching step, you can avoid the path validation error and successfully cache the pnpm dependencies. If you are experiencing the same issue with a project that uses a Yarn v1 lockfile and the I hope this helps! Please let us know if you have any further concerns or questions. |
Sorry @mahalakshmi-rekadi but it doesn't make any sense to me. What is the purpose of cache then? If we need to install the packages before activating cache, well, then cache is useless. |
Hello @javiertury , |
@mahalakshmi-rekadi, some issues are still not clear to me.
Suppose that I run your proposed workflow (first install, then setup node with cache for pnpm). Does it mean that next time I run that workflow, the install step will read from cache? Or does it imply that I have to manually edit the action and move the installation step to the end in order to read from the cache? The last case would be very inconvenient, specially if the cache is purged or expired and I have to setup everything manually again every so often.
|
Can anyone suggest on this, in our case we are even installing the dependencies, and the failure is only for few of them and not all. |
Hello @yashsway, Please let us know if the above resolved with the above work around or still have further concerns. |
Description:
Getting a strange error in the "Post setup node.js" step in my GitHub workflow. I ran the workflow with debugging enabled and this step fails with this error:
Action version:
v3 as
uses: actions/setup-node@v3
Platform:
ubuntu-latest
)Runner type:
Tools version:
pnpm
("packageManager": "[email protected]"
inpackage.json
at the root of my monorepo)Repro steps:
This is my GitHub action.
Expected behavior:
Not really sure what is actually supposed to happen here.
Actual behavior:
With debugging enabled, this is the full trace for the step:
0s
##[debug]Evaluating condition for step: 'Post setup node.js'
##[debug]Evaluating: success()
##[debug]Evaluating success:
##[debug]=> true
##[debug]Result: true
##[debug]Starting: Post setup node.js
##[debug]Loading inputs
##[debug]Evaluating: (((github.server_url == 'https://github.com') && github.token) || '')
##[debug]Evaluating Or:
##[debug]..Evaluating And:
##[debug]....Evaluating Equal:
##[debug]......Evaluating Index:
##[debug]........Evaluating github:
##[debug]........=> Object
##[debug]........Evaluating String:
##[debug]........=> 'server_url'
##[debug]......=> 'https://github.com'
##[debug]......Evaluating String:
##[debug]......=> 'https://github.com'
##[debug]....=> true
##[debug]....Evaluating Index:
##[debug]......Evaluating github:
##[debug]......=> Object
##[debug]......Evaluating String:
##[debug]......=> 'token'
##[debug]....=> ''
##[debug]..=> ''
##[debug]=> ''
##[debug]Expanded: ((('https://github.com' == 'https://github.com') && '') || '')
##[debug]Result: '***'
##[debug]Loading env
Post job cleanup.
##[debug]Checking zstd --quiet --version
##[debug]1.5.6
##[debug]zstd version: 1.5.6
##[debug]implicitDescendants 'false'
##[debug]followSymbolicLinks 'true'
##[debug]implicitDescendants 'false'
##[debug]omitBrokenSymbolicLinks 'true'
##[debug]Search path '/home/runner/setup-pnpm/node_modules/.bin/store/v3'
##[debug]Cache Paths:
##[debug][]
Error: Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved.
##[debug]Node Action run completed with exit code 1
##[debug]Finishing: Post setup node.js
The text was updated successfully, but these errors were encountered: