CF_IS_OBJC crash

Hi all. I've read all the posts related to CF_IS_OBJC, including this one, but since I don't have an Objective-C background and mostly work with Swift and SwiftUI, I'm struggling to fully understand the recommendations or how to address this issue. Could someone explain it to me in simple terms (like I'm 5) and provide a step-by-step guide on what to do? This crash has affected 66 devices over the past month.


Crashed: com.apple.main-thread
0  CoreFoundation                 0xf878 CF_IS_OBJC + 24
1  CoreFoundation                 0x17f58 CFArrayGetCount + 32
2  CoreGraphics                   0x322a1c CGPDFTaggedNodeEnumerateChildren + 60
3  CoreGraphics                   0x322880 CGPDFTaggedNodeGetBounds + 244
4  PDFKit                         0x5524 -[UICGPDFNodeAccessibilityElement isAccessibilityElement]
5  UIAccessibility                0x48518 ___axuiElementForNotificationData_block_invoke + 28
6  UIAccessibility                0x35678 __94-[NSObject(AXPrivCategory) _accessibilityFindFirstAXDescendantPassingTest:byYieldingElements:]_block_invoke_2 + 36
7  UIAccessibility                0x3534c __96-[NSObject(AXPrivCategory) _accessibilityEnumerateAXDescendants:passingTest:byYieldingElements:]_block_invoke + 60
8  UIAccessibility                0x359d0 __57-[NSObject(AXPrivCategory) _accessibilityFindDescendant:]_block_invoke_2 + 60
9  UIAccessibility                0x1ec98 -[NSObject(AXPrivCategory) accessibilityEnumerateContainerElementsWithOptions:usingBlock:] + 548
10 UIAccessibility                0x35858 __57-[NSObject(AXPrivCategory) _accessibilityFindDescendant:]_block_invoke + 176
11 UIAccessibility                0x3539c __96-[NSObject(AXPrivCategory) _accessibilityEnumerateAXDescendants:passingTest:byYieldingElements:]_block_invoke + 140
12 UIAccessibility                0x359d0 __57-[NSObject(AXPrivCategory) _accessibilityFindDescendant:]_block_invoke_2 + 60
13 UIAccessibility                0x1ec98 -[NSObject(AXPrivCategory) accessibilityEnumerateContainerElementsWithOptions:usingBlock:] + 548
14 UIAccessibility                0x35858 __57-[NSObject(AXPrivCategory) _accessibilityFindDescendant:]_block_invoke + 176
15 UIAccessibility                0x3539c __96-[NSObject(AXPrivCategory) _accessibilityEnumerateAXDescendants:passingTest:byYieldingElements:]_block_invoke + 140
16 UIAccessibility                0x359d0 __57-[NSObject(AXPrivCategory) _accessibilityFindDescendant:]_block_invoke_2 + 60
17 UIAccessibility                0x1ec98 -[NSObject(AXPrivCategory) accessibilityEnumerateContainerElementsWithOptions:usingBlock:] + 548
18 UIAccessibility                0x35858 __57-[NSObject(AXPrivCategory) _accessibilityFindDescendant:]_block_invoke + 176
19 UIAccessibility                0x3539c __96-[NSObject(AXPrivCategory) _accessibilityEnumerateAXDescendants:passingTest:byYieldingElements:]_block_invoke + 140
20 UIAccessibility                0x359d0 __57-[NSObject(AXPrivCategory) _accessibilityFindDescendant:]_block_invoke_2 + 60
21 UIAccessibility                0x1ec98 -[NSObject(AXPrivCategory) accessibilityEnumerateContainerElementsWithOptions:usingBlock:] + 548
22 UIAccessibility                0x35858 __57-[NSObject(AXPrivCategory) _accessibilityFindDescendant:]_block_invoke + 176
23 UIAccessibility                0x3539c __96-[NSObject(AXPrivCategory) _accessibilityEnumerateAXDescendants:passingTest:byYieldingElements:]_block_invoke + 140
24 UIAccessibility                0x35918 __57-[NSObject(AXPrivCategory) _accessibilityFindDescendant:]_block_invoke + 368
25 UIAccessibility                0x3539c __96-[NSObject(AXPrivCategory) _accessibilityEnumerateAXDescendants:passingTest:byYieldingElements:]_block_invoke + 140
26 UIAccessibility                0x35294 -[NSObject _accessibilityEnumerateAXDescendants:passingTest:byYieldingElements:] + 244
27 UIAccessibility                0x355d0 -[NSObject _accessibilityFindFirstAXDescendantPassingTest:byYieldingElements:] + 272
28 UIAccessibility                0x35788 -[NSObject(AXPrivCategory) _accessibilityFindDescendant:] + 100
29 UIAccessibility                0x48280 _axuiElementForNotificationData + 276
30 UIAccessibility                0x347c _massageAssociatedElementBeforePost + 36
31 UIAccessibility                0x2648 _UIAXBroadcastMainThread + 292
32 libdispatch.dylib              0x213c _dispatch_call_block_and_release + 32
33 libdispatch.dylib              0x3dd4 _dispatch_client_callout + 20
34 libdispatch.dylib              0x125a4 _dispatch_main_queue_drain + 988
35 libdispatch.dylib              0x121b8 _dispatch_main_queue_callback_4CF + 44
36 CoreFoundation                 0x56710 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 16
37 CoreFoundation                 0x53914 __CFRunLoopRun + 1996
38 CoreFoundation                 0x52cd8 CFRunLoopRunSpecific + 608
39 GraphicsServices               0x11a8 GSEventRunModal + 164
40 UIKitCore                      0x40a90c -[UIApplication _run] + 888
41 UIKitCore                      0x4be9d0 UIApplicationMain + 340
42 UIKitCore                      0x638384 keypath_get_selector_hoverStyle + 11024
43 Wisconsin State Journal        0x3b4ae8 main + 4299246312 (AppDelegate.swift:4299246312)
44 ???                            0x1b7239e4c (Missing)

