I updated my phone to iOS 17 and I'm using Xcode 15. After the update, Xcode started to open automatically when I debug the flutter project. Before, we used to run Xcode ourselves if necessary, but now it runs continuously and the debug session is open on Xcode. When I close Xcode, the debug session is also closed. Unnecessary ram and resource consumption.
Why does Xcode open while debugging flutter projects now, is there any way to prevent this?
As explained here: If your app imports iOS platform-specific libraries, then Xcode is needed to debug that portion of your code. Xcode running in the foreground is expected behaviour until Apple (hopefully) adds a missing debugging feature for iOS 17.
Flutter used to silently build your project using Xcode and then launch a debugserver on the iOS device using ios-deploy. iOS 17 no longer supports ios-deploy however, and the replacement tooling in Xcode 15 is not able to start a debugserver as required by Flutter. Apple now only allows Xcode 15 running in the foreground to start a debugserver on iOS 17 and newer. (source: Flutter issue #133465)
Debugging your app in Flutter web on the other hand doesn’t require Xcode to run, and will quickly highlight any incompatible iOS libraries.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With