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.

A package.json was not found at /package.json

See original GitHub issue

Hi All,

There is an error when I Launch npm-check and the message is : A package.json was not found at /package.json For more detail, add --debug to the command.

I use the npm install -g npm-check on the website before

Thanks

Issue Analytics

  • State:open
  • Created 7 years ago
  • Comments:7

github_iconTop GitHub Comments

1reaction
reveltcommented, Jul 2, 2017

Guys, this npm-check is normally ran in the root of one of your libraries.

When you run it in the root of your OS, that is ~ as @gielk two comments above, this tool can’t find package.json because it does not exist. Your root folder is not a package’s folder!

@gielk I noticed you are using sudo with your npm commands. It’s not good, you should never need to use sudo. It’s best to uninstall node, install n via Homebrew and you’ll get npm together with it.

0reactions
MHacker9404commented, Aug 8, 2019

I’m getting this error when I run it in my application root folder where package.json is located. I get this error for {app}/src/package.json.

Read more comments on GitHub >

github_iconTop Results From Across the Web

npm can't find package.json - Stack Overflow
if the package.json file is already created in the project directory then there is a possibility that you are not running your project...
Read more >
How to fix the npm can't find package.json error - Reactgo
To fix this error, first you need to initialize the package.json by using the following command. npm init -y. Now, you can install...
Read more >
Cannot find package.json file - DeployHQ
This happens when you have your package.json file located in a subfolder in your repository and not in the root. Build commands start...
Read more >
Creating a package.json file - npm Docs
To create a package.json file with values that you supply, use the npm init command. On the command line, navigate to the root...
Read more >
Fix for error package.json not found in npm install running
Usually, this error comes when npm commands are running and not found package.json in the application root. This error gives after running the...
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