If you're an Expo or React Native developer and Metro suddenly can't resolve modules after a macOS reboot (or upgrade), watchman's stale state is likely the cause.
After rebooting (or upgrading) macOS, Metro fails with:
Unable to resolve module ./node_modules/expo-router/entry
…even though the file exists on disk. Other variants include failure to resolve any node_modules path.
The error typically surfaces as a red screen in the simulator or a bundler failure in the terminal. Nothing in your code changed.
Metro uses watchman for fast filesystem lookups. Watchman maintains an in-memory + on-disk state of which directories it's watching and their file trees.
After a macOS reboot or major upgrade, watchman's state can become stale or invalid. When Metro asks watchman to resolve files, watchman may:
- Re-watch from the wrong root — e.g. a parent monorepo directory instead of your app directory
- Apply stale ignore rules — a
.watchmanconfighigher in the tree may haveignore_dirsthat exclude yournode_modules - Have a corrupted file map — the prior file tree snapshot no longer matches reality
The result: Metro's fileSystemLookup can't find modules that clearly exist on disk. The error message is misleading because it implies a missing file, not a broken filesystem index.
If your repo has a .watchmanconfig at the root with ignore_dirs entries like:
{ "ignore_dirs": ["app/node_modules"] }…and watchman decides to watch from the root instead of from app/, then your app's entire node_modules becomes invisible to Metro.
# Nuke all watchman watches
watchman watch-del-all
# Re-enter your app directory and re-establish the watch
cd /path/to/your/app
watchman watch .Then restart Metro:
npx expo start --clear
# or
npx react-native start --reset-cacheThe typical developer response to "it broke after I restarted my Mac" is to nuke node_modules, reinstall, clear caches, even delete ios/ and regenerate — all of which can incidentally fix the watchman state as a side effect. The root cause never gets identified.
If you're on Expo SDK 55+ with a monorepo-like layout (or any workspace structure with nested node_modules), and things mysteriously break after a reboot, try watchman watch-del-all first before the full nuclear reinstall.
- macOS 26.4.1 (Tahoe)
- watchman 2026.03.30.00
- Expo SDK 55 / React Native 0.83
- Metro via
expo run:ios - Monorepo with
.watchmanconfigat the repo root