Debugging on iOS 14.6

Which Xcode should I use to debug on iOS 14.6? Xcode 12.5 doesn't work, there is no active beta.
  • I’ve been looking for solutions for this as well, but there doesn’t seem to be any. Does this mean we have to wait for Xcode to update?

  • Either so or downgrade the iOS to 14.5

Add a Comment

Accepted Reply

I asked about this internally and the official word is that Xcode 12.5 should be able to debug apps running on iOS 14.6. I tested this here in my office and it works for me. However, it’s clear that this isn’t working for everyone. We’re looking into this (r. 78623341) but we’re having troubles reproducing it. So, if you’re one of the folks having this problem, please file your own bug about this and then post your bug number here.

With regards your bug report:

  • Please include a sysdiagnose log, taken shortly after reproducing the problem.

  • Make sure to be clear about whether the problem happens all the time, or just occasionally.

  • Also, create a new test project and see if the problem reproduces with that. If it does, include your test project in your bug report.

  • If it only reproduces with your main project, make sure to note that in your bug report. It’d be super helpful if you could include a copy of that project that we can use to reproduce the problem, but I understand that’s not always possible.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

  • For no particular reason, it connected this morning and registered the device after a few plug-ins and out. So, there's hope for the rest of you! Thanks, Quinn!

  • +1, it started to work without any actions from my side

  • how about simulator for 14.6 ?, seems i can't find any way to download it

Replies

Apple seem to be doing this a lot these days - releasing a new iOS version without a compatible Xcode. Seems like it's best to wait until I see a new version of Xcode before I update any devices. Pfft.

Post not yet marked as solved Up vote reply of JAWZ Down vote reply of JAWZ

I asked about this internally and the official word is that Xcode 12.5 should be able to debug apps running on iOS 14.6. I tested this here in my office and it works for me. However, it’s clear that this isn’t working for everyone. We’re looking into this (r. 78623341) but we’re having troubles reproducing it. So, if you’re one of the folks having this problem, please file your own bug about this and then post your bug number here.

With regards your bug report:

  • Please include a sysdiagnose log, taken shortly after reproducing the problem.

  • Make sure to be clear about whether the problem happens all the time, or just occasionally.

  • Also, create a new test project and see if the problem reproduces with that. If it does, include your test project in your bug report.

  • If it only reproduces with your main project, make sure to note that in your bug report. It’d be super helpful if you could include a copy of that project that we can use to reproduce the problem, but I understand that’s not always possible.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

  • For no particular reason, it connected this morning and registered the device after a few plug-ins and out. So, there's hope for the rest of you! Thanks, Quinn!

  • +1, it started to work without any actions from my side

  • how about simulator for 14.6 ?, seems i can't find any way to download it

A post somewhere else suggested duplicating the 14.5 folder inside Xcode and renaming it to 14.6 and that solved the issue for me.

A post somewhere else suggested duplicating the 14.5 folder inside Xcode

Please don’t modify your Xcode. While it might help in the short term, modifications like this are wildly unsupported and likely to cause long-term problems.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

  • So what you are saying, F your users. Because my users are having problems now running my app on 14.6 and I cannot test or debug it. Unless I use the above mentioned modification. Anyway, using that solved my problem, but some other users are still experiencing problems and currently, I have no way of investigating it. WHEN IS XCODE GOING TO SUPPORT 14.6???? And please let the answer be 'this weekend'.

Add a Comment

So what you are saying …

No, what I’m saying is:

  • Using Xcode 12.5 to debug iOS 14.6 is expected to work.

  • And it actually works for me (as I mentioned above) and for a vast majority of iOS developers (if this problem affected all iOS developers then this thread would be many pages long!).

  • If it’s not working for you then there’s something specific about your environment that’s causing the problem. It’s hard to say what that is, which is why I asked folks to post bug reports.

  • Trying to resolve that problem by unsupported modifications of Xcode is likely to cause more problems that it solves in the long term.

Once you’ve filed your bug report you can then take steps to try to find the real cause of this issue. For example:

  • Restarting your device, to rule out lingering state on the device itself.

  • Re-installing Xcode, to rule out the possibility that Xcode itself is broken.

  • Trying with a new project created from one of the built-in templates, to rule out the possibility that there’s something about your project that’s triggering this.

  • Trying from a fresh user account on your Mac, created using System Preferences > Users & Groups, to rule out any lingering state in your home directory.

  • Trying from a different Mac, to rule out any lingering state on your Mac.

  • Or if you don’t have a different Mac, re-installing macOS itself.

This process is doubly helpful: It’ll help you get around the problem (in a supported fashion) and it’ll make good factoids for your bug report.

Let us know how you get along.


Oh, and let me explain why I’m so against unsupported techniques. Let’s say you do this and it works. Cool, you’ve found a expedient workaround! Now imagine it’s a few months down the track and you install Xcode 13 final. Do you remember to undo this workaround before doing that install? If you don’t then you’ve put the Xcode 13 installer into a very weird place, where it’s trying to update a modified copy of Xcode. Does that work? No one can say for sure but I can guarantee that Apple didn’t test it.

And if you continue applying expedient workarounds then your macOS and Xcode installations will steadily deviate from the well-trodden path, making it more likely that you’ll run into weird problems like this one.

In contrast, the suggestions I’ve posted above should help you get back on the right path, making it less likely you’ll have ongoing issues.


I have no way of investigating it.

That’s not true. Even if you can’t get Xcode working, which I don’t believe is true, you can still debug problems using the same techniques you’d use for debugging issues that you can’t reproduce locally:

  1. Add debug logging to your app.

  2. Build it using Xcode.

  3. Export it as .ipa.

  4. Install that using the Finder.

  5. Run it and capture the logs.

  6. Analyse the logs.

  7. Repeat if necessary.

This is a lot slower than the usual debug cycle — which is why I recommend that you try to resolve the issue using the various steps described above — but it will work.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Can confirm that this is definitely an issue. It is happening on both my work and personal Mac's. In true Xcode fashion it is also happening to one of my colleagues, but not the other.

Xcode works locally with the simulator, but for devices it gives the following error:

Failed to prepare device for development.

Domain: com.apple.dtdevicekit

Code: 806

Recovery Suggestion: If you are certain that Xcode supports development on this device, try disconnecting and reconnecting the device.

User Info: {

    AssociatedMobileDeviceFunction = AMDeviceMountImage;

    DVTRadarComponentKey = 487927;

    NSLocalizedFailure = "This operation can fail if the version of the OS on the device is newer than the version of Xcode that is running.";

}

I appreciate @Eskimo's thorough answer, but I think I share @Iksmode sentiment that Apple should be frantically fixing this. There really are a lot of reports about this bug if you google.

For instance: https://github.com/iGhibli/iOS-DeviceSupport/issues/151

Thanks

  • Ok update 😄 I fixed it by using DevCleaner, cleaning the build, unpairing the iPhone and then switching it off.

    I switched it back on while plugged in and then Xcode no longer gave the above mentioned error.

    Hope it works for the work device too 🤞

Add a Comment

Earlier I wrote:

if this problem affected all iOS developers then this thread would be many pages long!

And we just got an example of this. It seems that Xcode 14.0 is not able to work with iOS 15.7. Apple reacted to that problem very quickly. And, yes, the associated DevForums thread is quite long (-: (although not as long as it might be because there’s a relatively straightforward workaround).

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"