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.

[Packager] Packager does not start after upgrading to NPM 3.0 beta

See original GitHub issue

After upgrading to NPM 3.0 beta (https://github.com/npm/npm/releases/tag/v3.0.0), I re-installed the node_modules through npm install in my React Native project. Everything showed up in the file system, but after calling npm start I get the error:

Could not find dependencies.
Ensure dependencies are installed - run 'npm install' from project root.

No matter how often I call npm install and npm start, the error persists. This happens for me with both 0.6.0 and 0.7.0-rc.

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:49 (17 by maintainers)

github_iconTop GitHub Comments

4reactions
jdk89757commented, Dec 24, 2015

PATH: [Your Project]/node_modules/react-native/package/packager.js SOLUTION: add’…/…’ & delete ‘node_modules’, CODE:if (!fs.existsSync(path.resolve(__dirname, ‘…/…’, ‘’))) { console.log( ‘\n’ + path.resolve(__dirname, ‘…/…’, ‘’) + ‘Could not find dependencies.\n’ + 'Ensure dependencies are installed - ’ + ‘run 'npm install' from project root.\n’ ); process.exit(); }

2reactions
jsierlescommented, Jun 28, 2015

This happens because the packager is looking for react-native’s dependencies in its own node_modules directory. In npm 3, all dependencies install flat in the top level node_modules.

https://github.com/facebook/react-native/blob/master/packager/packager.js#L18

I’d love to start using npm3 - will look into a PR.

Read more comments on GitHub >

github_iconTop Results From Across the Web

node.js - npm update does not do anything - Stack Overflow
Now, after updating the versions of your packages in package.json , run npm update and your packages will be updated to the latest...
Read more >
npm-check-updates
Make sure your package file is in version control and all changes have been committed. This will overwrite your package file. $ ncu...
Read more >
HOW TO: Update all npm packages in your project at once
A solution could be to use npm run scripts . We can define a script, let's call it update:packages . This script executes...
Read more >
npm packages in the Package Registry - GitLab Docs
Project-level: Use when you have few npm packages and they are not in the same GitLab group. If you plan to install a...
Read more >
ng serve not working when install latest version of angular cli
Make sure you have the latest version of node.js and npm installed. npm ERR! If you do, this is most likely a problem...
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