Skip to content
This repository has been archived by the owner on Aug 11, 2022. It is now read-only.

cb() never called #19228

Open
5 of 13 tasks
evolkmann opened this issue Nov 23, 2017 · 11 comments
Open
5 of 13 tasks

cb() never called #19228

evolkmann opened this issue Nov 23, 2017 · 11 comments
Labels

Comments

@evolkmann
Copy link

evolkmann commented Nov 23, 2017

I'm opening this issue because:

  • npm is crashing.
  • npm is doing something I don't understand.
  • npm is producing an incorrect install.
  • Other (see below for feature requests):

What's going wrong?

Error-Log: https://gist.github.com/evolkmann/d2bc075b82422e604ca60a02b8c5f31c

NPM Config: https://gist.github.com/evolkmann/19b73980177d92f01422fe8c7ca2534c

  • npm install stops at loadAllDepsIntoIdealTree
  • Error cb() never called
  • The error occurs not everytime and not in all repos

How can the CLI team reproduce the problem?

  • Create npm environment according to the attached config
  • For example, run npm install -g gulp
  • Watch the error occur

supporting information:

  • npm -v prints: 5.5.1
  • node -v prints: v8.9.1
  • npm config get registry prints: https://registry.npmjs.org/
  • Windows, OS X/macOS, or Linux?: Microsoft Windows 7 Enterprise (6.1.7601 Service Pack 1 Build 7601)
  • Network issues:
    • Geographic location where npm was run:
    • I use a proxy to connect to the npm registry.
    • I use a proxy to connect to the web.
    • I use a proxy when downloading Git repos.
    • I access the npm registry via a VPN
    • I don't use a proxy, but have limited or unreliable internet access.
  • Container:
    • I develop using Vagrant on Windows.
    • I develop using Vagrant on OS X or Linux.
    • I develop / deploy using Docker.
    • I deploy to a PaaS (Triton, Heroku).
@kenany kenany added the npm5 label Nov 23, 2017
@dpz3579
Copy link

dpz3579 commented Nov 24, 2017

hi ..

run

npm cache verify

to see how much cache npm holds.

then try

npm cache clean

if required run with --force.

this should clear your cache, and you can install your packages again..

worked for me node - 8.9.1 & npm -5.4.2

@evolkmann
Copy link
Author

Hi @dpz3579,
Running npm cache verify resulted in

Cache verified and compressed (~\AppData\Roaming\npm-cache\_cacache):
Content verified: 3068 (148544512 bytes)
Content garbage-collected: 483 (19096481 bytes)
Index entries: 4708
Finished in 26.635s

After npm cache clean --force:

Cache verified and compressed (~\AppData\Roaming\npm-cache\_cacache):
Content verified: 0 (0 bytes)
Index entries: 0
Finished in 0.031s

Unfortunately, the issue is still there.

@dpz3579
Copy link

dpz3579 commented Nov 24, 2017

try downgrading npm to 5.4.2
use command npm install -g npm@5.4.2

don't use sudo.

@evolkmann
Copy link
Author

λ npm install -g npm@5.4.2
npm ERR! cb() never called!

npm ERR! This is an error with npm itself. Please report this error at:
npm ERR!     <https://github.com/npm/npm/issues>

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\volkende\AppData\Roaming\npm-cache\_logs\2017-11-24T06_53_03_272Z-debug.log

@dpz3579
Copy link

dpz3579 commented Nov 24, 2017

can you send me the log file

@evolkmann
Copy link
Author

0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli   'C:\\Users\\volkende\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli   'install',
1 verbose cli   '-g',
1 verbose cli   'npm@5.4.2' ]
2 info using npm@5.5.1
3 info using node@v8.9.1
4 verbose npm-session ab2395f26d0cadb2
5 silly install loadCurrentTree
6 silly install readGlobalPackageData
7 error cb() never called!
8 error This is an error with npm itself. Please report this error at:
9 error <https://github.com/npm/npm/issues>

Basically the same as above

@Butterfly
Copy link

I'm looking at that one path there:

1 verbose cli 'C:\Users\volkende\AppData\Roaming\npm\node_modules\npm\bin\npm-cli.js',

Is that how it's supposed to look?

Mine that is possibly comparable is:

