Watchman crawl failed. Retrying once with node crawler

后端 未结 5 2356
时光说笑
时光说笑 2021-02-14 23:06

Watchman crawl failed. Retrying once with node crawler. Usually this happens when watchman isn\'t running. Create an empty .watchmanconfig file i

相关标签:
5条回答
  • 2021-02-14 23:24

    I had a real issue with this one but finally found the answer.

    Here's a screenshot of the post that helped me.

    https://github.com/facebook/watchman/issues/751#issuecomment-542300670

    The whole forum has multiple different solutions which I hadn't actually tried, but this one is the solution that worked for me! Hope this helps.

    0 讨论(0)
  • 2021-02-14 23:36

    As Jodie suggested above I tried the below and it worked well, for the benefit of others mentioning below steps which I tried in my mac to fix this issue

    1. First, Kill all the server running and close your terminal.
    2. Go to 'System preferences' -> 'Security & Privacy' -> privacy tab
    3. Scroll down and click 'Full Disk Access'
    4. Make sure you checked on 'Terminal' and 'Watchman'.
    5. Now relaunch terminal and simply try running again it works!!
    0 讨论(0)
  • 2021-02-14 23:38

    Use sudo command to run watchman.

    sudo npm run test
    

    This problem arose because you might be running watchman as root.

    0 讨论(0)
  • 2021-02-14 23:43

    You're running watchman as root but the state dir, which may contain trigger definitions and thus allow spawning arbitrary commands, is not owned by root. This is a security issue and thus watchman is refusing to start.

    The safest way to resolve this is to remove the state dir by running:

    rm -rf /usr/local/var/run/watchman/root-state

    I'd recommend that you avoid running tools that wish to use watchman using sudo to avoid this happening again.

    0 讨论(0)
  • 2021-02-14 23:50

    I solved this, on linux by using the following commands on terminal.

    $ echo 256 | sudo tee -a /proc/sys/fs/inotify/max_user_instances
    
    $ echo 32768 | sudo tee -a /proc/sys/fs/inotify/max_queued_events
    
    $ echo 65536 | sudo tee -a /proc/sys/fs/inotify/max_user_watches
    
    $ pkill node
    

    Then:

    $ npm start
    

    or

    $ expo start (if you are using expo)
    
    0 讨论(0)
提交回复
热议问题