设置:
- Xcode 8
- OSX El Capitan(10.11.6(
- 物理版iPhone6(iOS 9.1(
- 葫芦黄瓜0.20.3
- 运行操作2.2.2
首先,我尝试在物理手机上启动calabash控制台,但因为它没有DeviceAgentRunner.app应用程序,所以尝试安装它。
calabash-ios 0.20.3> start_test_server_in_background
EXEC: xcrun simctl list devices --json
EXEC: xcrun instruments -s devices
DEBUG: HTTP: get http://10.57.39.140:27753/1.0/health {:retries=>1, :timeout=>0.5}
DEBUG: Waiting for DeviceAgent to launch...
EXEC: cd /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent
EXEC: ditto -xk Frameworks.zip .
EXEC: ditto -xk DeviceAgent-Runner.app.zip .
EXEC: /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager install --device-id e544a153544294d3a9bcce89cecb17161d528baa --app-bundle /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/ipa/DeviceAgent-Runner.app --codesign-identity iPhone Developer: name@gmail.com (P536D9MXXX)
with a timeout of 60
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/shell.rb:104:in `run_shell_command'
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/ios_device_manager.rb:124:in `launch'
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/client.rb:1233:in `launch_cbx_runner'
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/client.rb:264:in `launch'
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/client.rb:140:in `run'
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop.rb:113:in `run'
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/calabash-cucumber-0.20.3/lib/calabash-cucumber/launcher.rb:408:in `block in new_run_loop'
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/calabash-cucumber-0.20.3/lib/calabash-cucumber/launcher.rb:406:in `times'
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/calabash-cucumber-0.20.3/lib/calabash-cucumber/launcher.rb:406:in `new_run_loop'
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/calabash-cucumber-0.20.3/lib/calabash-cucumber/launcher.rb:365:in `relaunch'
from /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/calabash-cucumber-0.20.3/lib/calabash-cucumber/core.rb:1567:in `start_test_server_in_background'
from (irb):1
from /Users/stefan/.rbenv/versions/2.2.3/bin/irb:11:in `<main>'
正如您所看到的,它无法安装DeviceAgentRunner.app应用程序,并超时。
然后我尝试安装DeviceAgentRunner.app手动
MACC02MK1XBFD59:CalabashVerification stefan$ /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager install --device-id e544a153544294d3a9bcce89cecb17161d528baa --app-bundle /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/ipa/DeviceAgent-Runner.app --codesign-identity "iPhone Developer: name@gmail.com (P536D9MXXX)"
objc[47805]: Class DDLog is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDLoggerNode is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDLogMessage is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDAbstractLogger is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDAbstractDatabaseLogger is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDTTYLogger is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDTTYLoggerColorProfile is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDLogFileManagerDefault is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDLogFileFormatterDefault is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDFileLogger is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDLogFileInfo is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
objc[47805]: Class DDASLLogger is implemented in both /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/Frameworks/FBControlCore.framework/Versions/A/Frameworks/CocoaLumberjack.framework/Versions/A/CocoaLumberjack and /Users/stefan/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/run_loop-2.2.2/lib/run_loop/device_agent/bin/iOSDeviceManager. One of the two will be used. Which one is undefined.
2016-10-31 12:09:12.495 iOSDeviceManager[47805:7626359] [MT] DVTPlugInManager: Required plug-in compatibility UUID DA4FDFD8-C509-4D8B-8B55-84A7B66AE701 for KSImageNamed.ideplugin (com.ksuther.KSImageNamed) not present
2016-10-31 12:09:12.638 iOSDeviceManager[47805:7626359] [MT] PluginLoading: Required plug-in compatibility UUID DA4FDFD8-C509-4D8B-8B55-84A7B66AE701 for plug-in at path '~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/xcfui.xcplugin' not present in DVTPlugInCompatibilityUUIDs
2016-10-31 12:09:12.639 iOSDeviceManager[47805:7626359] [MT] PluginLoading: Required plug-in compatibility UUID DA4FDFD8-C509-4D8B-8B55-84A7B66AE701 for plug-in at path '~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/RTImageAssets.xcplugin' not present in DVTPlugInCompatibilityUUIDs
2016-10-31 12:09:12.639 iOSDeviceManager[47805:7626359] [MT] PluginLoading: Required plug-in compatibility UUID DA4FDFD8-C509-4D8B-8B55-84A7B66AE701 for plug-in at path '~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/PrettyPrintJSON.xcplugin' not present in DVTPlugInCompatibilityUUIDs
2016-10-31 12:09:12.640 iOSDeviceManager[47805:7626359] [MT] PluginLoading: Required plug-in compatibility UUID DA4FDFD8-C509-4D8B-8B55-84A7B66AE701 for plug-in at path '~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/OMColorSense.xcplugin' not present in DVTPlugInCompatibilityUUIDs
2016-10-31 12:09:12.640 iOSDeviceManager[47805:7626359] [MT] PluginLoading: Required plug-in compatibility UUID DA4FDFD8-C509-4D8B-8B55-84A7B66AE701 for plug-in at path '~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/KSImageNamed.xcplugin' not present in DVTPlugInCompatibilityUUIDs
2016-10-31 12:09:12.641 iOSDeviceManager[47805:7626359] [MT] PluginLoading: Required plug-in compatibility UUID DA4FDFD8-C509-4D8B-8B55-84A7B66AE701 for plug-in at path '~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/DebugSearch.xcplugin' not present in DVTPlugInCompatibilityUUIDs
2016-10-31 12:09:12.641 iOSDeviceManager[47805:7626359] [MT] PluginLoading: Required plug-in compatibility UUID DA4FDFD8-C509-4D8B-8B55-84A7B66AE701 for plug-in at path '~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/CocoaPods.xcplugin' not present in DVTPlugInCompatibilityUUIDs
2016-10-31 12:09:12.642 iOSDeviceManager[47805:7626359] [MT] PluginLoading: Required plug-in compatibility UUID DA4FDFD8-C509-4D8B-8B55-84A7B66AE701 for plug-in at path '~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/Alcatraz.xcplugin' not present in DVTPlugInCompatibilityUUIDs
2016-10-31 12:09:20.201 iOSDeviceManager[47805:7626359] EXEC: /usr/bin/xcrun security find-identity -v -p codesigning
2016-10-31 12:09:50.203 iOSDeviceManager[47805:7626359] Could not find valid codesign identities with:
/usr/bin/xcrun security find-identity -v -p codesigning
2016-10-31 12:09:50.203 iOSDeviceManager[47805:7626359] Command timed out after 30.0009800195694 seconds
2016-10-31 12:09:50.203 iOSDeviceManager[47805:7626359] ERROR: The signing identity you provided is not valid:
iPhone Developer: name@gmail.com (P536D9MXXX)
2016-10-31 12:09:50.203 iOSDeviceManager[47805:7626359] ERROR:
2016-10-31 12:09:50.203 iOSDeviceManager[47805:7626359] ERROR: These are the valid signing identities that are available:
2016-10-31 12:09:50.203 iOSDeviceManager[47805:7626359] EXEC: /usr/bin/xcrun security find-identity -v -p codesigning
2016-10-31 12:10:20.204 iOSDeviceManager[47805:7626359] Could not find valid codesign identities with:
/usr/bin/xcrun security find-identity -v -p codesigning
2016-10-31 12:10:20.204 iOSDeviceManager[47805:7626359] Command timed out after 30.00082302093506 seconds
2016-10-31 12:10:20.206 iOSDeviceManager[47805:7626359] Error creating product bundle for /var/folders/yy/vvrqrp2n6qv9b_tbssf_74n80000gn/T/59E25CB1-38F5-4269-B950-0040BACB2E00-47805-000048155108503C/DeviceAgent-Runner.app: Error Domain=com.facebook.XCTestBootstrap Code=0 "Failed to codesign /var/folders/yy/vvrqrp2n6qv9b_tbssf_74n80000gn/T/59E25CB1-38F5-4269-B950-0040BACB2E00-47805-000048155108503C/DeviceAgent-Runner.app" UserInfo={NSLocalizedDescription=Failed to codesign /var/folders/yy/vvrqrp2n6qv9b_tbssf_74n80000gn/T/59E25CB1-38F5-4269-B950-0040BACB2E00-47805-000048155108503C/DeviceAgent-Runner.app, NSUnderlyingError=0x7fbfef6127f0 {Error Domain=sh.calaba.iOSDeviceManger Code=5 "Could not resign with the given arguments" UserInfo={NSLocalizedDescription=Could not resign with the given arguments, NSLocalizedFailureReason=The device UDID and code signing identity were invalid forsome reason. Please check the logs.}}}
install
-u,--update-app <true-or-false> [OPTIONAL] When true, will reinstall the app if the device contains an older version than the bundle specified DEFAULT=1
-c,--codesign-identity <codesign-identity> [OPTIONAL] Identity used to codesign app bundle [device only] DEFAULT=
-a,--app-bundle <path/to/app-bundle.app> Path .app bundle (for .ipas, unzip and look inside of 'Payload')
-d,--device-id <device-identifier> iOS Simulator GUID or 40-digit physical device ID
这至少给了我更多的信息,因为它说这与代码演唱有关。我确信我的证明是有效的。所以我的问题是:
- 我可以告诉run_loop使用不同的标识符来辞职DeviceAgentRunner.app吗,因为我不能使用通配符证书(公司政策(
或者任何其他想法如何从这一点继续
谢谢!
iOSDeviceManager install <snip> --codesign-identity "iPhone Developer: name@gmail.com (P536D9MXXX)"
The signing identity you provided is not valid:
iPhone Developer: name@gmail.com (P536D9MXXX)
EXEC: /usr/bin/xcrun security find-identity -v -p codesigning
Could not find valid codesign identities with:
/usr/bin/xcrun security find-identity -v -p codesigning
问题是签名标识无效。此外,您的计算机上没有安装有效的代码签名标识。
通配符证书
我认为您混淆了通配符配置文件和开发人员证书。不需要通配符设置配置文件。