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

Watchman crawl failed. After MacOS Catalina Update #751

Closed
t-castanho opened this issue Oct 10, 2019 · 22 comments
Closed

Watchman crawl failed. After MacOS Catalina Update #751

t-castanho opened this issue Oct 10, 2019 · 22 comments

Comments

@t-castanho
Copy link

After the MacOS update and zsh terminal change i can't run my app with npm start even with a watchman blank file. I'm getting this error:

jest-haste-map:` Watchman crawl failed. Retrying once with node crawler.
  Usually this happens when watchman isn't running. Create an empty `.watchmanconfig` file 
in your project's root folder or initialize a git or hg repository in your project.
  Error: Watchman error: resolve_projpath: path `(mypath)`: open: (mypath): Operation 
not permitted. Make sure watchman is running for this project. 
See https://facebook.github.io/watchman/docs/troubleshooting.html.

Should i downgrade? Or there is any fix for this?

@rocketaero
Copy link

I had the same problem. I moved the entire project directory outside of the Documents directory and it solved the problem. Appears to be something related to the new permissions catalina requires for access to the Documents directory.

@t-castanho
Copy link
Author

Where do you paste your project? I’ve my project in the desktop directory. Can we remove the permissions?

@rocketaero
Copy link

I think the Desktop has similar problems as Documents, I moved mine to my root user directory
( /Users/{myuser} ) and it worked.

@nickwelp
Copy link

nickwelp commented Oct 14, 2019

To change the permissions for Watchman regarding the Documents folder, it's under Security & Privacy -> files & folders in the system preferences

@peachsky1
Copy link

peachsky1 commented Oct 15, 2019

Guys. I spent hours to figure this out. I found a solution.
If you still face this problem after you re-install node, watchman and expo cli etc, You gotta try this simple step. Trust me. Its all bcuz of catalina grant access to folders permission.

First, Kill all the server running and close your terminal.
Go to 'System preference' -> 'Security & Privacy' -> scroll down and click 'Full Disk Access' -> Make sure you checked on 'Terminal' and 'Watchman'. Save and restart ur laptop.

You are welcome.

@SaravanakumarSubramanian

@jaeseonglee1008 Worked for me!! kudos man!!

@IgorUsoltsev
Copy link

I think the Desktop has similar problems as Documents, I moved mine to my root user directory
( /Users/{myuser} ) and it worked.

this one solved it for me.

Tried all the stuff from "Full disk access" to reinstall, chmod etc. But moving project under {user} folder solved all the issues. Damn Catalina's new security rules. Spent few days on that.

@webhaoying
Copy link

To change the permissions for Watchman regarding the Documents folder, it's under Security & Privacy -> files & folders in the system preferences

thanks ,fixed

@grangerjs
Copy link

Guys. I spent hours to figure this out. I found a solution.
If you still face this problem after you re-install node, watchman and expo cli etc, You gotta try this simple step. Trust me. Its all bcuz of catalina grant access to folders permission.

First, Kill all the server running and close your terminal.
Go to 'System preference' -> 'Security & Privacy' -> scroll down and click 'Full Disk Access' -> Make sure you checked on 'Terminal' and 'Watchman'. Save and restart ur laptop.

You are welcome.

This was it. THANK YOU.

@lalidiaz
Copy link

To change the permissions for Watchman regarding the Documents folder, it's under Security & Privacy -> files & folders in the system preferences

Thank you so much :)

@rplotkin
Copy link

Guys. I spent hours to figure this out. I found a solution.
If you still face this problem after you re-install node, watchman and expo cli etc, You gotta try this simple step. Trust me. Its all bcuz of catalina grant access to folders permission.

First, Kill all the server running and close your terminal.
Go to 'System preference' -> 'Security & Privacy' -> scroll down and click 'Full Disk Access' -> Make sure you checked on 'Terminal' and 'Watchman'. Save and restart ur laptop.

You are welcome.

This was it. Thank you!

@ismailkhan4
Copy link

How to change fix the issue in Ubuntu? :(

@nikhilthakur001
Copy link

nikhilthakur001 commented May 31, 2022

I think the Desktop has similar problems as Documents, I moved mine to my root user directory
( /Users/{myuser} ) and it worked.

this one solved it for me.

Tried all the stuff from "Full disk access" to reinstall, chmod etc. But moving project under {user} folder solved all the issues. Damn Catalina's new security rules. Spent few days on that.

Same, this only solved my problem, but there must be a better solution. I manage all my projects in Documents/projects. It would not be possible to move all my react-native projects to /User/{myuser}.

@DavidPhilip
Copy link

@nikhilthakur001 What actually solved this for me was that I needed to run watchman shutdown-server after doing all of the above. When I fired it up again I got the OS's disk-access permission dialog which I confirmed and everything started to work as expected.

@nikhilthakur001
Copy link

@nikhilthakur001 What actually solved this for me was that I needed to run watchman shutdown-server after doing all of the above. When I fired it up again I got the OS's disk-access permission dialog which I confirmed and everything started to work as expected.

Okay, I will try this and revert you back soon.

@Dinesh456
Copy link

I had the same issue and this is worked for me.

@ourmaninamsterdam
Copy link

Only way I could resolve this was to move my project out of ~/Documents and into ~/

@himanshuzeptonow
Copy link

I think the Desktop has similar problems as Documents, I moved mine to my root user directory ( /Users/{myuser} ) and it worked.

Worked for me as well

@shubhamRai12
Copy link

I think the Desktop has similar problems as Documents, I moved mine to my root user directory
( /Users/{myuser} ) and it worked.

this one solved it for me.
Tried all the stuff from "Full disk access" to reinstall, chmod etc. But moving project under {user} folder solved all the issues. Damn Catalina's new security rules. Spent few days on that.

Same, this only solved my problem, but there must be a better solution. I manage all my projects in Documents/projects. It would not be possible to move all my react-native projects to /User/{myuser}.

Worked for me also. Thanks.

@ui-code
Copy link

ui-code commented Nov 25, 2022

I'm using Mac with Apple M1 chip.
As of today, 25th Nov 2022, none of the above worked for me, until I came across this post:

https://www.spinellis.gr/blog/20211127/

According to which, we need to add path of homebrew within project's build phases, so that watchman is picked up while xcode archives the project:
export PATH="$PATH:/opt/homebrew/bin"

image

@shahzeb8285
Copy link

Guys. I spent hours to figure this out. I found a solution. If you still face this problem after you re-install node, watchman and expo cli etc, You gotta try this simple step. Trust me. Its all bcuz of catalina grant access to folders permission.

First, Kill all the server running and close your terminal. Go to 'System preference' -> 'Security & Privacy' -> scroll down and click 'Full Disk Access' -> Make sure you checked on 'Terminal' and 'Watchman'. Save and restart ur laptop.

You are welcome.

worked for me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests