美文网首页
Error: ENOENT: no such file or d

Error: ENOENT: no such file or d

作者: DuffyMagic | 来源:发表于2019-10-09 17:12 被阅读0次

    问题:app-inspector之前一直是好的,忽然抽风一直挂掉提示Internal Server Error,用macaca doctor检查环境也是好的,就是报错
    报错日志:

    server.js:16:12 [master] pid:24652 server start with config:
    {
    port: 5678,
    verbose: true,
    udid: '25ff8f554eec8da683a00f0310291573f313a72f',
    ip: '172.16.48.223',
    host: 'wangruideMacBook-Pro-2.local',
    loaded_time: '2019-09-19 13:20:48'
    }
    app-inspector.js:45:12 [master] pid:24652 server start at: http://172.16.48.223:5678
    xctest-client.js:56:14 [master] pid:24652 project path: /usr/local/homebrew/lib/node_modules/app-inspector/node_modules/xctestwd/XCTestWD/XCTestWD.xcodeproj
    xctest-client.js:283:14 [master] pid:24652 xcode version: 10.3
    XCTestWD version: 1.4.18
    xctest-client.js:309:14 [master] pid:24652 Fail to start xctest: Error: ENOENT: no such file or directory, scandir '/usr/local/homebrew/lib/node_modules/app-inspector/node_modules/xctestwd/XCTestWD/build/Build/Products'
    Error: ENOENT: no such file or directory, scandir '/usr/local/homebrew/lib/node_modules/app-inspector/node_modules/xctestwd/XCTestWD/build/Build/Products'
    at Object.readdirSync (fs.js:795:3)
    at /usr/local/homebrew/lib/node_modules/app-inspector/node_modules/xctestwd/lib/xctest-client.js:189:26
    at new Promise ()
    at XCTest.startBootstrap (/usr/local/homebrew/lib/node_modules/app-inspector/node_modules/xctestwd/lib/xctest-client.js:182:12)
    at startBootstrap.next ()
    at onFulfilled (/usr/local/homebrew/lib/node_modules/app-inspector/node_modules/co/index.js:65:19)
    at /usr/local/homebrew/lib/node_modules/app-inspector/node_modules/co/index.js:54:5
    at new Promise ()
    at co (/usr/local/homebrew/lib/node_modules/app-inspector/node_modules/co/index.js:50:10)
    at toPromise (/usr/local/homebrew/lib/node_modules/app-inspector/node_modules/co/index.js:118:63) {
    errno: -2,
    syscall: 'scandir',
    code: 'ENOENT',
    path: '/usr/local/homebrew/lib/node_modules/app-inspector/node_modules/xctestwd/XCTestWD/build/Build/Products'
    }
    iOS device started: 25ff8f554eec8da683a00f0310291573f313a72f
    inspector start at: http://172.16.48.223:5678
    <-- GET /
    helper.js:94:16 [master] pid:24652 xctest client proxy error with: Error: connect ECONNREFUSED 127.0.0.1:8001

    Error: connect ECONNREFUSED 127.0.0.1:8001
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1056:14)

    分析:就是缺少Build/Products,试了很多方法包括重装都一直报错,以为是xcode的bug

    解决:直接在这个路径手动增加缺少的目录,/usr/local/homebrew/lib/node_modules/app-inspector/node_modules/xctestwd/XCTestWD/build/Build/Products,新建Build,在Build里新建Products,就解决啦

    相关文章

      网友评论

          本文标题:Error: ENOENT: no such file or d

          本文链接:https://www.haomeiwen.com/subject/yoeructx.html