react-native run-android总是无法正常运行



  • 在mac上,当执行上面的命令后,就会出现下面的错误

    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: unable to resolve root /Users/HEME/Workspace/app/AP: failed to opendir(/Users/HEME/Workspace/app/AP): No such file or directory. Make sure watchman is running for this project. See https://facebook.github.io/watchman/docs/troubleshooting.html.
     ERROR  unable to resolve root /Users/HEME/Workspace/app/AP: failed to opendir(/Users/HEME/Workspace/app/AP): No such file or directory
    {"watchmanResponse":{"version":"4.7.0","error":"unable to resolve root /Users/HEME/Workspace/app/AP: failed to opendir(/Users/HEME/Workspace/app/AP): No such file or directory"}}
    Error: unable to resolve root /Users/HEME/Workspace/app/AP: failed to opendir(/Users/HEME/Workspace/app/AP): No such file or directory
        at BunserBuf.<anonymous> (/Users/HEME/Workspace/app/AP/node_modules/fb-watchman/index.js:95:23)
        at emitOne (events.js:96:13)
        at BunserBuf.emit (events.js:188:7)
        at BunserBuf.process (/Users/HEME/Workspace/app/AP/node_modules/bser/index.js:289:10)
        at /Users/HEME/Workspace/app/AP/node_modules/bser/index.js:244:12
        at _combinedTickCallback (internal/process/next_tick.js:67:7)
        at process._tickCallback (internal/process/next_tick.js:98:9)
    

    按照说明,也尝试了创建空白的 .watchmanconfig 文件,也init了git,但一直是这个错误,请问该怎么处理?


  • administrators

    没见过这个问题,重装下watchman试试



  • 卸载重装了多次,总是这个问题,所以跑来请教了


登录后回复