com.apple.uikit.eventfetch-thread
0  libsystem_kernel.dylib         0x1808 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x5008 mach_msg2_internal + 80
2  libsystem_kernel.dylib         0x4f20 mach_msg_overwrite + 436
3  libsystem_kernel.dylib         0x4d60 mach_msg + 24
4  CoreFoundation                 0x53f5c __CFRunLoopServiceMachPort + 160
5  CoreFoundation                 0x53600 __CFRunLoopRun + 1208
6  CoreFoundation                 0x52cd8 CFRunLoopRunSpecific + 608
7  Foundation                     0xc7e4c -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212
8  Foundation                     0xc7c9c -[NSRunLoop(NSRunLoop) runUntilDate:] + 64
9  UIKitCore                      0x41e640 -[UIEventFetcher threadMain] + 420
10 Foundation                     0xde718 __NSThread__start__ + 732
11 libsystem_pthread.dylib        0x606c _pthread_start + 136
12 libsystem_pthread.dylib        0x10d8 thread_start + 8

com.google.firebase.crashlytics.MachExceptionServer
0  Wisconsin State Journal        0x83b668 FIRCLSProcessRecordAllThreads + 392 (FIRCLSProcess.c:392)
1  Wisconsin State Journal        0x83ba48 FIRCLSProcessRecordAllThreads + 423 (FIRCLSProcess.c:423)
2  Wisconsin State Journal        0x849c5c FIRCLSHandler + 34 (FIRCLSHandler.m:34)
3  Wisconsin State Journal        0x84a460 FIRCLSMachExceptionServer + 521 (FIRCLSMachException.c:521)
4  libsystem_pthread.dylib        0x606c _pthread_start + 136
5  libsystem_pthread.dylib        0x10d8 thread_start + 8

Thread
0  libsystem_kernel.dylib         0x1808 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x5008 mach_msg2_internal + 80
...
Answered by DTS Engineer in 801940022

As a first step, I suggest that you remove your third-party crash reporter. Debugging problems like this is hard, and third-party crash reporters make it harder. See Implementing Your Own Crash Reporter for more on that.

Once you have a ‘clean’ Apple crash report, please post an example here. It may offer some clues beyond the excerpt in your original post. See Posting a Crash Report for advice on how to post you crash report.

Problems like this are almost always the result of a memory management issue. And how you debug them depends on how reproducible they are:

This crash has affected 66 devices over the past month.

It sounds like you’re trying to debug this based on crash reports coming in from the field. That not easy. A good first step is to apply the standard memory debugging tools to see if you can make the problem more reproducible. If so, that’ll make debugging it more feasible.

Share and Enjoy

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

As a first step, I suggest that you remove your third-party crash reporter. Debugging problems like this is hard, and third-party crash reporters make it harder. See Implementing Your Own Crash Reporter for more on that.

Once you have a ‘clean’ Apple crash report, please post an example here. It may offer some clues beyond the excerpt in your original post. See Posting a Crash Report for advice on how to post you crash report.

Problems like this are almost always the result of a memory management issue. And how you debug them depends on how reproducible they are:

This crash has affected 66 devices over the past month.

It sounds like you’re trying to debug this based on crash reports coming in from the field. That not easy. A good first step is to apply the standard memory debugging tools to see if you can make the problem more reproducible. If so, that’ll make debugging it more feasible.

Share and Enjoy

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

CF_IS_OBJC crash
 
 
Q