app-inspector报错This socket has been ended by the other party
-
Macaca Version: 1.1.2
-
Macaca Doctor: Node.js checklist:
node env: /usr/local/bin/node node version: v4.5.0
iOS checklist:
Xcode is installed at:
/Applications/Xcode.app/Contents/DeveloperXcode Command Line Tools is ready, version: 2343. ios_webkit_debug_proxy is installed at: /usr/local/bin/ios_webkit_debug_proxyAndroid checklist:
JAVA version is
1.8.0_91JAVA_HOME is set to/Library/Java/JavaVirtualMachines/jdk1.8.0_91.jdk/Contents/HomeANDROID_HOME is set to/usr/local/opt/android-sdkPlatforms is set to/usr/local/opt/android-sdk/platforms/android-24Android tools is set to/usr/local/opt/android-sdk/tools/androidInstalled driver list:
android: 1.0.27 chrome: 1.0.2 electron: 1.1.2 ios: 1.0.36
-
Operate System: max os
-
programming Language:
首先启动app-inspector后inspector -u 32c3e283,一切ok
`
inspector start at: http://172.31.216.35:5678 INSTRUMENTATION_STATUS: numtests=1 INSTRUMENTATION_STATUS: stream= com.android.uiautomator.client.Initialize:
INSTRUMENTATION_STATUS: id=UiAutomatorTestRunner INSTRUMENTATION_STATUS: test=testStartServer INSTRUMENTATION_STATUS: class=com.android.uiautomator.client.Initialize INSTRUMENTATION_STATUS: current=1 INSTRUMENTATION_STATUS_CODE: 1 uiautomator start socket server.
socket server ready socket client ready Android device started: 32c3e283
<-- GET / recive: {"cmd":"getSource","args":{}}
return: {"success":true,"data":true}
Dump Android XML success, save to /Users/codetosurvivemac/npm/lib/node_modules/app-inspector/.temp/android.json --> GET / 200 <-- GET / recive: {"cmd":"getSource","args":{}}
return: {"success":true,"data":true}
Dump Android XML success, save to /Users/codetosurvivemac/npm/lib/node_modules/app-inspector/.temp/android.json --> GET / 200 <-- GET /
` 此时我新启动窗口后,跑一个macaca的官方case macaca run -d ../macaca-test-sample/macaca-test/macaca-mobile-sample.test.js --verbose
再重新刷新页面后就报错了,Internal Server Error 后台日志为 ` Error: This socket has been ended by the other party at Socket.writeAfterFIN as write at UIAutomator.initSocketClient.UIAutomator.initSocketServer.UIAutomator.send.cmd as send at next (native) at onFulfilled (/Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:65:19) at /Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:54:5 at Object.co (/Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:50:10) at Object.toPromise (/Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:118:63) at next (/Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:99:29) at onFulfilled (/Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:69:7) at /Users/lixiaojiao/npm/lib/node_modules/app-inspector/node_modules/co/index.js:54:5
<-- GET /favicon.ico --> GET /favicon.ico 404 <-- GET /
Error: This socket has been ended by the other party at Socket.writeAfterFIN as write at UIAutomator.initSocketClient.UIAutomator.initSocketServer.UIAutomator.send.cmd as send at next (native) at onFulfilled (/Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:65:19) at /Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:54:5 at Object.co (/Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:50:10) at Object.toPromise (/Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:118:63) at next (/Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:99:29) at onFulfilled (/Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:69:7) at /Users/codetosurvivemac/npm/lib/node_modules/app-inspector/node_modules/co/index.js:54:5 ` 请问这是bug还是macaca run的时候会占用inspector的端口?
刚换了个端口,重新跑macaca run,也是同样的问题
inspector 和 run 占用的端口不会冲突
@xudafeng 是的 我刚试了 换过端口也会出现这个问题,这是什么原因呢?
@lixiaojiao 请升级最新版
@xudafeng 这个问题又出现了 版本冲掉了吗