[Update: this was fixed in newer Unity versions, see the comments below]
Describe the bug
Unity will instantly crash when ran on an iOS 16 device using Xcode 14.
This will cause an app using flutter_unity_widget to crash on the splash screen.
The exact same project will run like normal with Xcode 14 on iPadOS 15, and probably iOS 15 too.
Looks like the issue was already reported to Flutter here by @RoyalCoder88, but it was closed because it is a Unity issue.
Given that we use Unity here, it is important to document this crash here.
I'm not sure which exact Unity versions have this error, but I've seen multiple 2021.3.x versions mentioned.
To Reproduce
My setup:
Unity 2021.3.6
flutter_unity_widget 2022.2.0
iPhone XS with iOS16
Xcode 14.0.1
Setup the example project, and export iOS in the Unity project.
In Xcode go to Product > Scheme > Edit Scheme > Run > Diagnostics (shortcut ⌘ <).
Now disable Thread Performance Checker.
Changing this setting has stopped the crash for me.
Related
For another iOS 16 crash, this other Unity forum thread mentions random crashes in AR on iOS 16. Here disabling Multi-threaded rendering in the Unity player settings seems to get rid of the crashes.
Error messages
Some text visible in Xcode for Future search engine hits:
~AutoLock [inlined]
Thread 1: EXC_BREAKPOINT (code=1, subcode=0x1115cccb0)
warning: UnityFramework was compiled with optimization - stepping may behave oddly; variables may not be available.
(lldb)
[Update: this was fixed in newer Unity versions, see the comments below]
Describe the bug Unity will instantly crash when ran on an iOS 16 device using Xcode 14. This will cause an app using
flutter_unity_widget
to crash on the splash screen. The exact same project will run like normal with Xcode 14 on iPadOS 15, and probably iOS 15 too.Looks like the issue was already reported to Flutter here by @RoyalCoder88, but it was closed because it is a Unity issue. Given that we use Unity here, it is important to document this crash here.
I'm not sure which exact Unity versions have this error, but I've seen multiple 2021.3.x versions mentioned.
To Reproduce My setup:
Solution This unity forum thread has a workaround.
In Xcode go to
Product > Scheme > Edit Scheme > Run > Diagnostics
(shortcut⌘ <
). Now disableThread Performance Checker
.Changing this setting has stopped the crash for me.
Related For another iOS 16 crash, this other Unity forum thread mentions random crashes in AR on iOS 16. Here disabling Multi-threaded rendering in the Unity player settings seems to get rid of the crashes.
Error messages Some text visible in Xcode for Future search engine hits: