After upgrading to Xcode 16 I am stuck at "Waiting to reconnect to..." when trying to build to a device
After upgrading to Xcode 16, I'm having trouble building to a device because it gets stuck on "Waiting to reconnect to...". Has anyone else faced this issue or found a solution?
This issue of getting stuck at "Waiting to reconnect to..." after upgrading to Xcode 16 is relatively common and can be caused by various factors related to device connectivity or software configurations. Here are some steps you can try to resolve it:
Troubleshooting Steps
Restart Xcode and the Device:
Quit Xcode and restart your device. Reconnect and try building again.
Update macOS and iOS Versions:
Ensure both macOS and the connected device are updated to the latest versions compatible with Xcode 16.
Reset Trust Settings:
On the device, navigate to Settings > General > Transfer or Reset iPhone > Reset > Reset Location & Privacy. Reconnect the device and tap "Trust" when prompted.
Clean Build Folder:
In Xcode, go to Product > Clean Build Folder or press Shift + Command + K to remove any corrupted build data.
Reset Xcode Derived Data:
Delete derived data by going to Xcode > Preferences > Locations and clicking the arrow next to the derived data path. Delete the folder.
Reboot CoreDevice Service:
Run the following command in Terminal to restart the CoreDevice service:
sudo killall -9 com.apple.CoreSimulator.CoreSimulatorService
Reinstall Xcode or Command Line Tools:
If none of the above work, consider reinstalling Xcode or updating/reinstalling Command Line Tools:
xcode-select --install
These steps typically resolve the connection issue. If the problem persists, checking for known issues in Xcode’s release notes or Apple Developer forums might help.