Signing for "WebDriverAgentRunner" requires a development team. Select a development team in the project editor. [Xcode] Code signing is required for product type 'UI Testing Bundle' in SDK 'iOS 10.2'

I am using Appium 1.6.3 (also tried 1.6.2) with Xcode 8.2 (also tried 8.2.1) to start appium and use appium inspector from appium 1.5.3 GUI.

appium & → This starts the server with following message on terminal:
admins-mac-mini:WebDriverAgent admin$ [Appium] Welcome to Appium v1.6.2
[Appium] Appium REST http interface listener started on 0.0.0.0:4723

But when I click on inspector button on appium GUI, it gives error as below on terminal:
[Xcode] Code signing is required for product type 'UI Testing Bundle' in SDK 'iOS 10.2'

[Xcode] Signing for "WebDriverAgentRunner" requires a development team. Select a development team in the project editor.

[Xcode] Code signing is required for product type 'UI Testing Bundle' in SDK 'iOS 10.2'

[Xcode] Signing for "WebDriverAgentRunner" requires a development team. Select a development team in the project editor.

[Xcode] Code signing is required for product type 'UI Testing Bundle' in SDK 'iOS 10.2'

[Xcode] Code signing is required for product type 'UI Testing Bundle' in SDK 'iOS 10.2'


[Xcode] 
Testing failed:

[Xcode] 	Signing for "WebDriverAgentRunner" requires a development team. Select a development team in the project editor.
	Code signing is required for product type 'UI Testing Bundle' in SDK 'iOS 10.2'
** TEST FAILED **

The following build commands failed:
	Check dependencies
(1 failure)

[XCUITest] xcodebuild exited with code '65' and signal 'null'
[debug] [XCUITest] xcodebuild failure warrants retry. Retrying...

I read a lot of post on discuss.appium.io and githum to check the development team in XCode and correct all the configurations in WebDriverAgent xcodeproject. I have done all of them. I have signed my app with proper development team (WebDriverAgentLib, WebDriverAgentRunner and all).

But still it gives me same error. I have tried this on XCode 8.2 and XCode 8.2.1 both and also with Appium 1.6.3 and Appium 1.6.2 but I had no luck. Issue is still there as a blockage to start with ios10 automation.
I read somewhere in discussion that to create xcodeconfig configuration setting file and specify development team and all there but before executing script from code I have to start appium inspector to check everything works fine. And also to inspect elements I cant execute and inspect from Java code.

Can someone help me out with this.

I think this will help with your problem:

@wreed I tried this but it did not helped.

PLease share the screenshot of webdriver agent which you have signed manually

@abh7nav there is no try. Do or do not. Show error if problem. Your response unhelped.

[debug] [XCUITest] Xcode version set to ‘8.2’
[debug] [XCUITest] iOS SDK Version set to ‘10.2’
[debug] [XCUITest] Available devices:
[debug] [XCUITest] Creating iDevice object with udid
[XCUITest] Determining device to run tests on: udid: , real device: true
[BaseDriver] Using local app '/Users/admin/Downloads/<appName.ipa>’
[debug] [BaseDriver] Copying local zip to tmp dir
[debug] [BaseDriver] Unzipping /var/folders/gv/kgsw87q93wq34dpxyq3z044m0000gn/T/20161128-20719-awxyg7.jtrs51xlxr/appium-app.zip
[debug] [BaseDriver] Testing zip archive: /var/folders/gv/kgsw87q93wq34dpxyq3z044m0000gn/T/20161128-20719-awxyg7.jtrs51xlxr/appium-app.zip
[BaseDriver] Unzipped local app to ‘/var/folders/gv/kgsw87q93wq34dpxyq3z044m0000gn/T/20161128-20719-awxyg7.jtrs51xlxr/Payload/appName.app’
[debug] [XCUITest] Checking whether app ‘/var/folders/gv/kgsw87q93wq34dpxyq3z044m0000gn/T/20161128-20719-awxyg7.jtrs51xlxr/Payload/appName.app’ is actually present
[debug] [XCUITest] App is present
[debug] [iOSLog] Attempting iOS device log capture via libimobiledevice idevicesyslog
[debug] [iOSLog] Found idevicesyslog: ‘/usr/local/bin/idevicesyslog’
[XCUITest] Setting up real device
[debug] [XCUITest] App is already installed.
[debug] [XCUITest] Full reset not requested. No need to install.
[XCUITest] Using WDA path: ‘/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent’
[XCUITest] Using WDA agent: ‘/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/WebDriverAgent.xcodeproj’
[XCUITest] Launching WebDriverAgent on the device
[debug] [XCUITest] Carthage found: /usr/local/bin/carthage
[debug] [XCUITest] Killing hanging processes
[debug] [XCUITest] Using real device logger ‘idevicesyslog’
[debug] [XCUITest] Beginning test with command ‘xcodebuild build test -project /usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/WebDriverAgent.xcodeproj -scheme WebDriverAgentRunner -destination id= -configuration Debug’ in directory ‘/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent’
[XCUITest] Waiting for WebDriverAgent to start on device
[debug] [XCUITest] Log file for xcodebuild test: /Users/admin/Library/Developer/Xcode/DerivedData/WebDriverAgent-brdadhpuduowllgivnnvuygpwhzy/Logs/Test/9975B7BD-4AD2-4F81-A94D-A453DF38AD03/Session-WebDriverAgentRunner-2016-12-28_215817-GnaPb1.log
[Xcode] 2016-12-28 21:58:18.197 xcodebuild[20754:366429] Error Domain=IDETestOperationsObserverErrorDomain Code=3 “Test operation was canceled. If you believe this error represents a bug, please attach the log file at /Users/admin/Library/Developer/Xcode/DerivedData/WebDriverAgent-brdadhpuduowllgivnnvuygpwhzy/Logs/Test/9975B7BD-4AD2-4F81-A94D-A453DF38AD03/Session-WebDriverAgentRunner-2016-12-28_215817-GnaPb1.log” UserInfo={NSLocalizedDescription=Test operation was canceled. If you believe this error represents a bug, please attach the log file at /Users/admin/Library/Developer/Xcode/DerivedData/WebDriverAgent-brdadhpuduowllgivnnvuygpwhzy/Logs/Test/9975B7BD-4AD2-4F81-A94D-A453DF38AD03/Session-WebDriverAgentRunner-2016-12-28_215817-GnaPb1.log}

