Several users are seeing a crash in a new app version that introduces the use of a UITabBarController. We haven't been able to isolate the crash to a specific user flow, device, or OS version.
Fatal Exception: NSInternalInconsistencyException
Inconsistency in UITabBar items and view controllers detected. No view controller matches the UITabBarItem '<UITabBarItem: 0x130623160> title='Today' image=<UIImage:0x3001893b0 named(RootTab-resources: today) {36, 32} renderingMode=automatic(original)> selected'.
0 CoreFoundation 0x83f20 __exceptionPreprocess
1 libobjc.A.dylib 0x16018 objc_exception_throw
2 Foundation 0x6de868 _userInfoForFileAndLine
3 UIKitCore 0x85c9d8 -[UITabBarController _viewControllerForTabBarItem:]
4 UIKitCore 0x85ca80 -[UITabBarController _tabBarItemClicked:]
5 UIKitCore 0x3fb31c -[UIApplication sendAction:to:from:forEvent:]
6 UIKitCore 0x785d18 -[UITabBar _sendAction:withEvent:]
7 UIKitCore 0x3fb31c -[UIApplication sendAction:to:from:forEvent:]
8 UIKitCore 0x3fb1f4 -[UIControl sendAction:to:forEvent:]
9 UIKitCore 0x3fb044 -[UIControl _sendActionsForEvents:withEvent:]
10 UIKitCore 0x787054 -[UITabBar _buttonUp:]
11 UIKitCore 0x3fb31c -[UIApplication sendAction:to:from:forEvent:]
12 UIKitCore 0x3fb1f4 -[UIControl sendAction:to:forEvent:]
13 UIKitCore 0x3fb044 -[UIControl _sendActionsForEvents:withEvent:]
14 UIKitCore 0x913894 -[UIControl touchesEnded:withEvent:]
15 UIKitCore 0x33beac -[UIWindow _sendTouchesForEvent:]
16 UIKitCore 0x33b954 -[UIWindow sendEvent:]
17 UIKitCore 0x1bc9e0 -[UIApplication sendEvent:]
18 UIKitCore 0x1be1d4 __dispatchPreprocessedEventFromEventQueue
19 UIKitCore 0x1c6ecc __processEventQueue
20 UIKitCore 0xb984c updateCycleEntry
21 UIKitCore 0xb776c _UIUpdateSequenceRun
22 UIKitCore 0xb73b0 schedulerStepScheduledMainSection
23 UIKitCore 0xb8254 runloopSourceCallback
24 CoreFoundation 0x56834 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__
25 CoreFoundation 0x567c8 __CFRunLoopDoSource0
26 CoreFoundation 0x54298 __CFRunLoopDoSources0
27 CoreFoundation 0x53484 __CFRunLoopRun
28 CoreFoundation 0x52cd8 CFRunLoopRunSpecific
29 GraphicsServices 0x11a8 GSEventRunModal
30 UIKitCore 0x40a90c -[UIApplication _run]
31 UIKitCore 0x4be9d0 UIApplicationMain
32 Coach 0x62a44 main + 14 (main.m:14)
33 ??? 0x1bcfd9e4c (Missing)
I have only found 2 references to this exception online and neither of them have a resolution:
https://stackoverflow.com/questions/77536249/embed-flutterviewcontroller-to-native-swift-tabbar
https://github-com.translate.goog/ChenYilong/CYLTabBarController/issues/608?_x_tr_sl=zh-CN&_x_tr_tl=en&_x_tr_hl=en&_x_tr_pto=sc
Any ideas on how this can be further investigated or resolved?
Post
Replies
Boosts
Views
Activity
I've started seeing several users getting an app crash that I've been unable to find the root cause for so far. I've tried running the app in release build with address sanitizer and zombie objects checks enabled but have been unable to reproduce it. It only occurs for iOS 17 users. Any ideas on how I can troubleshoot this?
Crashed: com.apple.main-thread
EXC_BAD_ACCESS KERN_INVALID_ADDRESS 0x0000000000000000
Crashed: com.apple.main-thread
0 libsystem_platform.dylib 0xed4 _platform_memmove + 52
1 QuartzCore 0x137120 CA::Render::InterpolatedFunction::encode(CA::Render::Encoder*) const + 248
2 QuartzCore 0x136f40 CA::Render::GradientLayer::encode(CA::Render::Encoder*) const + 44
3 QuartzCore 0x2e384 CA::Render::Layer::encode(CA::Render::Encoder*) const + 284
4 QuartzCore 0x2e224 CA::Render::encode_set_object(CA::Render::Encoder*, unsigned long, unsigned int, CA::Render::Object*, unsigned int) + 196
5 QuartzCore 0x2b654 invocation function for block in CA::Context::commit_transaction(CA::Transaction*, double, double*) + 244
6 QuartzCore 0x2b4fc CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 368
7 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
8 QuartzCore 0x2b4bc CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 304
9 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
10 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
11 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
12 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
13 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
14 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
15 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
16 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
17 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
18 QuartzCore 0x2b488 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block_pointer) + 252
19 QuartzCore 0x6fc60 CA::Context::commit_transaction(CA::Transaction*, double, double*) + 11192
20 QuartzCore 0x66574 CA::Transaction::commit() + 648
21 UIKitCore 0x31b5ec __34-[UIApplication _firstCommitBlock]_block_invoke_2 + 36
22 CoreFoundation 0x373a8 __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 28
23 CoreFoundation 0x35b9c __CFRunLoopDoBlocks + 356
24 CoreFoundation 0x33a9c __CFRunLoopRun + 848
25 CoreFoundation 0x33668 CFRunLoopRunSpecific + 608
26 GraphicsServices 0x35ec GSEventRunModal + 164
27 UIKitCore 0x22c2b4 -[UIApplication _run] + 888
28 UIKitCore 0x22b8f0 UIApplicationMain + 340
29 Coach 0x799d8 main + 14 (main.m:14)
30 ??? 0x1abefadcc (Missing)