gpt4 book ai didi

ios - 致命异常: NSInternalInconsistencyException how to find offending code?

转载 作者:行者123 更新时间:2023-12-01 17:45:28 25 4
gpt4 key购买 nike

我在实时应用程序中遇到了随机崩溃。我知道如何解决它。我想知道如何找出有问题的代码,因为 crashlytics 日志在我的应用程序中没有显示任何代码。这是 crashlytics 崩溃吗?

由于它是随机崩溃,我无法调试它。

任何找出违规代码的指针将不胜感激。

Fatal Exception: NSInternalInconsistencyException
Modifications to the layout engine must not be performed from a background thread after it has been accessed from the main thread.


Fatal Exception: NSInternalInconsistencyException
0 CoreFoundation 0x196676a48 __exceptionPreprocess
1 libobjc.A.dylib 0x19639dfa4 objc_exception_throw
2 Foundation 0x196b4cf08 -[NSISEngine tryToOptimizeReturningMutuallyExclusiveConstraints]
3 Foundation 0x196957d34 -[NSISEngine _optimizeWithoutRebuilding]
4 Foundation 0x196957c4c -[NSISEngine optimize]
5 Foundation 0x1969578c0 -[NSISEngine performPendingChangeNotifications]
6 UIKitCore 0x19ab6c9e0 -[UIView(Hierarchy) layoutSubviews]
7 UIKitCore 0x19ab7f3d0 -[UIView(CALayerDelegate) layoutSublayersOfLayer:]
8 QuartzCore 0x19d0e27dc -[CALayer layoutSublayers]
9 QuartzCore 0x19d0e8958 CA::Layer::layout_if_needed(CA::Transaction*)
10 QuartzCore 0x19d0f3578 CA::Layer::layout_and_display_if_needed(CA::Transaction*)
11 QuartzCore 0x19d03bf1c CA::Context::commit_transaction(CA::Transaction*, double)
12 QuartzCore 0x19d065c08 CA::Transaction::commit()
13 QuartzCore 0x19d066b8c CA::Transaction::release_thread(void*)
14 libsystem_pthread.dylib 0x196394fb0 _pthread_tsd_cleanup
15 libsystem_pthread.dylib 0x196391de8 _pthread_exit
16 libsystem_pthread.dylib 0x196392e7c _pthread_wqthread_legacy_worker_wrap
17 libsystem_pthread.dylib 0x196392c18 _pthread_wqthread
18 libsystem_pthread.dylib 0x196395760 start_wqthread


Crashed: com.twitter.crashlytics.ios.exception
EXC_BREAKPOINT 0x00000001962dd8e0
Crashed: com.twitter.crashlytics.ios.exception
0 myApp 0x10101f028 CLSProcessRecordAllThreads + 376 (CLSProcess.c:376)
1 myApp 0x10101f410 CLSProcessRecordAllThreads + 407 (CLSProcess.c:407)
2 myApp 0x10100f114 CLSHandler + 26 (CLSHandler.m:26)
3 myApp 0x10101d63c __CLSExceptionRecord_block_invoke + 198 (CLSException.mm:198)
4 libdispatch.dylib 0x196343184 _dispatch_client_callout + 16
5 libdispatch.dylib 0x1962f5c04 _dispatch_lane_barrier_sync_invoke_and_complete + 56
6 myApp 0x10101d0e4 CLSExceptionRecord + 205 (CLSException.mm:205)
7 myApp 0x10101cf18 CLSExceptionRecordNSException + 102 (CLSException.mm:102)
8 myApp 0x10101cb3c CLSTerminateHandler() + 258 (CLSException.mm:258)
9 libc++abi.dylib 0x196443304 std::__terminate(void (*)()) + 16
10 libc++abi.dylib 0x196442c58 __cxa_get_exception_ptr + 30
11 libc++abi.dylib 0x196442c18 __cxxabiv1::exception_cleanup_func(_Unwind_Reason_Code, _Unwind_Exception*) + 122
12 libobjc.A.dylib 0x19639e0d0 _objc_exception_destructor(void*) + 354
13 Foundation 0x196b4cf08 -[NSISEngine tryToOptimizeReturningMutuallyExclusiveConstraints] + 318
14 Foundation 0x196957d34 -[NSISEngine _optimizeWithoutRebuilding] + 68
15 Foundation 0x196957c4c -[NSISEngine optimize] + 112
16 Foundation 0x1969578c0 -[NSISEngine performPendingChangeNotifications] + 112
17 UIKitCore 0x19ab6c9e0 -[UIView(Hierarchy) layoutSubviews] + 308
18 UIKitCore 0x19ab7f3d0 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 2140
19 QuartzCore 0x19d0e27dc -[CALayer layoutSublayers] + 284
20 QuartzCore 0x19d0e8958 CA::Layer::layout_if_needed(CA::Transaction*) + 480
21 QuartzCore 0x19d0f3578 CA::Layer::layout_and_display_if_needed(CA::Transaction*) + 136
22 QuartzCore 0x19d03bf1c CA::Context::commit_transaction(CA::Transaction*, double) + 304
23 QuartzCore 0x19d065c08 CA::Transaction::commit() + 676
24 QuartzCore 0x19d066b8c CA::Transaction::release_thread(void*) + 228
25 libsystem_pthread.dylib 0x196394fb0 _pthread_tsd_cleanup + 580
26 libsystem_pthread.dylib 0x196391de8 _pthread_exit + 80
27 libsystem_pthread.dylib 0x196392e7c _pthread_wqthread_legacy_worker_wrap + 94
28 libsystem_pthread.dylib 0x196392c18 _pthread_wqthread + 420
29 libsystem_pthread.dylib 0x196395760 start_wqthread + 8

最佳答案

我在来自广告 SDK 的崩溃中看到过类似的堆栈跟踪。您的应用程序中有广告吗?或者WKWebviews?如果是,请尝试禁用它们并检查崩溃是否仍然发生。

关于ios - 致命异常: NSInternalInconsistencyException how to find offending code?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59885732/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com