Skip to main content

Unable to create a new remote session with iOS real devices

You encounter the following error:
java.util.concurrent.ExecutionException: org.openqa.selenium.SessionNotCreatedException: Unable to create a new remote session. Please check the server log for more details. 
Original error: An unknown server-side error occurred while processing the command. Original error: Unable to launch WebDriverAgent because of xcodebuild failure: xcodebuild failed with code 65
  1. Remove the current WebDriverAgentRunner from the iOS device.
  2. On the iOS device, go to Settings > General > Device Management, and trust your Apple ID.
  3. Run this command again to install the WebDriverAgentRunner:
    xcodebuild -project WebDriverAgent.xcodeproj -scheme WebDriverAgentRunner -destination 'id=your_device_id' test
  4. Message below confirms the driver is installed successfully:
    install WebDriverAgentRunner successfully
  5. Restart your Mobile Spy/Record session.