The application crashes in the App Store when launch on iPhone with iOS 15.3.1.

My application is currently crashing in production in iPhone devices running iOS 15.x. The app will work as normal while running developer mode, enterprise builds and Test Flight builds. Unfortunately, I am unable to reproduce this issue even app is downloaded from the app store. I observed crash is happening at main.m. Can someone help me to reproduce this issue? How to read this crash log file?

Please find the crash log details attached.

Exception Type:  EXC_CRASH (SIGABRT)

This indicates that the app crashed itself by calling abort. The presence of the Last Exception Backtrace section confirms that this was caused by an unhandled language exception:

Last Exception Backtrace:
0   CoreFoundation    … __exceptionPreprocess + 220 (NSException.m:200)
1   libobjc.A.dylib   … objc_exception_throw + 60 (objc-exception.mm:565)
2   UIKitCore         … -[UIViewController _presentViewController:withAnimationController:completion:] + 5616 …
3   UIKitCore         … __63-[UIViewController _presentViewController:animated:completion:]_block_invoke + 108 …
4   UIKitCore         … -[UIViewController _performCoordinatedPresentOrDismiss:animated:] + 536 …
5   UIKitCore         … -[UIViewController _presentViewController:animated:completion:] + 208 …
6   UIKitCore         … -[UIViewController presentViewController:animated:completion:] + 188 …
7   libdispatch.dylib … _dispatch_call_block_and_release + 32 (init.c:1517)

The backtrace indicates that you’re tripping an assert in the UIKit view controller presentation subsystem. I’m not a UIKit expert, so I can’t offer any further insight. I’ve added the UIKit tag to your question and hopefully someone else can chime in.

Share and Enjoy

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

I have same problem. how to solve it?

So many crashes of presentViewController, we are seeing from Nov 2023. Two of them were because of viewWillTransition and UIAlertController, so we fully removed these two from our app.

But now, after removing , we saw this issue popping up again showing GameCenterUI.

Last Exception Backtrace:
0   CoreFoundation                	0x193c28f20 __exceptionPreprocess + 164 (NSException.m:249)
1   libobjc.A.dylib               	0x18bad2018 objc_exception_throw + 60 (objc-exception.mm:356)
2   UIKitCore                     	0x196394154 -[UIViewController _presentViewController:withAnimationController:completion:] + 4272 (UIViewController.m:0)
3   UIKitCore                     	0x1963957e4 __63-[UIViewController _presentViewController:animated:completion:]_block_invoke + 88 (UIViewController.m:9733)
4   UIKitCore                     	0x19638f81c -[UIViewController _performCoordinatedPresentOrDismiss:animated:] + 484 (UIViewController.m:9999)
5   UIKitCore                     	0x19638f544 -[UIViewController _presentViewController:animated:completion:] + 188 (UIViewController.m:9740)
6   UIKitCore                     	0x19638f3d8 -[UIViewController presentViewController:animated:completion:] + 164 (UIViewController.m:9936)
7   GameCenterUICore              	0x21941d91c -[GKLocalPlayer(iOSAuthenticationUI) showViewController:usingPresentingViewController:wrapInNavController:] + 492 (GKLocalPlayer+iOSAuthenticationUI.m:87)
8   GameCenterUI                  	0x1bc2db5f8 __87-[GKLocalPlayer(AuthenticationExtras) showOnboardingUIFromViewController:signInOrigin:]_block_invoke.20 + 64 (GKLocalPlayer+AuthenticationExtras.m:248)
9   libdispatch.dylib             	0x19bacddd4 _dispatch_client_callout + 20 (object.m:576)
10  libdispatch.dylib             	0x19bad12d8 _dispatch_continuation_pop + 600 (queue.c:321)
11  libdispatch.dylib             	0x19bae51c8 _dispatch_source_latch_and_call + 420 (source.c:596)
12  libdispatch.dylib             	0x19bae3d8c _dispatch_source_invoke + 832 (source.c:961)
13  libdispatch.dylib             	0x19badc4b4 _dispatch_main_queue_drain + 748 (queue.c:7898)
14  libdispatch.dylib             	0x19badc1b8 _dispatch_main_queue_callback_4CF + 44 (queue.c:8058)
15  CoreFoundation                	0x193bfb710 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 16 (CFRunLoop.c:1780)
16  CoreFoundation                	0x193bf8914 __CFRunLoopRun + 1996 (CFRunLoop.c:3149)
17  CoreFoundation                	0x193bf7cd8 CFRunLoopRunSpecific + 608 (CFRunLoop.c:3420)
18  GraphicsServices              	0x1d8aa81a8 GSEventRunModal + 164 (GSEvent.c:2196)
19  UIKitCore                     	0x19623090c -[UIApplication _run] + 888 (UIApplication.m:3713)
20  UIKitCore                     	0x1962e49d0 UIApplicationMain + 340 (UIApplication.m:5303)
21  MyApp           	0x102875f7c main + 64 (AppDelegate.swift:20)
22  dyld                          	0x1b72a9e4c start + 2240 (dyldMain.cpp:1298)

After adding GameCenter 72 days ago and 60k session, we see this crash. Surprising , we updated our app 5 days ago with removing viewwilltransition & uialertccontroller so that presentviewcontroller dont happen.

But this popped up first and only time now.

The code for GameCenter, we are using in our UIKit code is - https://github.com/fserrazes/GameCenterKit

The application crashes in the App Store when launch on iPhone with iOS 15.3.1.
 
 
Q