Cannot connect to physical iOS Device

All of the sudden, I was not able to connect to the iOS physical device to run my automation scripts, written in Java/Appium, from my Macbook.

The error returned in the IntelliJ logs is:
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
xcodebuild error message:

The error that pops up in the Appium log:
debug] [iProxy@9f639560:8100] Connection was refused to port 8100

The MacBook has the following software installed:

  1. MacOS - Ventura 13.3.1
  2. XCODE - 14.3
  3. Appium - v2.0.0-beta.71

I am attaching also the log files generated from IntelliJ and Appium server.

I will be grateful for your help since I have reached a deadlock and I cannot restart the Automation process on my physical device.Appium Server logfile.txt (21.1 KB) IntelliJ logfile.txt (11.2 KB)

1 Like

try rebuild WDA manually for sure.

I normally open xcode on the host, check that xcode can see the target, if so I unplug the target, reboot phone, plug back and 50% of the time that’s it. Alternately in xcode do a “clean”, and then go and clear out the internal xcode cache. What solved it for you @nathanael