While working on Find&Save‘s Cash Dash Inbox feature which is built using React Native I started the node packager and launched the app into SIM but got this error as soon as the app attempted to load the bundle:
TypeError: Cannot read property 'root' of null
Turns out the issue was an outdated watchman. Ok so off to brew update
stevet:iPhoneGeo strefethen$ brew update Error: undefined method `link_overwrite' for #<Class:0x007fdb697392d0>
Doh! Looks like I ran into a “hole not many people should fall into“. Anyhoo, as suggested let’s try that again:
stevet:iPhoneGeo strefethen$ brew update Already up-to-date. stevet:iPhoneGeo strefethen$ brew upgrade watchman ==> Upgrading 1 outdated package, with result: watchman 3.7.0 ==> Upgrading watchman ==> Downloading https://homebrew.bintray.com/bottles/watchman-3.7.0.yosemite.bottl ######################################################################## 100.0% ==> Pouring watchman-3.7.0.yosemite.bottle.tar.gz 🍺 /usr/local/Cellar/watchman/3.7.0: 9 files, 240K
Whala now the packager is happy again. Btw, another Engineer on my team had this same problem and her machine required a reboot before things started working again.