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.

create-react-app failing

See original GitHub issue

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?

Many errors, especially related to “missing modules”, are due to npm bugs.

If you’re using Windows, follow these instructions to update npm.

If you’re using OS X or Linux, run this to update npm:

npm install -g npm@latest

cd your_project_directory
rm -rf node_modules
npm install

Then try to reproduce the issue again.

Can you still reproduce it? Yes

Description

I am trying to use create-react-app to create a react app using command create-react-app work. My OS is Windows 7 64 bit, npm version is 4.5.0, node version is v7.8.0, I tried with earlier npm and node versions as well and still unable to use create-react-app

What are you reporting?

Expected behavior

The command above should be able to create react app. Tell us what you think should happen.

Actual behavior

Tell us what actually happens. It aborts with following messages. npm WARN prefer global marked@0.3.6 should be installed with -g 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”:“win32”,“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”:“win32”,“arch”:“x64”}) Aborting installation. npm install --save --save-exact react react-dom react-scripts has failed.

Deleting generated file… node_modules Deleting generated file… package.json Deleting work/ from C:\anil\business Done.

Environment

Windows 7 64 bit Run these commands in the project folder and fill in their results:

  1. npm ls react-scripts (if you haven’t ejected): C:\anil\business `-- (empty)

  2. node -v: v7.8.0

  3. npm -v: 4.5.0

Then, specify:

  1. Operating system: Windows
  2. Browser and version: NA

Reproducible Demo

Please take the time to create a new app that reproduces the issue.

Alternatively, you could copy your app that experiences the problem and start removing things until you’re left with the minimal reproducible demo.

(Accidentally, you might get to the root of your problem during that process.)

log.txt

Push to GitHub and paste the link here.

By doing this, you’re helping the Create React App contributors a big time! Demonstrable issues gets fixed faster.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:29 (13 by maintainers)

github_iconTop GitHub Comments

2reactions
gaearoncommented, Jun 30, 2017

npm 5.x is very buggy at this moment. Please revert to npm 4.x in the meantime.

1reaction
guru9commented, Dec 29, 2017

G:\GURU\WORK-BENCH\PROJECTS\ReactJS>create-react-app --version 1.4.3

G:\GURU\WORK-BENCH\PROJECTS\ReactJS>create-react-app my-app

-----------------------------------what is going on here ==unsolved==---------------------------

Creating a new React app in G:\GURU\WORK-BENCH\PROJECTS\ReactJS\my-app.

Installing packages. This might take a couple of minutes. Installing react, react-dom, and react-scripts…

npm ERR! Unexpected end of JSON input while parsing near ‘…lugin-flowtype","dist’

npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\Bharat Moger\AppData\Roaming\npm-cache_logs\2017-12-29T10_13_00_967Z-debug.log

Aborting installation. npm install --save --save-exact --loglevel error react react-dom react-scripts has failed.

Deleting generated file… package.json Deleting my-app / from G:\GURU\WORK-BENCH\PROJECTS\ReactJS Done.

Read more comments on GitHub >

github_iconTop Results From Across the Web

create-react-app Failing to create a new ... - Stack Overflow
This is due to the network issues try to download all dependency one by one or try to clean cache "npm cache clean...
Read more >
npx create-react-app is not working · Issue #10132 - GitHub
First, you'll need to uninstall "create-react-app" using the "npm uninstall -g create-react-app" command. Run "npx create-react-app my-app" each ...
Read more >
npx create-react-app not working? Here's the solution.
The current solution is simple — run create-react-app and target the latest version. Run creact-react-app using the latest version. npx create- ...
Read more >
What To Do if create-react-app Doesn't Work
1. npm uninstall -g create-react-app. This is the npm command to uninstall your global installation of create-react-app .
Read more >
create-react-app: command not found (React) error [Solved]
Use `npx` to solve the error create-react-app: command not found, e.g. `npx create-react-app my-app` or install the package globally by running `npm install ......
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