question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`ERR undefined` with v3.0.1 when running on Windows 10

See original GitHub issue

From @kirlat:

Thanks @nathanhleung for providing a fix! v3.0.1, still does not work for me, but the output is different this time.

I’m using install-peerdeps with npx on Win10, and here is how I’m running it: npx install-peerdeps alpheios-node-build --dev --only-peers and the output in my case is ERR undefined.

That’s different from v3.0.0 where the output is ERR spawn npm ENOENT so things have changed since then.

If I run it as npx install-peerdeps@v2.0.2 alpheios-node-build --dev --only-peers it works without a hitch.

My node version is 14.8.0 and npm is 6.14.7.

I will try to test it in different scenarios (maybe installed locally) to get more info on this. Not sure what’s the best way to diagnose the issue.

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:1
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
kirlatcommented, Jan 29, 2021

I’ve checked the logs and the problem seems to be that the package whose dependencies to be installed, alpheios-node-build, is not in the npm registry. It is installed locally (i.e. exist in ./node_modules/alpheios-node_build) and this seems to cause the issue:

0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli   'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli   'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli   'info',
1 verbose cli   'alpheios-node-build@latest',
1 verbose cli   '--json'
1 verbose cli ]
2 info using npm@6.14.7
3 info using node@v14.8.0
4 verbose npm-session d488d407d2f19391
5 http fetch GET 404 https://registry.npmjs.org/alpheios-node-build 339ms
6 verbose stack Error: 404 Not Found - GET https://registry.npmjs.org/alpheios-node-build - Not found
6 verbose stack     at C:\Program Files\nodejs\node_modules\npm\node_modules\npm-registry-fetch\check-response.js:114:15
6 verbose stack     at processTicksAndRejections (internal/process/task_queues.js:93:5)
7 verbose statusCode 404
8 verbose pkgid alpheios-node-build@latest
9 verbose cwd C:\uds\projects\alpheios\alpheios-core
10 verbose Windows_NT 10.0.19042
11 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "info" "alpheios-node-build@latest" "--json"
12 verbose node v14.8.0
13 verbose npm  v6.14.7
14 error code E404
15 error 404 'alpheios-node-build' is not in the npm registry.
15 error 404 You should bug the author to publish it
15 error 404 (or use the name yourself!)
15 error 404
15 error 404 Note that you can also install from a
15 error 404 tarball, folder, http url, or git url.
16 error 404
17 error 404 'alpheios-node-build@latest' is not in the npm registry.
18 error 404 You should bug the author to publish it (or use the name yourself!)
19 error 404 Note that you can also install from a
20 error 404 tarball, folder, http url, or git url.
21 verbose exit [ 1, true ]

This, however works with v2.0.2, npx install-peerdeps@v2.0.2 alpheios-node-build --dev --only-peers gets the dependencies installed.

Another thing I’ve noticed. If to remove the package whose dependencies need to be installed (i.e. alpheios-node-build) and run v2.0.2 (npx install-peerdeps@v2.0.2 alpheios-node-build --dev --only-peers) it recognizes the fact that the package is missing and provides the relevant error message: ERR That package doesn't exist. Did you mean to specify a custom registry?

v3.0.3, however, just prints ERR undefined in this case.

If to run v3.0…3 against the package that IS in the registry (npx install-peerdeps eslint-config-airbnb --dev --only-peers ), it works fine.

So probably something was changed around how locally installed packages are handled.

1reaction
karlhorkycommented, Jan 29, 2021
Read more comments on GitHub >

github_iconTop Results From Across the Web

ERR: undefined when installing eslint-config-airbnb · Issue #150
When running npx install-peerdeps --dev eslint-config-airbnb I get the following error: install-peerdeps v3.0.3 Installing peerdeps for ...
Read more >
How to Fix “Script Error” An Error Has Occurred In ... - YouTube
How to Fix “Script Error ” An Error Has Occurred In The Script On This Page In Windows 11/ 10 PC. 105K views...
Read more >
Cannot read property 'resolve' of undefined when using npm ...
Run npm cache clean --force · Go to the control panel --> Programs --> Programs and Features · Scroll down, Uninstall Node.js and...
Read more >
List of Error Codes that you may receive when you try to make ...
Lists all the Error Codes that you may receive when you try to make a dial-up connection or a VPN connection in Windows...
Read more >
Uncaught Error: Call to undefined function mysql_connect() in
I installed php 7.2 and have since gotten this error: PHP Fatal error: Uncaught Error: Call to undefined function mysql_connect() in ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found