[Xcode] Code signing is required for product type ‘UI Testing Bundle’ in SDK ‘iOS 10.2’

[Xcode] Signing for “WebDriverAgentRunner” requires a development team. Select a development team in the project editor.

[Xcode] Code signing is required for product type ‘UI Testing Bundle’ in SDK ‘iOS 10.2’

[Xcode] Signing for “WebDriverAgentRunner” requires a development team. Select a development team in the project editor.

[Xcode] Code signing is required for product type ‘UI Testing Bundle’ in SDK ‘iOS 10.2’

[Xcode] Code signing is required for product type ‘UI Testing Bundle’ in SDK ‘iOS 10.2’

[Xcode]
Testing failed:

[Xcode] Signing for “WebDriverAgentRunner” requires a development team. Select a development team in the project editor.
Code signing is required for product type ‘UI Testing Bundle’ in SDK ‘iOS 10.2’
** TEST FAILED **

The following build commands failed:
Check dependencies
(1 failure)

[XCUITest] xcodebuild exited with code ‘65’ and signal ‘null’
[debug] [XCUITest] xcodebuild failure warrants retry. Retrying…
[XCUITest] Shutting down sub-processes
[XCUITest] Shutting down Logger process (pid 20759)
[XCUITest] System log exited with code ‘0’
[debug] [XCUITest] Removing WDA application from device
[XCUITest] Launching WebDriverAgent on the device
[debug] [XCUITest] Carthage found: /usr/local/bin/carthage
[debug] [XCUITest] Killing hanging processes
[debug] [XCUITest] Using real device logger ‘idevicesyslog’
[debug] [XCUITest] Beginning test with command ‘xcodebuild build test -project /usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/WebDriverAgent.xcodeproj -scheme WebDriverAgentRunner -destination id= -configuration Debug’ in directory ‘/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent’
[XCUITest] Waiting for WebDriverAgent to start on device
[debug] [XCUITest] Log file for xcodebuild test: /Users/admin/Library/Developer/Xcode/DerivedData/WebDriverAgent-brdadhpuduowllgivnnvuygpwhzy/Logs/Test/171E8052-5CEB-4530-ADA2-4BA7B57B5892/Session-WebDriverAgentRunner-2016-12-28_215820-pAGiLP.log
[Xcode] 2016-12-28 21:58:20.442 xcodebuild[20790:366571] Error Domain=IDETestOperationsObserverErrorDomain Code=3 “Test operation was canceled. If you believe this error represents a bug, please attach the log file at /Users/admin/Library/Developer/Xcode/DerivedData/WebDriverAgent-brdadhpuduowllgivnnvuygpwhzy/Logs/Test/171E8052-5CEB-4530-ADA2-4BA7B57B5892/Session-WebDriverAgentRunner-2016-12-28_215820-pAGiLP.log” UserInfo={NSLocalizedDescription=Test operation was canceled. If you believe this error represents a bug, please attach the log file at /Users/admin/Library/Developer/Xcode/DerivedData/WebDriverAgent-brdadhpuduowllgivnnvuygpwhzy/Logs/Test/171E8052-5CEB-4530-ADA2-4BA7B57B5892/Session-WebDriverAgentRunner-2016-12-28_215820-pAGiLP.log}

