Watcher took too long time to load(NodeWatcher) - React Native
Asked Answered
S

3

7

I am trying to run already built application in my mobile. When i start the app with "react-native start" code, it returns the following error message after some time

ERROR  Watcher took too long to load (NodeWatcher)
Error: Watcher took too long to load (NodeWatcher)
at Timeout._onTimeout (index.js:99:16)
at ontimeout (timers.js:386:14)
at tryOnTimeout (timers.js:250:5)
at Timer.listOnTimeout (timers.js:214:5)

I am using Windows 7 (32 Bit). I dont find any "Watchman" release for windows 7 32bit system. Because of this issue, i got the following error after installing my app in mobile

Reference Error: Can't find varaible: __fbBatchedBridge

Edit: now i have upgrade my system to windows8 with 64bit. But still i was not able to install the watchman.

Shrum answered 14/7, 2017 at 11:18 Comment(4)
What version of react-native and watchman are you using? I think I have your problem resolved, I just need to confirm versions.Incongruity
what is your watchman version?Sibyl
Is the React Native project director a git repository? how you installed watchman?Sibyl
I have downloaded it from here. facebook.github.io/watchman/docs/install.html. It said there is no release for windows 7 32bit system, So i havent installed watchmanShrum
S
2

You can try to edit a file from react-native packager

node_modules\react-native\packager\react-packager\src\FileWatcher\index.js

Change the line 17 MAX_WAIT_TIME to 60000.

More here

Scottscotti answered 21/7, 2017 at 7:32 Comment(3)
my node_modules\react-native\packager\react-packager\src folder doesnt have FileWatcher. Could you please tell me how to include it?Shrum
@Shrum This is why I asked for the version you're using. This is likely the problem, but the solution will depend on what you are using.Incongruity
@KyleRichardson I have downloaded it from here. facebook.github.io/watchman/docs/install.htmlShrum
C
1

i just want to help you so i think you need to re-install your watchman because I've also had problems with my wachman and the solution I re-install and my program goes back

i hope this answer can help you :)

Cohbert answered 20/7, 2017 at 18:46 Comment(1)
I have used this link facebook.github.io/watchman/docs/install.html to download watchman. its not working. Its still showing error.Shrum
A
1

Changing this passed my test on window

node_modules\react-native\packager\react-packager\src\FileWatcher\index.js line 17 MAX_WAIT_TIME to 50000 or higher 

May be this can help you

Apocope answered 21/7, 2017 at 7:10 Comment(1)
my node_modules\react-native\packager\react-packager\src folder doesnt have FileWatcher. Could you please tell me how to include it?Shrum

© 2022 - 2024 — McMap. All rights reserved.