'npm install' fails for simple example
See original GitHub issueI cannot run the simple example - I get an error from npm install
.
To repro:
- download fresh repo from github
- cd to
examples/simple
- run
npm install
- not the error below (I’ve tried this on a few Macs)
➜ simple git:(master) npm install
npm WARN prepublish-on-install As of npm@5, `prepublish` scripts will run only for `npm publish`.
npm WARN prepublish-on-install (In npm@4 and previous versions, it also runs for `npm install`.)
npm WARN prepublish-on-install See the deprecation note in `npm help scripts` for more information.
> redux-form@6.4.3 prepublish /Users/lowellk/workspace/redux-form
> npm run test && npm run clean && npm run build
> redux-form@6.4.3 test /Users/lowellk/workspace/redux-form
> mocha --compilers js:babel-register --recursive --recursive "src/**/__tests__/*" --require src/__tests__/setup.js
sh: mocha: command not found
npm ERR! Darwin 16.3.0
npm ERR! argv "/usr/local/Cellar/node/7.4.0/bin/node" "/usr/local/bin/npm" "run" "test"
npm ERR! node v7.4.0
npm ERR! npm v4.0.5
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! redux-form@6.4.3 test: `mocha --compilers js:babel-register --recursive --recursive "src/**/__tests__/*" --require src/__tests__/setup.js`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the redux-form@6.4.3 test script 'mocha --compilers js:babel-register --recursive --recursive "src/**/__tests__/*" --require src/__tests__/setup.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the redux-form package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! mocha --compilers js:babel-register --recursive --recursive "src/**/__tests__/*" --require src/__tests__/setup.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs redux-form
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls redux-form
npm ERR! There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! Please include the following file with any support request:
npm ERR! /Users/lowellk/workspace/redux-form/npm-debug.log
npm ERR! addLocal Could not install /Users/lowellk/workspace/redux-form
npm ERR! Darwin 16.3.0
npm ERR! argv "/usr/local/Cellar/node/7.4.0/bin/node" "/usr/local/bin/npm" "install"
npm ERR! node v7.4.0
npm ERR! npm v4.0.5
npm ERR! code ELIFECYCLE
npm ERR! redux-form@6.4.3 prepublish: `npm run test && npm run clean && npm run build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the redux-form@6.4.3 prepublish script 'npm run test && npm run clean && npm run build'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the redux-form package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! npm run test && npm run clean && npm run build
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs redux-form
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls redux-form
npm ERR! There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! Please include the following file with any support request:
npm ERR! /Users/lowellk/workspace/redux-form/examples/simple/npm-debug.log
Also, the following command fails: npm run test && npm run clean && npm run build
> @ test /Users/lowellk/workspace/redux-form/examples/simple
> echo 'Error: no test specified'
Error: no test specified
> @ clean /Users/lowellk/workspace/redux-form/examples/simple
> rimraf dist
sh: rimraf: command not found
npm ERR! Darwin 16.3.0
npm ERR! argv "/usr/local/Cellar/node/7.4.0/bin/node" "/usr/local/bin/npm" "run" "clean"
npm ERR! node v7.4.0
npm ERR! npm v4.0.5
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! @ clean: `rimraf dist`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the @ clean script 'rimraf dist'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! rimraf dist
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls
npm ERR! There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! Please include the following file with any support request:
npm ERR! /Users/lowellk/workspace/redux-form/examples/simple/npm-debug.log
Issue Analytics
- State:
- Created 7 years ago
- Reactions:1
- Comments:8
Top Results From Across the Web
5 Ways to Fix the Npm Install Not Working Issue
Way 1. Make Sure Npm Is Installed · Way 2. Make Sure There Is a Package.json File · Way 3. Delete Lock File...
Read more >Common errors | npm Docs
You are trying to install on a drive that either has no space, or has no permission to write. Free some disk space...
Read more >npm install error from the terminal - Stack Overflow
Running just "npm install" will look for dependencies listed in your package.json. The error you're getting says that you don't have a ...
Read more >NPM install error - Material Design for Bootstrap
Trying to install MDB pro 4.19.2 just downloaded and ran npm install but getting this error of sha512 not matching. Can someone tell...
Read more >How to solve npm ERR! code 1 when running npm install
Fix npm error code 1 by downgrading Node (not recommended) ... The other way to fix the issue is to downgrade your Node.js...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi people,
I had the same problem. After a while, I restarted from scratch and I noticed the documentation says:
"To run this example locally on your machine: 1 - Clone the redux-form repository, then 2 - cd redux-form to change to the repo directory, and 3 - run: npm install.
Then run npm run example:simple or manually run the following commands:
cd ./examples/simple npm install npm start"
I was missing the steps 1,2,3. Best!
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.