macaca icon indicating copy to clipboard operation
macaca copied to clipboard

proxy.js:63:22 [master] pid:19958 xctest client proxy error with: Error: connect ECONNREFUSED 127.0.0.1:8001

Open spa221 opened this issue 7 years ago • 21 comments

您好,目前有一个问题困扰了我很久了,一直没有解决,求指导

macaca-ios的版本是2.0.25

运行demo(https://github.com/macaca-sample/sample-nodejs)的时候一直报错

运行demo执行的命令是:npm run test:ios

报错信息如下:

xctest-client.js:230:20 [master] pid:19958 please check project: /Users/duke/Documents/testmacaca/sample-nodejs/node_modules/xctestwd/XCTestWD/XCTestWD.xcodeproj proxy.js:63:22 [master] pid:19958 xctest client proxy error with: Error: connect ECONNREFUSED 127.0.0.1:8001

spa221 avatar May 04 '19 07:05 spa221

This is the translated issue:


proxy.js:63:22 [master] pid:19958 xctest client proxy error with: Error: connect ECONNREFUSED 127.0.0.1:8001

Hello, there is a problem that has been bothering me for a long time, and I have not solved it. I ask for guidance.

The version of macaca-ios is 2.0.25

I always get an error when running demo (https://github.com/macaca-sample/sample-nodejs)

The command to run the demo is: npm run test: ios

The error message is as follows:

xctest-client.js:230:20 [master] pid:19958 please check project: /Users/duke/Documents/testmacaca/sample-nodejs/node_modules/xctestwd/XCTestWD/XCTestWD.xcodeproj proxy.js:63:22 [master] pid:19958 xctest client proxy error with: Error: connect ECONNREFUSED 127.0.0.1:8001

macaca-bot avatar May 04 '19 07:05 macaca-bot

@spa221 看样子是网络问题, 运行 xcode功能,看能否提供更多 log信息。 /Users/duke/Documents/testmacaca/sample-nodejs/node_modules/xctestwd/XCTestWD/XCTestWD.xcodeproj

xudafeng avatar May 04 '19 09:05 xudafeng

This is the translated issue comment: @xudafeng


@spa221 It seems that it is a network problem. Run the xcode function to see if you can provide more log information. /Users/duke/Documents/testmacaca/sample-nodejs/node_modules/xctestwd/XCTestWD/XCTestWD.xcodeproj

macaca-bot avatar May 04 '19 09:05 macaca-bot

@spa221 看样子是网络问题, 运行 xcode功能,看能否提供更多 log信息。 /Users/duke/Documents/testmacaca/sample-nodejs/node_modules/xctestwd/XCTestWD/XCTestWD.xcodeproj

目前直接使用命令启动 xcodebuild -project XCTestWD.xcodeproj
-scheme XCTestWDUITests
-destination 'platform=iOS Simulator,name=iPhone 6'
XCTESTWD_PORT=8001
clean test

显示如下 2019-05-04 21:54:35.015913+0800 XCTestWDUITests-Runner[21541:345025] initializing wd server 2019-05-04 21:54:35.020827+0800 XCTestWDUITests-Runner[21541:345025] check log dir @:["/Users/duke/Library/Developer/CoreSimulator/Devices/33D57EDC-24F6-489C-9E8D-7F62031278FB/data/Containers/Data/Application/1D3E921F-3C20-4BA6-8C38-3DABED83A8B0/Documents"] 2019-05-04 21:54:35:023 XCTestWDUITests-Runner[21541:345025] XCTestWD-Debug-Info: setup debug log 2019-05-04 21:54:35.024494+0800 XCTestWDUITests-Runner[21541:345044] XCTestWD-Debug-Info: setup debug log 2019-05-04 21:54:35.051919+0800 XCTestWDUITests-Runner[21541:345025] com.apple.test.XCTestWDUITests-Runner 2019-05-04 21:54:35.052132+0800 XCTestWDUITests-Runner[21541:345025] XCTestWDSetup->http://localhost:8001<-XCTestWDSetup

感觉是成功启动了的

单独用Xcode进行运行,我看是有一些警告的,没有报错。 WX20190504-220038@2x

spa221 avatar May 04 '19 14:05 spa221

This is the translated issue comment: @spa221


@spa221 It seems that it is a network problem, Run the xcode function to see if you can provide more log information. /Users/duke/Documents/testmacaca/sample-nodejs/node_modules/xctestwd/XCTestWD/XCTestWD.xcodeproj

Currently using the command to start directly Xcodebuild -project XCTestWD.xcodeproj
           -scheme XCTestWDUITests
           -destination 'platform=iOS Simulator,name=iPhone 6'
           XCTESTWD_PORT=8001
           Clean test

Displayed as follows 2019-05-04 21:54:35.015913+0800 XCTestWDUITests-Runner[21541:345025] initializing wd server 2019-05-04 21:54:35.020827+0800 XCTestWDUITests-Runner[21541:345025] check log dir @:["/Users/duke/Library/Developer/CoreSimulator/Devices/33D57EDC-24F6-489C-9E8D-7F62031278FB/ Data/Containers/Data/Application/1D3E921F-3C20-4BA6-8C38-3DABED83A8B0/Documents"] 2019-05-04 21:54:35:023 XCTestWDUITests-Runner[21541:345025] XCTestWD-Debug-Info: Setup debug log 2019-05-04 21:54:35.024494+0800 XCTestWDUITests-Runner[21541:345044] XCTestWD-Debug-Info: Setup debug log 2019-05-04 21:54:35.051919+0800 XCTestWDUITests-Runner[21541:345025] com.apple.test.XCTestWDUITests-Runner 2019-05-04 21:54:35.052132+0800 XCTestWDUITests-Runner[21541:345025] XCTestWDSetup->http://localhost:8001<-XCTestWDSetup

Feeling that it was successfully launched

Running with Xcode alone, I see some warnings and no errors. WX20190504-220038@2x

macaca-bot avatar May 04 '19 14:05 macaca-bot

app-inspector是正常的,截图如下

WX20190504-225302@2x WX20190504-225321@2x

spa221 avatar May 04 '19 14:05 spa221

This is the translated issue comment: @spa221


App-inspector is normal, the screenshot is as follows

WX20190504-225302@2x WX20190504-225321@2x

macaca-bot avatar May 04 '19 14:05 macaca-bot

@spa221 please provide diagnosis logs from macaca doctor, following the issue template.

paradite avatar May 08 '19 03:05 paradite

@spa221 please provide diagnosis logs from macaca doctor, following the issue template.

这个是诊断信息 DukedeMacBook-Pro:~ duke$ macaca doctor

macaca-doctor version: 2.0.16

Node.js checklist:

node env: /usr/local/bin/node node version: v10.15.3

iOS checklist:

Xcode Command Line Tools is ready, version: 2354. xcodebuild version: 10.2.1 iproxy[usbmuxd] is installed at: /usr/local/bin/iproxy ios_webkit_debug_proxy is installed at: /usr/local/bin/ios_webkit_debug_proxy

Android checklist:

JAVA version is 1.8 JAVA_HOME is not set ANDROID_HOME is not set gradle is installed, version: 5.4

Installed driver list:

android: 2.1.0 location: /usr/local/lib/node_modules/macaca-android

chrome: 1.1.0 location: /usr/local/lib/node_modules/macaca-chrome

electron: 3.0.2 location: /usr/local/lib/node_modules/macaca-electron

ios: 2.0.35 location: /usr/local/lib/node_modules/macaca-ios

DukedeMacBook-Pro:~ duke$

spa221 avatar May 09 '19 03:05 spa221

This is the translated issue comment: @spa221


@spa221 please provide diagnosis logs from macaca doctor, following the issue template.

This is diagnostic information DukedeMacBook-Pro:~ duke$ macaca doctor

  Macaca-doctor version: 2.0.16

  Node.js checklist:

  Node env: /usr/local/bin/node   Node version: v10.15.3

  iOS checklist:

  Xcode Command Line Tools is ready, version: 2354.   Xcodebuild version: 10.2.1   Iproxy[usbmuxd] is installed at: /usr/local/bin/iproxy   Ios_webkit_debug_proxy is installed at: /usr/local/bin/ios_webkit_debug_proxy

  Android checklist:

  JAVA version is 1.8   JAVA_HOME is not set   ANDROID_HOME is not set   Gradle is installed, version: 5.4

  Installed driver list:

  Android: 2.1.0   Location: /usr/local/lib/node_modules/macaca-android

  Chrome: 1.1.0   Location: /usr/local/lib/node_modules/macaca-chrome

  Electron: 3.0.2   Location: /usr/local/lib/node_modules/macaca-electron

  Ios: 2.0.35   Location: /usr/local/lib/node_modules/macaca-ios

DukedeMacBook-Pro:~ duke$

macaca-bot avatar May 09 '19 03:05 macaca-bot

hi,有人能帮忙看看我的问题吗?

spa221 avatar May 20 '19 14:05 spa221

This is the translated issue comment: @spa221


Hi, can someone help me with my question?

macaca-bot avatar May 20 '19 14:05 macaca-bot

@spa221 试试 Xcode 10.2。详见 https://github.com/macacajs/app-inspector/issues/228#issuecomment-491171629

paradite avatar May 20 '19 15:05 paradite

This is the translated issue comment: @paradite


@spa221 Try Xcode 10.2. See details Https://github.com/macacajs/app-inspector/issues/228#issuecomment-491171629

macaca-bot avatar May 20 '19 15:05 macaca-bot

I meet the same problem, for several days. Mac OS 10.14.5 + Xcode 10.2 ( also tried Xcode 10.2.1), neither work.

Log:

proxy.js:63:22 [master] pid:76512 xctest client proxy error with: Error: socket hang up proxy.js:63:22 [master] pid:76512 xctest client proxy error with: Error: read ECONNRESET proxy.js:63:22 [master] pid:76512 xctest client proxy error with: Error: read ECONNRESET proxy.js:63:22 [master] pid:76512 xctest client proxy error with: Error: read ECONNRESET xctest-client.js:309:14 [master] pid:76512 Fail to start xctest: Error: read ECONNRESET xctest-client.js:322:14 [master] pid:76512 killing runnerProc pid: 84284 xctest-client.js:328:14 [master] pid:76512 killing iproxyProc pid: 84538 xctest-client.js:272:14 [master] pid:76512 iproxy exit with code: null, signal: SIGKILL xctest-client.js:242:16 [master] pid:76512 xctest client exit with code: null, signal: SIGKILL

xinxinga avatar May 29 '19 08:05 xinxinga

@spa221 请问你的macOS版本是多少?

paradite avatar May 30 '19 15:05 paradite

This is the translated issue comment: @paradite


@spa221 What is your version of macOS?

macaca-bot avatar May 30 '19 15:05 macaca-bot

@spa221 请问你的macOS版本是多少?

10.14.5

spa221 avatar Jun 20 '19 09:06 spa221

This is the translated issue comment: @spa221


@spa221 What is your version of macOS?

10.14.5

macaca-bot avatar Jun 20 '19 09:06 macaca-bot

在最新的xcode 11下修复了,试一下。 @spa221

paradite avatar Oct 17 '19 13:10 paradite