In Xcode 15, the checkbox for "Connect via network" is grayed out and cannot be unchecked. However, I would like to disable it because debugging via network is too slow for me.
Does anyone have an idea how I can disable this?
In Xcode 15, the checkbox for "Connect via network" is grayed out and cannot be unchecked. However, I would like to disable it because debugging via network is too slow for me.
Does anyone have an idea how I can disable this?
Last week Apple published TN3158 Resolving Xcode 15 device connection issues that addresses this topic in depth.
IMPORTANT While this technote is associated with changes in macOS 14.4 and Xcode 15.3, both currently available as release candidates, installing these builds will not automagically fix all device connection problems. Read TN3158 for more backstory on this.
Because I want to separate the pre- and post-TN3158 discussion of this issue, I’ve locked this thread. If you have more to say on this subject, I’ve created a new thread for that discussion, namely Xcode 15.3 device connection issues.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
Pre-TN3158 bugs
FB13198191
FB13203790
FB13204677
FB13208687
FB13210513
FB13211128
FB13231882
FB13246000
FB13256031
FB13267950
FB13278689
FB13350507
FB13380011
FB13474705
FB13513987
FB13601388
Revision History
2023-03-05 Made major changes to reference TN3158.
2024-02-09 Added more bug numbers.
2024-01-09 Added more bug numbers.
2023-11-09 Added more bug numbers.
2023-11-08 First posted.
Can you point more precise than "Xcode Release Notes"? I'm unable to find anything related in the changelog from "Xcode 15.1 Beta 2 Release Notes" or "Xcode 15.0.1 Release Notes"
What if Apple "keeps this professional" and does not take such radical decisions that affects hundreds of thousands of people. Loading apps on device and debugging is extremely slow, and I've lost hours of works because of this. Guessing by the comments here, tons of feedback has been received by Apple, even from the beta stage, yet Apple released this crawling Xcode.
Using and debugging with Xcode is now so pain in the *** that I seriously consider using another tool and Apple answer is not an answer !
same here, Copying shared cache symbols for 20 minutes because force using of "Connect via network"
Same here, spent about 20-30 minutes with "Copying shared symbols" message with cable connected to device.
I was able to reduce the time to minutes by turning off Wi-Fi on the iOS device in the Control Center during the "Copy" stage. It seems to make it switch back to USB.
There are two parts to this:
Why is that checkbox greyed out?
Why is debugging slow?
The answer to the first is straightforward: iOS 17 has new debugging infrastructure such that all debugging goes over the network. That’s not the same thing as going over Wi-Fi. If you have the device attached via USB, the network requests will go over a virtual network interface running over USB.
Consider this test:
On an iOS 17 device, go to Settings > Wi-Fi and Settings > Bluetooth and disable both.
Attach the device to your Mac.
With Xcode 15, create a new test project from the iOS > App templates.
Select your device as a run destination.
Choose Build > Run.
You can install and debug the app just fine. This wouldn’t work if it were using Wi-Fi.
Which brings us to the the second issue: Why is this slow? This seems to only affect some folks. If it were affecting everyone, there’d be a lot more activity on this thread |-:
I suspect that something above your setup is causing the network to misbehave. For example:
It could be that Xcode’s connection over the USB virtual network interface is failing, resulting in the traffic going over Wi-Fi.
Or perhaps something is just slowing everything down.
As a first step I recommend that you repeat my test above. Are you able to debug on a device with Wi-Fi disabled? If not, that’s evidence for my first theory.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
Disabling WiFi & Bluetooth on the phone (or disabling WiFi on the Mac) does seems to solve this for me, but isn't a long-term solution.
Can we get a setting to force Xcode to use the cable, esp. now that the 15 Pro does support USB 3.2 Gen 2 transfer speeds if using the right cable.
Reported FB13203790
Forcing all debugging over the network is a major inconvenience to those of us that work remotely and require a VPN connection to corporate infrastructure. I can't debug on a device connected by wire because my VPN requires disabling the local network to maintain our ISO certification.
Just scratching my head as to why this needs to be a forced option? Appreciate any help.
Simply disabling Wifi and Bluetooth does make it a lot quicker to launch but this is really not a long term solution, especially when you're debugging apps that require a network connection or even debugging your bluetooth code. This would mean that your workflow becomes: disable bluetooth, launch app, enable bluetooth and debug (same for network related code assuming you're not using cellular). It just seems like many steps for something that always worked fine.
Yes perhaps something is just slowing everything down. But I don't know that something, and this problem is pain. We need option to disable "Connect via network"
Yes, it is critical
florian_buerger wrote:
Disabling WiFi & Bluetooth on the phone (or disabling WiFi on the Mac) does seems to solve this for me, but isn't a long-term solution.
I neven suggested it was. Rather, it’s a useful diagnostic test.
Reported
FB13203790
Thanks.
Reading that bug it seems that your issue is that things run very slowly. In that case, I recommend that you retest this on a ‘clean’ machine, one with a freshly installed copy of macOS and Xcode and nothing else.
I suspect that’ll work, which then suggests that there’s something about the network configuration on your main Mac that’s causing this issue. You can use that as a basic of your investigation. For example, your main Mac might have some sort of firewall that’s causing this issue [1].
OTOH, if you still see this problem on a clean machine, that’s more interesting, suggesting that the issue is with your wider network environment.
[1] Possibly even the Apple firewall!
jvc_canfieldsci wrote:
I can't debug on a device connected by wire because my VPN requires disabling the local network to maintain our ISO certification.
That makes things challenging, but at least it’s an explanation as to why things are failing.
I recommend that you file a bug about this with the details of your specific situation, including the VPN client you’re using and as as many details about how it’s configured as your IS folks are will to share.
Please post your bug number, just for the record.
In the meantime, I encourage you to discuss this with your IS folks. It’s possible that they can work out some sort of exception for you.
iTarek wrote:
We need option to disable "Connect via network"
As discussed above, that’s not really possible with the current architecture. I recommend that you follow the same path as florian_buerger, that is:
File a bug.
Runs tests to determine if there’s something about your network configuration that’s causing this.
Fedy wrote:
Yes, it is critical
That’s not really actionable feedback. Please read through the above and see if your situation matches one of those listed there. If not, please post more details.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
Thanks, bug filed, FB13204677. Unfortunately, my IT department cannot make an exception for me.
Thanks for filing FB13204677
.
Where I work, people experience this both when working at their home-networks as well as at the office. So there you've got multiple IT-infrastructures as well as variety of machines. One of the devs is very new so that comp is just like 1 month old, so the computer configuration is "very clean".
Thanks for getting back to me.
Reading that bug it seems that your issue is that things run very slowly. In that case, I recommend that you retest this on a ‘clean’ machine, one with a freshly installed copy of macOS and Xcode and nothing else.
I don't have the resources to do a clean install on a separate machine to investigate this, sorry.
I suspect that’ll work, which then suggests that there’s something about the network configuration on your main Mac that’s causing this issue. You can use that as a basic of your investigation. For example, your main Mac might have some sort of firewall that’s causing this issue [1].
OTOH, if you still see this problem on a clean machine, that’s more interesting, suggesting that the issue is with your wider network environment.
This happens on my home wifi, which is a standard Eero mesh system. The only custom network configuration I can think of is:
It worked much better in early Xcode 15 betas, but I don't recall when it became unusable.
1. IPv6 is disabled
How did you disable IPv6? On just the Wi-Fi interface? Or system wide?
Disabling IPv6 system wide is really not a good idea these days; lots of stuff relies on it.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
IPv6 has caused issues in the past with my ISP (T-Mobile Netherlands). It was disabled in network settings of the Eero system, I didn't change anything on the Mac or iPhone.
I have enabled it again, I'll report back if that changes anything.
The home network environment shouldn't be a relevant variable in this equation. The architectural choice to introduce that as a dependency is the problem.
I'm experiencing super slow installs on Xcode 15. I have nothing between me and the router and the phone, yet installing an app that would take a minute at most before is now stuck after 15 mins.
The changelog seems to suggest turning off WiFi on mac and on iPhone forces to switch to USB connection but not even that is working.
https://developer.apple.com/documentation/xcode-release-notes/xcode-15-release-notes issue 109466074
Is there any other workaround to disable network debugging? I simply cannot launch any app right now.
Hi there,
I can confirm that running development apps on an iPhone connected via USB is now much slower than before.
Xcode stays in the "Installing <app> on <device>" state for roughly 5-10 seconds on average, whereas previously this was almost instant.
This massively slows down development, since this is an action I run several times a minute, especially when doing UI work.
(I can also confirm that the "Connect via network" checkbox is checked and disabled.)
Versions: macOS Version 13.6 (Build 22G120) Xcode 15.0 (22265) (Build 15A240d) iOS 17.0.1 (21A340)
Hi! Filed feedback FB13208687, also experiencing very slow debug runs on iPhone. Turning Wifi / Bluetooth "fixes" the issue, however it's quite strange workaround to turn off wifi and turn it back on for almost every app launch.
Filed Feedback FB13198191.
More observations that might help to narrow down the issue:
iOS 17.0.2
, the following are observed:
iOS 16.7
(make sure to turn on Network debug), the following are observed:
Your observations are similar to mine. I suspect mine goes over wifi even tho cable is plugged in, specifically due to the case your mentioning regarding unplug during debugging.
Please provide information with network requirements or return the option to disable «Connect Via Network»
FB13210513
Caching symbols take about 25-30 minutes with iPad Pro attached over USB-C. (So process started over WiFi then I attached cable but nothing changed, still very slow).
My 300 Mb project (with 4-5k asset files) uploads to device in 1-2 minutes with cable attached.
Debugging and running apps on a device become insanely slow!
Feedback filed FB13211128
Thanks for filing all those bugs.
As I learn more about this issue I have an update on the diagnostic info needed to investigate these problems. If you want to help out here, please do the following:
Make a note of the UDID of your device. You can see this in the Devices and Simulators window under Identifier.
Reproduce the problem.
Make a note of the time.
Grab a Core Device diagnostic log with this command:
% xcrun devicectl diagnose
Trigger a sysdiagnose log for both your Mac and the target device. For information about how to do that, see Bug Reporting > Profiles and Logs.
Attach all of the above to your bug report.
florian_buerger wrote:
It was disabled in network settings of the Eero system, I didn't change anything on the Mac or iPhone.
Ah, OK, that’s unlikely to affect things. The system services that rely on IPv6 typically do so because of its link-local capabilities.
ospfranco wrote:
The changelog seems to suggest turning off WiFi on mac and on iPhone forces to switch to USB connection but not even that is working.
https://developer.apple.com/documentation/xcode-release-notes/xcode-15 -release-notes
issue 109466074
Thanks for sharing that; I’d forgotten about it.
DenTelezhkin wrote:
Filed feedback FB13208687
Thanks.
however it's quite strange workaround
Yep. It’s safe to say that this isn’t the developer experience we want you to have )-:
thinkingBanana wrote:
Filed Feedback
FB13198191
.
Thanks.
More observations that might help to narrow down the issue:
Interesting. Thanks for sharing.
Fedy wrote:
FB13210513
Thanks.
or return the option to disable «Connect Via Network»
As discussed above, that’s not really possible with the current architecture.
den73 wrote:
Feedback filed
FB13211128
Thanks.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
Thanks! reports has attached
I'm having some of these same issues.
What I have noticed is that debugging while connected to USB-C works great, however, it seems that once I physically disconnect and try to run on a simulator or another device, Xcode attempts to connect back to my default device over the network and totally gets stuck.
Once it gets into this state, Xcode was stuck "Indexing Open Quickly Content" which prevented me from killing Xcode. Had to kill 9 it.
Also, the "Connect via network" option is grayed out so I can't disable this functionality. All I want is debugging over USB-C most of the time.
@eskimo People running React Native can't turn off Wifi on the iPhone. Metro, a fundamentally integral and important part of running/debugging React Native applications, needs Wifi enabled when connected via Cable in order to function.
Would love a solution here as well !
I have to disconnect my iPhone from the wifi if I want to debug, because even if plugged, debugging seems to prioritize network over usb. It also seems to slow down all my network connections on my phone which is a bummer.
I observed a clear regression from beta 8, it was way faster on the prior iOS 17 / Xcode 15 betas.
Same, it's absolutely killing me how slow app launches and debugging are.
+1