create-react-app: "create-react-app hello-world" fails on Vagrant Ubuntu 12.04
If you are reporting a bug, please fill in below. Otherwise feel free to remove this template entirely.
Can you reproduce the problem with latest npm?
I am using npm version 4.3.0
Description
I can’t use create-react-app hello-world
on Vagrant Ubuntu . It fails with the error “Aborting installation”, then deletes the files it previously installed.
Actual behavior
root@precise64:/code/React# create-react-app hello-world
Creating a new React app in /code/React/hello-world.
Installing packages. This might take a couple minutes.
Installing react, react-dom, and react-scripts...
npm WARN prefer global marked@0.3.6 should be installed with -g
hello-world@0.1.0 /code/React/hello-world
+-- react@15.4.2
| +-- fbjs@0.8.9
| | +-- core-js@1.2.7
| | +-- isomorphic-fetch@2.2.1
| | | `-- node-fetch@1.6.3
| | | +-- encoding@0.1.12
...
...
| +-- stream-cache@0.0.2
| `-- webpack-dev-middleware@1.10.1
| +-- memory-fs@0.4.1
| `-- mime@1.3.4
+-- webpack-manifest-plugin@1.1.0
`-- whatwg-fetch@2.0.2
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.0.17 (node_modules/react-scripts/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.0.17: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.0.0 (node_modules/chokidar/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.1: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
Aborting installation.
Deleting generated file... node_modules
Deleting generated file... package.json
Deleting hello-world/ from /code/React
Done.
Environment
Run these commands in the project folder and fill in their results:
npm ls react-scripts
(if you haven’t ejected):
/code/React
`-- (empty)
node -v
:6.9.1
npm -v
:4.3.0
Then, specify:
- Operating system: Vagrant virtual machine running Ubuntu 12.04 LTS
- Browser and version: n/a
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 29 (27 by maintainers)
I’ll try the good 'ol remove everything, reboot, reinstall, reboot, try again method and see if that makes any difference.
Thanks a lot for your help, could not have gotten nearly this far w/o you.
Will get back soon.
While I empathize with your problem, those screenshots are beautiful in a way.
Can you try creating an
.env
file in the project root and addingCHOKIDAR_USEPOLLING=true
to it? Then restart the server.Hey, it worked! Not sure if it was the uninstall/reinstall, or having Yarn do the magic. But… here we go.
Unfortunately, now experiencing another weird issue:
I’m running this inside of a Vagrant box. When I edit the file in my Sublime Text editor from my local machine, the development server does not recognize the change, and does not re-load the files. When I use
vim
inside the vagrant machine, everything works as expected.I’m happy to research this on my own or open a new issue. Maybe it’s an easy fix and you can point me in the right direction?