[Xcode] Signing for “WebDriverAgentRunner” requires a development team. Select a development team in the project editor.

[Xcode] Code signing is required for product type ‘UI Testing Bundle’ in SDK ‘iOS 10.2’

[Xcode] Code signing is required for product type ‘UI Testing Bundle’ in SDK ‘iOS 10.2’

[Xcode]
Testing failed:

[Xcode] Signing for “WebDriverAgentRunner” requires a development team. Select a development team in the project editor.
Code signing is required for product type ‘UI Testing Bundle’ in SDK ‘iOS 10.2’
** TEST FAILED **

The following build commands failed:
Check dependencies
(1 failure)

[XCUITest] xcodebuild exited with code ‘65’ and signal ‘null’
[XCUITest] Error: xcodebuild failed with code 65
at SubProcess. (…/…/lib/webdriveragent.js:332:25)
at emitTwo (events.js:106:13)
at SubProcess.emit (events.js:191:7)
at ChildProcess. (…/…/lib/teen_process.js:197:14)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
Error: xcodebuild failed with code 65
at SubProcess. (…/…/lib/webdriveragent.js:332:25)
at emitTwo (events.js:106:13)
at SubProcess.emit (events.js:191:7)
at ChildProcess. (…/…/lib/teen_process.js:197:14)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
[XCUITest] Shutting down sub-processes
[XCUITest] Shutting down Logger process (pid 20795)
[XCUITest] System log exited with code ‘0’
[debug] [XCUITest] Running ios real device reset flow
[debug] [XCUITest] Resetting simulator
[debug] [iOSLog] Stopping iOS log capture
(node:20719) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 4): Error: Can’t stop process; it’s not currently running
(node:20719) DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
[MJSONWP] Encountered internal error running command: Error: xcodebuild failed with code 65
at SubProcess. (…/…/lib/webdriveragent.js:332:25)
at emitTwo (events.js:106:13)
at SubProcess.emit (events.js:191:7)
at ChildProcess. (…/…/lib/teen_process.js:197:14)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
[HTTP] <-- POST /wd/hub/session 500 11140 ms - 167

I got it working . Thanks All

Could you post the solution? It will be helpful if someone lands on this question from a web search.

Facing the same issue.
Can you PLS give a detailed solution that will help us to overcome this issue?
Thanks!

The .xcodeproj under WebDriverAgent project which I was signing was not correct. When I opened the project whose path was being displayed on terminal using open command then the changes were reflected and everything worked. Thanks all for your help!!

Hi abh7nav, I do have the same issue which were facing earlier , can you please elaborate on the solution please .
currently i am getting the below error:
Testing failed:

[Xcode] No profiles for ‘com.facebook.WebDriverAgentRunnersRS’ were found: Xcode couldn’t find a provisioning profile matching ‘com.facebook.WebDriverAgentRunnersRS’.
Code signing is required for product type ‘UI Testing Bundle’ in SDK ‘iOS 10.2’
** TEST FAILED **

For Appium 1.6.X , if you get this issue please follow the steps to resolve the issue:

  1. Go to your Appium folder and find appium/node_modules/appium-xcuitest-driver/WebDriverAgent/WebDriverAgent.xcodeproj file or you can search for the file name.
  2. Open the file using Xcode.
  3. Select WebDriverAgentLib and In general tab select 'Automatically Manage Signing" and select an id in team dropdown (Ask your developement team to provide you the team id).
  4. Now select the next WebDriverAgentRunner and do the same thing as you did for the WebDriverAgentLib.
  5. In case you get some errors just go to the ‘Build Settings’ tab and change the “Product Bundle Identifier” from “com.facebook.WebDriverAgentLib” to “com.facebook.WebDriverAgentLibNew”.
  6. Come back to general tab and the errors should be fixed.
  7. Now build both WebDriverAgentLib and WebDriverAgentRunner.
  8. When you get Build succeed message, run your test again.

Please refer to below link:
https://github.com/appium/appium/blob/master/docs/en/appium-setup/real-devices-ios.md#configuring-ios-real-device-tests-xcode-8-and-ios-93-and-above