Error npm WARN unmet dependency in nodejs

0 votes

I have a node package. When I run npm install from the package root, it installs a bunch of things, but then prints several error messages that look like this:

npm WARN unmet dependency /Users/seanmackesey/google_drive/code/explore/generator/node_modules/findup-sync/node_modules/glob requires graceful-fs@'~1.2.0' but will load

I must be confused about what exactly npm install does. If it detects a dependency, shouldn't it install it? Under what conditions does it give me error messages like this, and how can I resolve the dependencies?

Jul 12, 2020 in Node-js by kartik
• 37,530 points
1,702 views

1 answer to this question.

0 votes

Hii @kartik,

Following are the possible solution :

  1. Manually need to install the top-level modules, containing unmet dependencies: npm install findup-sync@0.1.2

  2. Re-structure your package.json. Place all the high-level modules (serves as a dependency for others modules) at the bottom.

  3. Re-run the npm install command.

The problem could be caused by npm's failure to download all the package due to timed-out or something else.

Note: You can also install the failed packages manually as well using npm install findup-sync@0.1.2.

Before running npm install, performing the following steps may help:

  • remove node_modules using rm -rf node_modules/
  • run npm cache clean
Hope it helps!!
Thank You!!
answered Jul 12, 2020 by Niroj
• 82,880 points

Related Questions In Node-js

0 votes
1 answer

Error:npm WARN package.json: No repository field

Hello @kartik, It's just a check as of NPM ...READ MORE

answered Jul 20, 2020 in Node-js by Niroj
• 82,880 points
2,016 views
0 votes
1 answer

Error:Failed to parse json-This is not a bug in npm.

Hello @kartik, Try this: npm cache clean Hope it works!! Thank ...READ MORE

answered Nov 27, 2020 in Node-js by Niroj
• 82,880 points
619 views
0 votes
1 answer

Error:npm throws error without sudo

Hello @kartik, This looks like a permissions issue ...READ MORE

answered Jul 8, 2020 in Node-js by Niroj
• 82,880 points
364 views
–1 vote
1 answer

How to uninstall npm modules in node js?

Hello @kartik, The command is simply: npm uninstall ...READ MORE

answered Jul 8, 2020 in Node-js by Niroj
• 82,880 points
1,607 views
0 votes
1 answer

jQuery AJAX fires error callback on window unload - how do I filter out unload and only catch real errors?

Hello, In the error callback or $.ajax you have three ...READ MORE

answered Apr 27, 2020 in Java-Script by Niroj
• 82,880 points
2,025 views
0 votes
1 answer

How do I pass command line arguments to a Node.js program?

Hello @kartik, If your script is called myScript.js ...READ MORE

answered May 5, 2020 in Java-Script by Niroj
• 82,880 points
1,613 views
0 votes
1 answer

Error:Issue when trying to use IN() in wordpress database

Hello @kartik, Try this code : // Create an ...READ MORE

answered May 8, 2020 in PHP by Niroj
• 82,880 points
242 views
+2 votes
1 answer

How do I debug Node.js applications?

Hello @kartik, Use node-inspector  from any browser supporting WebSocket. Breakpoints, ...READ MORE

answered Jul 8, 2020 in Node-js by Niroj
• 82,880 points
254 views
0 votes
2 answers

Error:npm UNMET PEER DEPENDENCY warning

Finding the compatible versions of related packages ...READ MORE

answered Aug 13, 2020 in Node-js by anonymous
• 140 points
3,667 views
0 votes
1 answer

Error:npm WARN package.json: No repository field

Hello @kartik, If you are getting this from ...READ MORE

answered Jul 9, 2020 in Node-js by Niroj
• 82,880 points
2,783 views