/usr/lib/node_modules/npm/bin

As I halfway expected, mine's holding npm-cli.js within that last bin child directory.

I fully understand that ALL of our user instances are going to vary k/t our personal needs, e.g. distributions, how global installs go, etc. It just seems like there would still be some level of consistency. What feels inconsistent to me here may actually be 100% fine and functional at that specific point.

Right now the affected npm-cli.js above feels awfully buried. Maybe when it reaches back up the food chain for something, it's not finding that something relative to where its deeper buried search is beginning?

But and again... that may be how that was supposed to go with that very specific install usage case. 😄

@jcrben
Copy link
Contributor

jcrben commented Nov 25, 2017

Looks like a duplicate of #16904 - I saw this on a list of known npm5 issues #16991 (comment)

@komkumar
Copy link

komkumar commented Jul 11, 2018

Installed node on Win 7(Enterprise) 64bit [https://nodejs.org/en/download/]
installed angular using command : npm install -g @angular/cli

node -v
v8.11.1

npm -v
6.1.0

ng -v
Angular CLI: 6.0.8
Node: 8.11.1
OS: win32 x64
Angular:
...

Package Version

@angular-devkit/architect 0.6.8
@angular-devkit/core 0.6.8
@angular-devkit/schematics 0.6.8
@schematics/angular 0.6.8
@schematics/update 0.6.8
rxjs 6.2.1
typescript 2.7.2

Now, while creating a new project using "ng new projname" (location D drive)., it gives the following error:

D:\Aj>ng new third
CREATE third/angular.json (3539 bytes)
CREATE third/package.json (1309 bytes)
CREATE third/README.md (1022 bytes)
CREATE third/tsconfig.json (384 bytes)
CREATE third/tslint.json (2805 bytes)
CREATE third/.editorconfig (245 bytes)
CREATE third/.gitignore (503 bytes)
CREATE third/src/environments/environment.prod.ts (51 bytes)
CREATE third/src/environments/environment.ts (631 bytes)
CREATE third/src/favicon.ico (5430 bytes)
CREATE third/src/index.html (292 bytes)
CREATE third/src/main.ts (370 bytes)
CREATE third/src/polyfills.ts (3194 bytes)
CREATE third/src/test.ts (642 bytes)
CREATE third/src/assets/.gitkeep (0 bytes)
CREATE third/src/styles.css (80 bytes)
CREATE third/src/browserslist (375 bytes)
CREATE third/src/karma.conf.js (964 bytes)
CREATE third/src/tsconfig.app.json (194 bytes)
CREATE third/src/tsconfig.spec.json (282 bytes)
CREATE third/src/tslint.json (314 bytes)
CREATE third/src/app/app.module.ts (314 bytes)
CREATE third/src/app/app.component.html (1141 bytes)
CREATE third/src/app/app.component.spec.ts (988 bytes)
CREATE third/src/app/app.component.ts (207 bytes)
CREATE third/src/app/app.component.css (0 bytes)
CREATE third/e2e/protractor.conf.js (752 bytes)
CREATE third/e2e/src/app.e2e-spec.ts (301 bytes)
CREATE third/e2e/src/app.po.ts (208 bytes)
CREATE third/e2e/tsconfig.e2e.json (213 bytes)
npm WARN deprecated istanbul-lib-hook@1.2.1: 1.2.0 should have been a major vers
ion bump
npm ERR! cb() never called!

npm ERR! This is an error with npm itself. Please report this error at:
npm ERR! https://github.com/npm/npm/issues

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\komkumar\AppData\Roaming\npm-cache_logs\2018-07-10T06_39_
39_241Z-debug.log
Package install failed, see above.

Tried clearing cache, and running the command again. doesn't work.
Tried the following steps, but didn't work:

  1. deleting npm , npm-cache folders from C:\Users\Username\AppData\Roaming
    2)uninstall node js
  2. reboot
    4)install again
  3. reboot
  4. run command "npm install -g @angular/cli"
  5. reboot
  6. run command "ng new firstproj" gives the same error. "cb() never called".

Is there any solution for this?

@DanielRuf
Copy link

@komkumar please create a new issue.

@komkumar
Copy link

@DanielRuf Created. Issue #21200

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

7 participants