升级到 iOS 9.1 模拟器使 Calabash 无法识别设备目标

Upgrading to iOS 9.1 simulator makes Calabash not recognize the device target

xcode安装位置:/Applications/Xcode.app/Contents/Developer

xcode 版本:Xcode 7.2 构建版本 7C68

葫芦版本:0.16.4

calabash.framework version: `0.16.4`
profiling: /Users/moody/git/calabash/calabash-ios-server/build/framework/version-tool/Build/Intermediates/calabash.build/Debug/version.build/Objects-normal/x86_64/main.gcda: cannot open: No such file or directory
profiling: /Users/moody/git/calabash/calabash-ios-server/build/framework/version-tool/Build/Intermediates/calabash.build/Debug/version.build/Objects-normal/x86_64/main.gcda: cannot open: No such file or directory
profiling: /Users/moody/git/calabash/calabash-ios-server/build/framework/version-tool/Build/Intermediates/calabash.build/Debug/version.build/Objects-normal/x86_64/main.gcda: cannot open: No such file or directory
profiling: /Users/moody/git/calabash/calabash-ios-server/build/framework/version-tool/Build/Intermediates/calabash.build/Debug/version.build/Objects-normal/x86_64/main.gcda: cannot open: No such file or directory

(我从 0.14.3 升级到 0.16.4 后得到了最上面的文本,在那之前它只会告诉我 0.14.3 而没有额外的东西)

问题来了: 当我将 Xcode 和 01_launch.rb 中的模拟器版本从 8.4 更新到 9.1 时,我的葫芦功能将不会 运行。这是我收到的错误:

No device_target was specified and did not detect a connected device. Set a device_target option in the relaunch method. (RuntimeError)
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/launcher.rb:684:in `default_uia_strategy'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/launcher.rb:627:in `relaunch'
  /Users/myname/Development/sprayerMobile/SprayMobile/features/support/01_launch.rb:35:in `Before'
Retrying.. Errno::ECONNREFUSED: (Connection refused - connect(2) for "localhost" port 37265 (http://localhost:37265))
Retrying.. Errno::ECONNREFUSED: (Connection refused - connect(2) for "localhost" port 37265 (http://localhost:37265))
Failing... Errno::ECONNREFUSED
  Connection refused - connect(2) for "localhost" port 37265 (http://localhost:37265) (Errno::ECONNREFUSED)
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient/session.rb:799:in `initialize'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient/session.rb:799:in `new'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient/session.rb:799:in `create_socket'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient/session.rb:747:in `block in connect'
  /Users/myname/.rbenv/versions/2.2.3/lib/ruby/2.2.0/timeout.rb:88:in `block in timeout'
  /Users/myname/.rbenv/versions/2.2.3/lib/ruby/2.2.0/timeout.rb:98:in `call'
  /Users/myname/.rbenv/versions/2.2.3/lib/ruby/2.2.0/timeout.rb:98:in `timeout'
  /Users/myname/.rbenv/versions/2.2.3/lib/ruby/2.2.0/timeout.rb:124:in `timeout'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient/session.rb:746:in `connect'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient/session.rb:612:in `query'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient/session.rb:164:in `query'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient.rb:1191:in `do_get_block'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient.rb:974:in `block in do_request'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient.rb:1082:in `protect_keep_alive_disconnected'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient.rb:969:in `do_request'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient.rb:822:in `request'
  /Users/myname/.calabash/gems/httpclient-2.6.0.1/lib/httpclient.rb:725:in `post'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/http_helpers.rb:57:in `block in make_http_request'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/http_helpers.rb:50:in `times'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/http_helpers.rb:50:in `make_http_request'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/http_helpers.rb:29:in `http'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/connection_helpers.rb:11:in `http'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/map.rb:71:in `raw_map'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/map.rb:23:in `map'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/core.rb:112:in `query'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/tests_helpers.rb:23:in `element_does_not_exist'
  /Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/tests_helpers.rb:30:in `element_exists'
  /Users/myname/Development/company/Company/features/support/01_launch.rb:43:in `Before'

当我切换回 8.4 时,此错误消失了 8.4 有没有人遇到过这种情况,或者知道解决此问题的方法?对我来说,这似乎是一个模拟器问题,因为当我切换回 b/w 模拟器时,在 9.1 中我得到了这些错误,而 8.4 我的功能 运行 很好..但是我的同事在我的代码中放入了一些 Xcode 7 个更新,所以这可能也与他的更新有关...

顺便说一句,如果我升级到 0.16.4 为什么它指的是 0.14.3 宝石?

*更新

当我在 运行ning 功能之前添加 DEBUG=1 时,我收到这些警告:

WARN: deprecated '1.5.0' - Replaced with RunLoop::Xcode
/Users/myname/.calabash/gems/run_loop-1.5.6/lib/run_loop/xctools.rb:183:in `xcode_version_gte_51?'
/Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/launcher.rb:490:in `default_launch_method'
/Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/launcher.rb:420:in `default_launch_args'
/Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/launcher.rb:534:in `relaunch'
/Users/myname/Development/sprayerMobile/SprayMobile/features/support/01_launch.rb:36:in `block in <top (required)>'
WARN: deprecated '1.5.0' - Replaced by RunLoop::Xcode
/Users/myname/.calabash/gems/run_loop-1.5.6/lib/run_loop/sim_control.rb:21:in `xctools'
/Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/launcher.rb:666:in `default_uia_strategy'
/Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/launcher.rb:627:in `relaunch'
/Users/myname/Development/sprayerMobile/SprayMobile/features/support/01_launch.rb:36:in `block in <top (required)>'
/Users/myname/.calabash/gems/cucumber-1.3.20/lib/cucumber/core_ext/instance_exec.rb:48:in `instance_exec'
WARN: deprecated '1.5.0' - Replaced with RunLoop::Instruments
/Users/myname/.calabash/gems/run_loop-1.5.6/lib/run_loop/xctools.rb:265:in `instruments'
/Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/launcher.rb:666:in `default_uia_strategy'
/Users/myname/.calabash/gems/calabash-cucumber-0.14.3/lib/calabash-cucumber/launcher.rb:627:in `relaunch'
/Users/myname/Development/sprayerMobile/SprayMobile/features/support/01_launch.rb:36:in `block in <top (required)>'
/Users/myname/.calabash/gems/cucumber-1.3.20/lib/cucumber/core_ext/instance_exec.rb:48:in `instance_exec'

如有任何帮助,我们将不胜感激!

安装新的 Xcode 或 moving/renaming Xcode 安装后,您需要重新启动计算机。

您的 gem 版本 (0.14.3) 与应用中的服务器版本 (0.16.4) 不匹配。请参阅Updating your Calabash iOS version

我认为您的 run-loop 版本与 Xcode 7.2 不兼容。

如果您没有使用 Gemfile,我们建议您开始使用。