-
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
bug: wrong node version installed when cache is corrupt #541
Comments
Hello @ben-styling. Thank you for your report. Could you please provide simple steps to reproduce the issue or debug logs ? Which version of runner do you use ? |
Hi @dmitry-shibanov, thank you for your reply! I'm very sorry, but I don't know how to replicate the issue we're having without manually putting the wrong binary in the wrong cache directory. There are not reproduction steps, but while working on a PR for this, I ran the action on a self-hosted runner to install v16.16.0 I'm not sure what you mean when asking which version of runner we use. I know that our runners are x64 linux, but I think once the cache is corrupt, the behaviour is the same on all platforms. I think these are the logs you're asking for, let me know if not!
|
Could you please confirm that the version was installed in the wrong directory ? It is an expected behaviour if you put binaries of node16 to node14 directory that it will use node14 binaries and the action won't throw an error. The If I understand correctly the initial issue is that node16 was pre-cached to wrong directory by the action. |
I can confirm that node14 was installed in a node16 directory. Yes, the initial issue is that node14 was somehow cached to the wrong directory. |
Hello @ben-styling. I've tried to reproduce the issue but everything works as expected. Could you please provide yaml in which the issue was caused ? |
Hello @ben-styling, just a gentle ping. |
Hi there, apologies for my delayed response. Thank you again for looking into this issue! Here's what the yaml looked like initially
We then updated Then 12 days ago (July 8th) the same yaml file (the one above, but with node-version: 16.15.1) was giving us node 14.16.1 We have since updated our yaml to the following:
This didn't fix the issue, but in nvmrc we just increased the node version to 16.16.0 As this runner is used on several projects across multiple teams, I can't be sure if it was this action that caused a version of node to be placed in the wrong directory. I'm suggesting that this action should check the version of node after a cached version is found and try at least once to correct the cache. edit: A colleague of mine has suggested that a runner that's running out of disk space, or a network error could have caused this to happen. I'm struggling to recreate those conditions, though. |
Hi @dmitry-shibanov, thank you again for your help with this. After speaking with @vsafonkin, I no longer think this issue is within scope of this project. This is likely an external issue. Closing this issue. |
Bumps [prettier](https://github.com/prettier/prettier) from 3.0.2 to 3.0.3. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](prettier/prettier@3.0.2...3.0.3) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Description:
I'm unsure of the cause, but somehow a version of node has been cached in the wrong directory.
The only way to fix this problem is to delete the cache manually if you have access to the runner.
Action version:
v3
Platform:
Runner type:
Tools version:
Requesting v16.15.1 gave v14.16.1 (requested cache path was correct, but the version of node inside was wrong)
Repro steps:
I do not know how to reproduce this with normal usage, but to test on a self hosted runner, install a version of node into the wrong directory.
Expected behavior:
A version of node requested should be installed
Actual behavior:
A corrupted cached version is provided
The text was updated successfully, but these errors were encountered: