Skip to content
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

Increased number of npm ERR! cb() never called! failures #3572

Closed
1 of 7 tasks
desrosj opened this issue Jun 11, 2021 · 6 comments
Closed
1 of 7 tasks

Increased number of npm ERR! cb() never called! failures #3572

desrosj opened this issue Jun 11, 2021 · 6 comments
Assignees
Labels
Area: JavaScript and Node.js Area: Packages investigate Collect additional information, like space on disk, other tool incompatibilities etc. OS: Ubuntu

Comments

@desrosj
Copy link

desrosj commented Jun 11, 2021

Description
On the WordPress/Gutenberg repository, we've been experiencing an increased number of workflows failing due to the following error:

npm ERR! prepareGitDep npm ERR! cb() never called!
npm ERR! prepareGitDep 
npm ERR! prepareGitDep npm ERR! This is an error with npm itself. Please report this error at:
npm ERR! prepareGitDep npm ERR!     <https://npm.community>
npm ERR! prepareGitDep 
npm ERR! prepareGitDep npm ERR! A complete log of this run can be found in:
npm ERR! prepareGitDep npm ERR!     /home/runner/.npm/_logs/2021-06-10T14_22_37_476Z-debug.log
npm ERR! prepareGitDep 
npm ERR! premature close

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/runner/.npm/_logs/2021-06-10T14_22_37_959Z-debug.log

Area for Triage:
JavaScript and Node.js

Question, Bug, or Feature?:
Bug

Virtual environments affected

  • Ubuntu 16.04
  • Ubuntu 18.04
  • Ubuntu 20.04
  • macOS 10.15
  • macOS 11
  • Windows Server 2016 R2
  • Windows Server 2019

Image version

20210606.1

Expected behavior
npm install completes without an error.

Actual behavior
Error listed above is displayed and the job fails.

Repro steps
It has happened on almost all of the workflows in the repository running npm install or npm ci. It is seemingly random, but has only happened on:

  • Jobs using NodeJS 14.
  • Jobs using ubuntu-latest.

We have not encountered the issue on MacOS jobs, or any job that uses NodeJS 12. In most cases, re-running the workflow will succeed, but occasionally a third run is required.

Some examples of this happening:

From what I've been able to find on this error, there are three ways people usually resolve this issue:

  • Running npm cache clean --force.
  • Uninstalling and reinstalling NodeJS.
  • Changing the ulimit for NodeJS.

We've ruled out that any cache being restored from https://github.com/actions/cache is causing the problem (unless there is some type of cache at the system level), as the error has happened when there was no cache restored. Some workflows where that is the case:

I don't think we have the ability to try the other two ways to resolve.

At the direction of GitHub support, I've also posted this to actions/setup-node.

@desrosj
Copy link
Author

desrosj commented Jun 15, 2021

Looks like this error is also happening in other repos. Just had an instance in WordPress/wordpress-develo: https://github.com/WordPress/wordpress-develop/runs/2824875313?check_suite_focus=true.

@al-cheb al-cheb added Area: JavaScript and Node.js OS: Ubuntu investigate Collect additional information, like space on disk, other tool incompatibilities etc. and removed needs triage labels Jun 15, 2021
@al-cheb
Copy link
Contributor

al-cheb commented Jun 15, 2021

Hello, @desrosj.
Thank you for your report. We will take a look.

@nikita-bykov nikita-bykov self-assigned this Jun 17, 2021
@nikita-bykov
Copy link
Contributor

Hello @desrosj.
It looks like this issue is reproducible not only in our CI, but also in the local environment. NPM repository has a lot of opened and closed issues related to npm ERR! cb() never called. Many reasons can lead to this error and they have an article described it.
Considering the fact that issue is reproduced outside of GitHub Actions CI and only with specific version of Node.js, we should report this issue to Node.js team. Not much we can do from our side.

@nikita-bykov
Copy link
Contributor

Hello @desrosj. I'm going to close this issue. If you have any questions feel free to contact us.

@desrosj
Copy link
Author

desrosj commented Jun 30, 2021

Thanks @nikita-bykov. I'll follow up with the NPM team.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: JavaScript and Node.js Area: Packages investigate Collect additional information, like space on disk, other tool incompatibilities etc. OS: Ubuntu
Projects
None yet
Development

No branches or pull requests

3 participants