-
Notifications
You must be signed in to change notification settings - Fork 24.8k
Closed
Labels
Description
Is this a bug report?
Yes
Have you read the Bugs section of the Contributing to React Native Guide?
Yes
Environment
react-native -v
:
react-native-cli: 2.0.1
react-native: 0.45.1
node -v
:
v8.1.1
npm -v
:
5.0.4
yarn --version
(if you use Yarn):
0.23.2
Then, specify:
- Target Platform (e.g. iOS, Android): Whatever the result of
yarn start
is - Development Operating System (e.g. macOS Sierra, Windows 10): macOS Sierra
- Build tools (Xcode or Android Studio version, iOS or Android SDK version, if relevant): Not relevant
Steps to Reproduce
Perform the first four steps outlined in the Getting Started (https://facebook.github.io/react-native/docs/getting-started.html) guide with a totally fresh React Native project.
npm install -g create-react-native-app
create-react-native-app AwesomeProject
cd AwesomeProject
npm start
Expected Behavior
I thought a dev server would run, or I would see the QR code mentioned in the Getting Started guide. I would expect react-native to be compatible with npm 5.0.4 or give instructions as to how to downgrade (not ideal). I wouldn't expect it to just outright break.
Actual Behavior
➜ /Users/foo/TestApp npm start
> TestApp@0.1.0 start /Users/foo/TestApp
> react-native-scripts start
1:54:47 PM: Starting packager...
***ERROR STARTING PACKAGER***
Error: You are using npm version 5.0.4. Please use an npm version that is >= 3.0.0 and < 5.0.0.
1:54:47 PM: Error starting packager: Error: Couldn't start project. Please fix the errors and restart the project.
at /xdl/src/Project.js:1038:11
at Generator.next (<anonymous>)
at step (/Users/foo/TestApp/node_modules/xdl/build/Project.js:1468:191)
at /Users/foo/TestApp/node_modules/xdl/build/Project.js:1468:361
at <anonymous>
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! TestApp@0.1.0 start: `react-native-scripts start`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the TestApp@0.1.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/foo/.npm/_logs/2017-06-28T20_54_47_593Z-debug.log
Reproducible Demo
Explained above.
ankitpopli1891, rawaludin, maxrugen, indrekj, flosch and 23 more