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: std::__1::system_error: open: /Users/xuyuanbei/Downloads/AwesomeProject: Operation not permitted. Make sure watchman is running for this project. See https://facebook.github.io/watchman/docs/troubleshooting.
RN項(xiàng)目文件下npm start 或者yarn ios 或者?react-native start 啟動(dòng)失敗捣郊,終端報(bào)上面的錯(cuò),然后手機(jī)或者模擬器的報(bào)錯(cuò)是
Could not connect to development server或者No bundle URL present?
開發(fā)環(huán)境是MacOs: 12.0.1 Monterey (M1) 不知道是不是M1的問題
解決方案就是更改項(xiàng)目目錄的地址移稳,把項(xiàng)目目錄放到用戶目錄下面跟Downloads(下載)瓮具,Documents(文稿)這些目錄平級(jí)
這個(gè)問題在watchman的github上有issue地址是
https://github.com/facebook/watchman/issues/977