Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New app "react-native start" return error without "sudo" #14631

Closed
mnlbox opened this issue Jun 20, 2017 · 10 comments
Closed

New app "react-native start" return error without "sudo" #14631

mnlbox opened this issue Jun 20, 2017 · 10 comments
Labels
Resolution: Locked This issue was locked by the bot.

Comments

@mnlbox
Copy link

mnlbox commented Jun 20, 2017

Description

Later I can't init project without sudo until I saw this issue and run sudo chmod 777 /home/xxxxx/.babel.json, now I can init project without sudo (like react-native init AppName) but when I create a simple project (just a project init) and try running this by react-native start it's return bellow message:

Loading dependency graph...(node:13642) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: EACCES: permission denied, open '/tmp/haste-map-react-native-packager-1-c06bcb90a866fe5fba0c98b29c4752c1'

When I use sudo react-native start it's working well. Why it's need sudo? How we can fix it?

Reproduction Steps

Create new project with:

react-native init TestApp

Change to this project directory:

cd TestApp

Try start app:

react-native start

Sample Code

Just simple hello world.

Solution

Run with sudo

Additional Information

  • React Native version: 0.45.1
  • Platform: both
  • Development Operating System: Linux
  • Build tools: React V. 16.0.0-alpha.12
@hramos
Copy link
Contributor

hramos commented Jun 20, 2017

You shouldn't need to use sudo. Can you provide more details about your OS, which steps did you follow to set up your dev environment?

@mnlbox
Copy link
Author

mnlbox commented Jun 20, 2017

@hramos I used https://facebook.github.io/react-native/docs/getting-started.html and install react native CLI.

npm install -g react-native-cli

Use OpenJDK
and other steps based on above tutorial.
My OS is Linux Mint 18.1.

@hramos
Copy link
Contributor

hramos commented Jun 20, 2017

Did you install watchman?

@mnlbox
Copy link
Author

mnlbox commented Jun 21, 2017

@hramos No because docs said that it's optional.

@hramos
Copy link
Contributor

hramos commented Jun 21, 2017

Please give that a try. It's less straightforward to install on Linux so it was marked as optional, but there may be certain situations where the tooling assumes watchman is installed.

@mnlbox
Copy link
Author

mnlbox commented Jun 22, 2017

I don't understand so why it's working well with sudo? 🤔

@mnlbox
Copy link
Author

mnlbox commented Jul 8, 2017

Any suggestion about this?

@hramos hramos added the Icebox label Sep 21, 2017
@hramos
Copy link
Contributor

hramos commented Sep 21, 2017

Hi there! This issue is being closed because it has been inactive for a while. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. Either way, we're automatically closing issues after a period of inactivity. Please do not take it personally!

If you think this issue should definitely remain open, please let us know. The following information is helpful when it comes to determining if the issue should be re-opened:

  • Does the issue still reproduce on the latest release candidate? Post a comment with the version you tested.
  • If so, is there any information missing from the bug report? Post a comment with all the information required by the issue template.
  • Is there a pull request that addresses this issue? Post a comment with the PR number so we can follow up.

If you would like to work on a patch to fix the issue, contributions are very welcome! Read through the contribution guide, and feel free to hop into #react-native if you need help planning your contribution.

@hramos hramos closed this as completed Sep 21, 2017
@simplenotezy
Copy link

simplenotezy commented Oct 12, 2017

I receive the error:

 Watchman:  watchman --no-pretty get-sockname returned with exit code=1, signal=null, stderr= 2017-10-12T20:19:24,539: [2552390464] opendir(/usr/local/var/run/watchman/simplenotezy-state): Permission denied

@vishnumohan89
Copy link

After installing watchman, my issue got fixed

@facebook facebook locked as resolved and limited conversation to collaborators Sep 21, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Sep 21, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

5 participants