Date/Time: 2021-06-29 17:50:42.4355 +0800
Launch Time: 2021-06-29 17:50:41.8504 +0800
OS Version: iPhone OS 14.6 (18F72)
Release Type: User
Baseband Version: 2.05.01
Report Version: 104
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Triggered by Thread: 3
Last Exception Backtrace:
0 CoreFoundation 0x182076754 __exceptionPreprocess + 220 (NSException.m:199)
1 libobjc.A.dylib 0x196b3d7a8 objc_exception_throw + 60 (objc-exception.mm:565)
2 CoreFoundation 0x181f79c3c -[NSObject(NSObject) doesNotRecognizeSelector:] + 144 (NSObject.m:146)
3 CoreFoundation 0x1820792ac ___forwarding___ + 1444 (NSForwarding.m:3651)
4 CoreFoundation 0x18207b5b0 _CF_forwarding_prep_0 + 96
5 UIKitCore 0x184ce9288 -[_UIContentSizeCategoryPreferenceSystem _updateContentSizeCategory:carPlay:postingNotification:] + 320 (UIContentSizeCategoryPreference.m:371)
6 UIKitCore 0x184ce9124 -[_UIContentSizeCategoryPreferenceSystem _updateContentSizeCategoriesFromUserDefaultsPostingNotification:] + 112 (UIContentSizeCategoryPreference.m:334)
7 UIKitCore 0x184ce8d30 -[_UIContentSizeCategoryPreferenceSystem _readAndObservePreferences] + 36 (UIContentSizeCategoryPreference.m:269)
8 UIKitCore 0x184ce85ec +[UIContentSizeCategoryPreference system] + 84 (UIContentSizeCategoryPreference.m:148)
9 UIKitCore 0x18464c608 -[UIScreen _defaultTraitCollectionForInterfaceOrientation:inBounds:] + 488 (UIScreen.m:2147)
10 UIKitCore 0x18464cb28 -[UIScreen _updateTraits] + 52 (UIScreen.m:2326)
11 UIKitCore 0x18464b598 -[UIScreen _connectScreen] + 64 (UIScreen.m:1865)
12 UIKitCore 0x1846470f0 +[UIScreen _FBSDisplayConfigurationConnected:forInitialDisplayContext:andNotify:forceMain:] + 264 (UIScreen.m:740)
13 UIKitCore 0x184645b5c +[UIScreen initialize] + 220 (UIScreen.m:577)
14 libobjc.A.dylib 0x196b16c40 CALLING_SOME_+initialize_METHOD + 24 (objc-initialize.mm:384)
15 libobjc.A.dylib 0x196b1d4bc initializeNonMetaClass + 788 (objc-initialize.mm:554)
16 libobjc.A.dylib 0x196b1ea9c initializeAndMaybeRelock(objc_class*, objc_object*, mutex_tt<false>&, bool) + 280 (objc-runtime-new.mm:2221)
17 libobjc.A.dylib 0x196b2db74 lookUpImpOrForward + 992 (objc-runtime-new.mm:2237)
18 libobjc.A.dylib 0x196b17644 _objc_msgSend_uncached + 68
19 UIKitCore 0x18464b1c4 _UIScreenForcedMainScreenScale + 56 (UIScreen.m:3487)
20 UIKitCore 0x184606138 _UIGraphicsBeginImageContextWithOptions + 72 (UIGraphics.m:382)
21 Lazada 0x10221199c __40+[LAMainViewController transparentImage]_block_invoke + 27433372 (LAMainViewController.m:106)
22 libdispatch.dylib 0x181c6381c _dispatch_client_callout + 20 (object.m:559)
23 libdispatch.dylib 0x181c650b4 _dispatch_once_callout + 32 (once.c:52)
24 Lazada 0x102211960 +[LAMainViewController transparentImage] + 27433312 (LAMainViewController.m:103)
25 Lazada 0x102211918 __28+[LAMainViewController load]_block_invoke + 27433240 (LAMainViewController.m:95)
26 libdispatch.dylib 0x181c61a84 _dispatch_call_block_and_release + 32 (init.c:1466)
27 libdispatch.dylib 0x181c6381c _dispatch_client_callout + 20 (object.m:559)
28 libdispatch.dylib 0x181c66968 _dispatch_queue_override_invoke + 756 (inline_internal.h:2557)
29 libdispatch.dylib 0x181c74fe0 _dispatch_root_queue_drain + 388 (inline_internal.h:2598)
30 libdispatch.dylib 0x181c757d8 _dispatch_worker_thread2 + 112 (queue.c:6765)
31 libsystem_pthread.dylib 0x1cdbda768 _pthread_wqthread + 215
32 libsystem_pthread.dylib 0x1cdbe174c start_wqthread + 7
code-block
Please help ,app crash at [_UIContentSizeCategoryPreferenceSystem _updateContentSizeCategory:carPlay:postingNotification:]
I have the same problem !Have you solved it
In general, it's not good practice to put work in +load
or +initialize
. It's better to do this at a known time, like in init
when an object is created.
In this case, it looks like +[LAMainViewController load]
is running on a non-main queue (thread 3), which then results in some UIKit code running off the main queue. Moving this code onto the main queue might solve your problem.