-
Notifications
You must be signed in to change notification settings - Fork 520
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Device freezes and not able to hit breakpoints when disconnecting USB and reattaching it while debugging. #21310
Comments
This is interesting, and I don't really have any ideas what might be causing it, except the Xcode issue you linked to.
|
Yes.
I tried it running Intellij Rider, there is no difference. I don't have VS 4 Mac as it's not supported anymore, and I do not have a Windows machine to test VS 4 Windows. Unfortunately, it now happened again and I tried following my own workarounds, none of them works :( In this scenario, I lost breakpoints from a USB disconnect. I tried to turn off Wifi on Mac and Airplane mode on device. I disconnected the USB and reattached it. Cleaned my bin folders, and started debugging. No breakpoints is hitting.
I closed the app, and Intellij Rider still thinks my app is running, with breakpoints disabled: :( So now I am completely stuck debugging my iOS app. This is the project I am running, specifically the Components app project. |
Do you see the same behavior if you create a new project? |
I can try a brand new project, but I see the same behaviour for all of my three app project I work on in my day job. I'll test a new one now. |
Tried my workaround for the new project when this bug appeared: I just turned off Wifi + enabled Airplane mode, then redeployed, it now hits my breakpoint. I then headed over to DIPS.Mobile.UI (original project I had issue with), it still has issues and no breakpoint is hit. This is confusing... |
This is quite puzzling, but here's an idea to try to fully revert to Xcode 15.4, which involves re-installing the packages from Xcode 15.4 that installs stuff into the system (replacing the ones that were installed by Xcode 16.0). The packages are in Here's a shell script to do it (make sure to update the path to Xcode): XCODE=/Applications/Xcode_15.4.0.app
PKGS="MobileDevice.pkg MobileDeviceDevelopment.pkg XcodeSystemResources.pkg"
for pkg in $PKGS; do
echo "Installing $pkg"
sudo /usr/sbin/installer -dumplog -verbose -pkg "$XCODE/Contents/Resources/Packages/$pkg" -target /
echo "Installed $pkg"
done Warning: I believe this to be safe, but it may leave your system in a confused state where things work worse than before. |
Fortunately, you decided to launch Xcode 16 support with .NET 8, for me this means that I can upgrade to it. Hopefully it will fix things for me :) |
Alright, good news. This looks like it got resolved. I will force this into our pipeline for my colleagues and give feedback here if we notice problems with the new update :) Have a nice weekend! |
That's great news! Hoping it will stay working 🤞 |
@rolfbjarne I still have issues after upgrading to xcode 16 and xamarin.ios 8303. However, it appears it is only reproduced when I am at the office, and not when I am working from home, where I do not have access to our internal network. It also has nothing to do with disconnecting and reconnecting the usb. Edit: Looks like I got it working by using the same network on device and mac and then restarting my mac, which I didn't need to before. |
Hi @haavamoa. Due to inactivity, we will be closing this issue. Please feel free to re-open this issue if the issue persists. For enhanced visibility, if over 7 days have passed, please open a new issue and link this issue there. Thank you. |
It's still happening for me, but I am unable to understand when it does. It can happen when I switch between VPN and non-VPN, but sometimes it happens when I am on the same network and I have to clear my bin/obj folders for it to connect again... This is very unfortunate |
I just realised that I had to downgrade iOS workload due to this issue: Which might be why I suddenly started getting this issues again. |
Apple platform
iOS
Framework version
net8.0-*
Affected platform version
.NET 8.0.100
Description
I upgraded to Xcode 16 last week, but after reading this post I removed it and installed Xcode 15.4. After doing so, I started noticing that debugging my app with a device sometimes freezes the app and I loose breakpoints.
Setup:
It seems like this is a known issue from Xcode 16 release notes
I want to create this issue so others can comment on their workarounds if others are experiencing the same behaviour as me.
Steps to Reproduce
Did you find any workaround?
It seems like rebooting my device stops the issue, but once I disconnect the USB and reattach it, the bug seem to come back.
It seems like this is a known issue from Xcode 16 release notes, and the workaround mentioned by Apple seems to work for me.
Relevant log output
No response
The text was updated successfully, but these errors were encountered: