As i understood, the threads provided by GCD do have a runloop but no source/port. Now i use some of methods that call AppleScripts thru AppleEvents inside an NSOperationQueue. And sometimes my app crashes with following stacktrace.
my questions:
Usage of AppleScript inside a NSInvocationOperation or NSBlockOperation
Usage of AppleEvents inside GCD-Threads
do i have to add a source / port to a runloop of a gcd-thread before using AppleEvents?
do i have to add a source / port to a runloop of a gcd-thread before using [CATransaction commit]?
do i have to add a source / port to a runloop of a gcd-thread before using [NSObject performSelectorAfterDelay...] ?
if yes, how?
can i simply call CFRunLoopRunInMode(kCFRunLoopDefaultMode, 5.0, false); /// or 30 or the defined timeout of appleevent?
..
Thread 9: Dispatch queue: com.apple.root.default-priority
0 libSystem.B.dylib 0x00007fff88276e82 semaphore_wait_signal_trap 10
1 libSystem.B.dylib 0x00007fff8827c3cd pthread_mutex_lock 469
2 com.apple.applescript 0x000000011d3d461f AppleScriptComponent 50
3 com.apple.applescript 0x000000011d3edbcc AGenericCall::Delegate(ComponentInstanceRecord*) 46
4 com.apple.applescript 0x000000011d3ed520 AGenericManager::HandleOSACall(ComponentParameters*) 54
5 com.apple.applescript 0x000000011d3ed4b0 GenericComponent 219
6 com.apple.openscripting 0x00007fff8381c6da OSAExecuteEvent 63
7 com.apple.Foundation 0x00007fff86f320d8 -[NSAppleScript(NSPrivate) _executeAppleEvent:withMode:error:] 161
8 xxx 0x0000000100048af0 -[TCallScript callScript:withArrayOfParameters:] 480
9 xxx 0x0000000100048ffd -[TCallScript callHandler:withParameters:] 477
10 xxx 0x0000000100036032 -[ZFOpenWindowController getSafariItemForCurrentTabForWindow:] 66
11 xxx 0x00000001000346af -[ZFOpenWindowController refreshWindowList:] 1679
12 xxx 0x000000010003541c -[ZFOpenWindowController bringZFToForegroundZoomOut:orJustLinkFrontMost:toItem:] 2988
13 xxx 0x0000000100053556 __-[ZFSelectionTool openWithPreferredApplication:]_block_invoke_516 54
14 com.apple.Foundation 0x00007fff86ed87d9 -[NSBlockOperation main] 140
15 com.apple.Foundation 0x00007fff86ec906d -[__NSOperationInternal start] 681
16 com.apple.Foundation 0x00007fff86ec8d23 ____startOperations_block_invoke_2 99
17 libSystem.B.dylib 0x00007fff882b2ce8 _dispatch_call_block_and_release 15
18 libSystem.B.dylib 0x00007fff88291279 _dispatch_worker_thread2 231
19 libSystem.B.dylib 0x00007fff88290bb8 _pthread_wqthread 353
20 libSystem.B.dylib 0x00007fff88290a55 start_wqthread 13
...
Thread 11 Crashed: Dispatch queue: com.apple.root.default-priority
0 com.apple.applescript 0x000000011d40f658 BCHandleError() 182
1 com.apple.applescript 0x000000011d4059ca UASExecute1() 2546
2 com.apple.applescript 0x000000011d3dd1d5 ASExecuteEvent(AEDesc const*, unsigned int, int, unsigned int*) 695
3 ...ple.CoreServices.CarbonCore 0x00007fff85388e04 CallComponentFunction 28
4 com.apple.applescript 0x000000011d3d4cad AppleScriptComponent 1728
5 com.apple.applescript 0x000000011d3edbcc AGenericCall::Delegate(ComponentInstanceRecord*) 46
6 com.apple.applescript 0x000000011d3ed520 AGenericManager::HandleOSACall(ComponentParameters*) 54
7 com.apple.applescript 0x000000011d3ed4b0 GenericComponent 219
8 com.apple.openscripting 0x00007fff8381c6da OSAExecuteEvent 63
9 com.apple.Foundation 0x00007fff86f320d8 -[NSAppleScript(NSPrivate) _executeAppleEvent:withMode:error:] 161
10 xxx 0x0000000100048af0 -[TCallScript callScript:withArrayOfParameters:] 480
11 xxx 0x0000000100048ffd -[TCallScript callHandler:withParameters:] 477
12 xxx 0x0000000100035c67 -[ZFOpenWindowController getItemForAXDocumentOfFrontMostWindow] 119
13 xxx 0x00000001000359f1 -[ZFOpenWindowController getItemForFrontMostWindow:] 721
14 xxx 0x00000001000348ac -[ZFOpenWindowController bringZFToForegroundZoomOut:orJustLinkFrontMost:toItem:] 60
15 xxx 0x0000000100053556 __-[ZFSelectionTool openWithPreferredApplication:]_block_invoke_516 54
16 com.apple.Foundation 0x00007fff86ed87d9 -[NSBlockOperation main] 140
17 com.apple.Foundation 0x00007fff86ec906d -[__NSOperationInternal start] 681
18 com.apple.Foundation 0x00007fff86ec8d23 ____startOperations_block_invoke_2 99
19 libSystem.B.dylib 0x00007fff882b2ce8 _dispatch_call_block_and_release 15
20 libSystem.B.dylib 0x00007fff88291279 _dispatch_worker_thread2 231
21 libSystem.B.dylib 0x00007fff88290bb8 _pthread_wqthread 353
22 libSystem.B.dylib 0x00007fff88290a55 start_wqthread 13
Note that the AppleScript component has limited thread safety. As of 10.6, you can use it on non-main threads, but you will need to create a new ComponentInstance for each thread. I think you can do this with OSAKit, otherwise you'll need to resort to the gnarly Carbon API. What's best really depends on what you're trying to achieve (e.g. are you running user-supplied scripts, or scripts hardcoded into your application, and what's the motivation for running them via NSOperationQueue).
Related
i have an issue with my (first) macOS app. A beta Tester gets a crash right on start of the app.
I am a bit puzzled as to why.
I have included the crashlytics framework (Version 3.9.3 (128)). It seems to me that is crashing while crashlytics is trying to send a report (from an earlier crash?).
has anyone experienced something similar?
2017-11-09 10:22:51.369 AquaCalculator[3959:1399290] [Crashlytics] Version 3.9.3 (128)
2017-11-09 10:22:51.464 AquaCalculator[3959:1399398] [Crashlytics:Crash:Reports] Packaged report with id '71a39da2c3fc41b9a563b6c2d0a20f8e' for submission
2017-11-09 10:22:52.966 AquaCalculator[3959:1399290] -[NSNull length]: unrecognized selector sent to instance 0x7fff94044b40
Illegal instruction: 4
logout
Saving session...
...copying shared history...
...saving history...truncating history files...
...completed.
Deleting expired sessions...none found.
more details from the crash report:
[Process completed]
Exception Type: EXC_BAD_INSTRUCTION (SIGILL)
Exception Codes: 0x0000000000000001, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Termination Signal: Illegal instruction: 4
Termination Reason: Namespace SIGNAL, Code 0x4
Terminating Process: exc handler [0]
Application Specific Information:
Crashing on exception: -[NSNull length]: unrecognized selector sent to instance 0x7fff94044b40
Application Specific Backtrace 1:
0 CoreFoundation 0x00007fff39dad14b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x00007fff60df2c76 objc_exception_throw + 48
2 CoreFoundation 0x00007fff39e45d64 -[NSObject(NSObject) doesNotRecognizeSelector:] + 132
3 CoreFoundation 0x00007fff39d23530 ___forwarding___ + 1456
4 CoreFoundation 0x00007fff39d22ef8 _CF_forwarding_prep_0 + 120
5 Foundation 0x00007fff3bf3739a getObjectValue + 444
6 Foundation 0x00007fff3bf37164 -[NSDateFormatter getObjectValue:forString:errorDescription:] + 471
7 Foundation 0x00007fff3bf36f79 -[NSDateFormatter dateFromString:] + 50
8 AquaCalculator 0x0000000100d56215 AquaCalculator + 115221
9 CFNetwork 0x00007fff38caf4ab __75-[__NSURLSessionLocal taskForClass:request:uploadFile:bodyData:completion:]_block_invoke + 19
10 CFNetwork 0x00007fff38caed05 __49-[__NSCFLocalSessionTask _task_onqueue_didFinish]_block_invoke + 147
11 Foundation 0x00007fff3beb925b __NSBLOCKOPERATION_IS_CALLING_OUT_TO_A_BLOCK__ + 7
12 Foundation 0x00007fff3beb90bd -[NSBlockOperation main] + 68
13 Foundation 0x00007fff3beb756a -[__NSOperationInternal _start:] + 778
14 libdispatch.dylib 0x00007fff619a8d50 _dispatch_client_callout + 8
15 libdispatch.dylib 0x00007fff619bb333 _dispatch_block_invoke_direct + 317
16 libdispatch.dylib 0x00007fff619a8d50 _dispatch_client_callout + 8
17 libdispatch.dylib 0x00007fff619bb333 _dispatch_block_invoke_direct + 317
18 libdispatch.dylib 0x00007fff619bb1d6 dispatch_block_perform + 109
19 Foundation 0x00007fff3beb3578 __NSOQSchedule_f + 342
20 libdispatch.dylib 0x00007fff619a8d50 _dispatch_client_callout + 8
21 libdispatch.dylib 0x00007fff619b432d _dispatch_main_queue_callback_4CF + 1148
22 CoreFoundation 0x00007fff39d658e9 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9
23 CoreFoundation 0x00007fff39d27b0a __CFRunLoopRun + 2586
24 CoreFoundation 0x00007fff39d26e63 CFRunLoopRunSpecific + 483
25 HIToolbox 0x00007fff3903fe26 RunCurrentEventLoopInMode + 286
26 HIToolbox 0x00007fff3903fb96 ReceiveNextEventCommon + 613
27 HIToolbox 0x00007fff3903f914 _BlockUntilNextEventMatchingListInModeWithFilter + 64
28 AppKit 0x00007fff37334483 _DPSNextEvent + 2085
29 AppKit 0x00007fff37ac9ff8 -[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 3044
30 AppKit 0x00007fff37329291 -[NSApplication run] + 764
31 AppKit 0x00007fff372f8436 NSApplicationMain + 804
32 libdyld.dylib 0x00007fff619e2115 start + 1
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 com.apple.AppKit 0x00007fff3765ec54 -[NSApplication _crashOnException:] + 109
1 com.apple.AppKit 0x00007fff3765eb3c -[NSApplication reportException:] + 953
2 com.apple.AppKit 0x00007fff377492ac uncaughtErrorProc + 157
3 com.apple.CoreFoundation 0x00007fff39e3f113 __handleUncaughtException + 771
4 libobjc.A.dylib 0x00007fff60df4e9d _objc_terminate() + 91
5 com.thallos.de.AquaCalculator 0x0000000100e31d39 0x100d3a000 + 1015097
6 libc++abi.dylib 0x00007fff5fa857c9 std::__terminate(void (*)()) + 8
7 libc++abi.dylib 0x00007fff5fa85843 std::terminate() + 51
8 libdispatch.dylib 0x00007fff619a8d64 _dispatch_client_callout + 28
9 libdispatch.dylib 0x00007fff619bb333 _dispatch_block_invoke_direct + 317
10 libdispatch.dylib 0x00007fff619a8d50 _dispatch_client_callout + 8
11 libdispatch.dylib 0x00007fff619bb333 _dispatch_block_invoke_direct + 317
12 libdispatch.dylib 0x00007fff619bb1d6 dispatch_block_perform + 109
13 com.apple.Foundation 0x00007fff3beb3578 __NSOQSchedule_f + 342
14 libdispatch.dylib 0x00007fff619a8d50 _dispatch_client_callout + 8
15 libdispatch.dylib 0x00007fff619b432d _dispatch_main_queue_callback_4CF + 1148
16 com.apple.CoreFoundation 0x00007fff39d658e9 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9
17 com.apple.CoreFoundation 0x00007fff39d27b0a __CFRunLoopRun + 2586
18 com.apple.CoreFoundation 0x00007fff39d26e63 CFRunLoopRunSpecific + 483
19 com.apple.HIToolbox 0x00007fff3903fe26 RunCurrentEventLoopInMode + 286
20 com.apple.HIToolbox 0x00007fff3903fb96 ReceiveNextEventCommon + 613
21 com.apple.HIToolbox 0x00007fff3903f914 _BlockUntilNextEventMatchingListInModeWithFilter + 64
22 com.apple.AppKit 0x00007fff37334483 _DPSNextEvent + 2085
23 com.apple.AppKit 0x00007fff37ac9ff8 -[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 3044
24 com.apple.AppKit 0x00007fff37329291 -[NSApplication run] + 764
25 com.apple.AppKit 0x00007fff372f8436 NSApplicationMain + 804
26 libdyld.dylib 0x00007fff619e2115 start + 1
Thread 1:
0 libsystem_kernel.dylib 0x00007fff61b32572 __workq_kernreturn + 10
1 libsystem_pthread.dylib 0x00007fff61c6d06a _pthread_wqthread + 1035
2 libsystem_pthread.dylib 0x00007fff61c6cc4d start_wqthread + 13
Thread 2:: Dispatch queue: io.answers.EventQueue (QOS: BACKGROUND)
0 com.apple.Foundation 0x00007fff3bef4016 -[NSFilesystemItemRemoveOperation delegate] + 0
1 com.apple.Foundation 0x00007fff3bef3f7b __NSRemoveFileConfirmCallback + 40
2 libremovefile.dylib 0x00007fff61a17861 __removefile_tree_walker + 181
3 libremovefile.dylib 0x00007fff61a17bd7 removefile + 151
4 com.apple.Foundation 0x00007fff3bef3e94 -[NSFilesystemItemRemoveOperation main] + 171
5 com.apple.Foundation 0x00007fff3beb756a -[__NSOperationInternal _start:] + 778
6 com.apple.Foundation 0x00007fff3bef3d23 -[NSFileManager removeItemAtPath:error:] + 84
7 com.thallos.de.AquaCalculator 0x0000000100e4e49b 0x100d3a000 + 1131675
8 com.thallos.de.AquaCalculator 0x0000000100e48f87 0x100d3a000 + 1109895
9 com.thallos.de.AquaCalculator 0x0000000100e48f09 0x100d3a000 + 1109769
10 com.thallos.de.AquaCalculator 0x0000000100e4e789 0x100d3a000 + 1132425
11 com.thallos.de.AquaCalculator 0x0000000100e433dc 0x100d3a000 + 1086428
12 com.thallos.de.AquaCalculator 0x0000000100e12aa6 0x100d3a000 + 887462
13 com.thallos.de.AquaCalculator 0x0000000100e1284f 0x100d3a000 + 886863
14 com.thallos.de.AquaCalculator 0x0000000100e12996 0x100d3a000 + 887190
15 com.thallos.de.AquaCalculator 0x0000000100e43261 0x100d3a000 + 1086049
16 com.thallos.de.AquaCalculator 0x0000000100e43127 0x100d3a000 + 1085735
17 com.thallos.de.AquaCalculator 0x0000000100e4e669 0x100d3a000 + 1132137
18 com.thallos.de.AquaCalculator 0x0000000100e4924f 0x100d3a000 + 1110607
19 com.apple.CFNetwork 0x00007fff38e68a9f __51-[NSURLSession delegate_task:didCompleteWithError:]_block_invoke.182 + 80
20 com.apple.Foundation 0x00007fff3beb925b __NSBLOCKOPERATION_IS_CALLING_OUT_TO_A_BLOCK__ + 7
21 com.apple.Foundation 0x00007fff3beb90bd -[NSBlockOperation main] + 68
22 com.apple.Foundation 0x00007fff3beb756a -[__NSOperationInternal _start:] + 778
23 libdispatch.dylib 0x00007fff619a8d50 _dispatch_client_callout + 8
24 libdispatch.dylib 0x00007fff619bb333 _dispatch_block_invoke_direct + 317
25 libdispatch.dylib 0x00007fff619a8d50 _dispatch_client_callout + 8
26 libdispatch.dylib 0x00007fff619bb333 _dispatch_block_invoke_direct + 317
27 libdispatch.dylib 0x00007fff619bb1d6 dispatch_block_perform + 109
28 com.apple.Foundation 0x00007fff3beb3578 __NSOQSchedule_f + 342
29 libdispatch.dylib 0x00007fff619a8d50 _dispatch_client_callout + 8
30 libdispatch.dylib 0x00007fff619bbe76 _dispatch_continuation_pop + 472
31 libdispatch.dylib 0x00007fff619b36cb _dispatch_async_redirect_invoke + 703
32 libdispatch.dylib 0x00007fff619aa941 _dispatch_root_queue_drain + 515
33 libdispatch.dylib 0x00007fff619aa6ed _dispatch_worker_thread3 + 101
34 libsystem_pthread.dylib 0x00007fff61c6d1ca _pthread_wqthread + 1387
35 libsystem_pthread.dylib 0x00007fff61c6cc4d start_wqthread + 13
Thread 3:
0 libsystem_kernel.dylib 0x00007fff61b32572 __workq_kernreturn + 10
1 libsystem_pthread.dylib 0x00007fff61c6d26f _pthread_wqthread + 1552
2 libsystem_pthread.dylib 0x00007fff61c6cc4d start_wqthread + 13
Thread 4:
0 libsystem_kernel.dylib 0x00007fff61b32572 __workq_kernreturn + 10
1 libsystem_pthread.dylib 0x00007fff61c6d06a _pthread_wqthread + 1035
2 libsystem_pthread.dylib 0x00007fff61c6cc4d start_wqthread + 13
Thread 5:
0 libsystem_kernel.dylib 0x00007fff61b32572 __workq_kernreturn + 10
1 libsystem_pthread.dylib 0x00007fff61c6d06a _pthread_wqthread + 1035
2 libsystem_pthread.dylib 0x00007fff61c6cc4d start_wqthread + 13
Thread 6:
0 libsystem_pthread.dylib 0x00007fff61c6cc40 start_wqthread + 0
1 ??? 0x00007ffd8ba0f350 0 + 140726946034512
Thread 7:
0 libsystem_kernel.dylib 0x00007fff61b32572 __workq_kernreturn + 10
1 libsystem_pthread.dylib 0x00007fff61c6d06a _pthread_wqthread + 1035
2 libsystem_pthread.dylib 0x00007fff61c6cc4d start_wqthread + 13
Thread 8:: com.twitter.crashlytics.mac.MachExceptionServer
0 libsystem_kernel.dylib 0x00007fff61b339e2 write + 10
1 com.thallos.de.AquaCalculator 0x0000000100e27b1e 0x100d3a000 + 973598
2 com.thallos.de.AquaCalculator 0x0000000100e1f15c 0x100d3a000 + 938332
3 libsystem_pthread.dylib 0x00007fff61c6d6c1 _pthread_body + 340
4 libsystem_pthread.dylib 0x00007fff61c6d56d _pthread_start + 377
5 libsystem_pthread.dylib 0x00007fff61c6cc5d thread_start + 13
Thread 9:
0 libsystem_pthread.dylib 0x00007fff61c6cc40 start_wqthread + 0
1 ??? 0x000070000303bbe0 0 + 123145352887264
Thread 10:: com.apple.NSEventThread
0 libsystem_kernel.dylib 0x00007fff61b288f2 mach_msg_trap + 10
1 libsystem_kernel.dylib 0x00007fff61b27e0c mach_msg + 60
2 com.apple.CoreFoundation 0x00007fff39d28495 __CFRunLoopServiceMachPort + 341
3 com.apple.CoreFoundation 0x00007fff39d277e7 __CFRunLoopRun + 1783
4 com.apple.CoreFoundation 0x00007fff39d26e63 CFRunLoopRunSpecific + 483
5 com.apple.AppKit 0x00007fff37471918 _NSEventThread + 184
6 libsystem_pthread.dylib 0x00007fff61c6d6c1 _pthread_body + 340
7 libsystem_pthread.dylib 0x00007fff61c6d56d _pthread_start + 377
8 libsystem_pthread.dylib 0x00007fff61c6cc5d thread_start + 13
Thread 11:: com.apple.NSURLConnectionLoader
0 libsystem_kernel.dylib 0x00007fff61b288f2 mach_msg_trap + 10
1 libsystem_kernel.dylib 0x00007fff61b27e0c mach_msg + 60
2 com.apple.CoreFoundation 0x00007fff39d28495 __CFRunLoopServiceMachPort + 341
3 com.apple.CoreFoundation 0x00007fff39d277e7 __CFRunLoopRun + 1783
4 com.apple.CoreFoundation 0x00007fff39d26e63 CFRunLoopRunSpecific + 483
5 com.apple.CFNetwork 0x00007fff38ec744c -[__CoreSchedulingSetRunnable runForever] + 722
6 com.apple.Foundation 0x00007fff3beabe78 __NSThread__start__ + 1197
7 libsystem_pthread.dylib 0x00007fff61c6d6c1 _pthread_body + 340
8 libsystem_pthread.dylib 0x00007fff61c6d56d _pthread_start + 377
9 libsystem_pthread.dylib 0x00007fff61c6cc5d thread_start + 13
Mike from Fabric here. I don't believe that this is a crash within Crashlytics. You'll see our threads referenced in most crash reports because our processes are waking up to catch the exception.
The error you're seeing is usually due to memory mismanagement or holding onto an object that's no longer present.
I'm using SinchRTC 3.11.1 in my IOS App. When I enter a video chat the following warnings are being produced because of the Sinch library. A few UI API calls are being done from a background thread instead of the main UI thread. Can these be fixed within the library?
Main Thread Checker: UI API called on a background thread: -[UIApplication applicationState]
PID: 96751, TID: 7066961, Thread name: Sinch Worker Thread, Queue name: com.apple.root.default-qos.overcommit, QoS: 21
Backtrace:
4 XXXXXX 0x0000000105d7eb41 -[SINClientImpl onPubSubSubscriptionConnectionEvent] + 66
5 XXXXXX 0x0000000105d7ec84 -[SINClientImpl onPubSubSubscriptionSuccess:] + 197
6 CoreFoundation 0x0000000108740a3c __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 12
7 CoreFoundation 0x000000010874093a _CFXRegistrationPost + 442
8 CoreFoundation 0x0000000108740682 ___CFXNotificationPost_block_invoke + 50
9 CoreFoundation 0x0000000108702a02 -[_CFXNotificationRegistrar find:object:observer:enumerator:] + 1826
10 CoreFoundation 0x0000000108701b7c _CFXNotificationPost + 652
11 Foundation 0x0000000109ec0172 -[NSNotificationCenter postNotificationName:object:userInfo:] + 66
12 XXXXXX 0x0000000105d9b8c7 -[SINPubSubscriber notify:userInfo:] + 336
13 XXXXXX 0x0000000105d9ba46 -[SINPubSubscriber subscribeDidSucceedOnChannel:sequence:withRequestedTimetoken:] + 220
14 XXXXXX 0x0000000105d92515 -[PubnubSubscriber request:withInitialTimeToken:didSucceedWithResponse:] + 435
15 XXXXXX 0x0000000105d920d5 __43-[PubnubSubscriber subscribeWithTimeToken:]_block_invoke + 111
16 XXXXXX 0x0000000105d909ce __52-[PubnubService performRequest:onSuccess:onFailure:]_block_invoke.42 + 143
17 XXXXXX 0x0000000105d8ffc9 -[PubnubRequestOperation operationWillFinish] + 284
18 XXXXXX 0x0000000105d6902d -[SINQRunLoopOperation finishWithError:] + 70
19 XXXXXX 0x0000000105d68536 -[SINQHTTPOperation finishWithError:] + 41
20 CFNetwork 0x0000000107f7e0e5 __65-[NSURLConnectionInternal _withConnectionAndDelegate:onlyActive:]_block_invoke + 53
21 CFNetwork 0x0000000107f7e00a -[NSURLConnectionInternal _withConnectionAndDelegate:onlyActive:] + 198
22 CFNetwork 0x0000000107f7df32 -[NSURLConnectionInternal _withActiveConnectionAndDelegate:] + 48
23 CFNetwork 0x0000000107f823b3 ___ZN27URLConnectionClient_Classic26_delegate_didFinishLoadingEU13block_pointerFvvE_block_invoke + 100
24 CFNetwork 0x00000001081283cb ___ZN27URLConnectionClient_Classic18_withDelegateAsyncEPKcU13block_pointerFvP16_CFURLConnectionPK33CFURLConnectionClientCurrent_VMaxE_block_invoke_2 + 100
25 libdispatch.dylib 0x0000000110e8a658 _dispatch_client_callout + 8
26 libdispatch.dylib 0x0000000110e8fe6b _dispatch_block_invoke_direct + 589
27 CFNetwork 0x0000000107f7de04 _ZN19RunloopBlockContext13_invoke_blockEPKvPv + 24
28 CoreFoundation 0x00000001086f35d8 CFArrayApplyFunction + 72
29 CFNetwork 0x0000000107f7dcda _ZN19RunloopBlockContext7performEv + 132
30 CFNetwork 0x0000000107f7db78 _ZN17MultiplexerSource7performEv + 282
31 CFNetwork 0x0000000107f7d9ab _ZN17MultiplexerSource8_performEPv + 65
32 CoreFoundation 0x0000000108747e71 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
33 CoreFoundation 0x000000010872c56f __CFRunLoopDoSources0 + 271
34 CoreFoundation 0x000000010872bb1f __CFRunLoopRun + 1039
35 CoreFoundation 0x000000010872b499 CFRunLoopRunSpecific + 409
36 Foundation 0x0000000109eda22e -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 274
37 XXXXXX 0x0000000105cf8bd8 _ZN4base20MessagePumpNSRunLoop2017-07-12 12:20:51.360149-0700 XXXXXX[96751:7066961] [reports] Main Thread Checker: UI API called on a background thread: -[UIApplication applicationState]
PID: 96751, TID: 7066961, Thread name: Sinch Worker Thread, Queue name: com.apple.root.default-qos.overcommit, QoS: 21
Backtrace:
4 XXXXXX 0x0000000105d7eb41 -[SINClientImpl onPubSubSubscriptionConnectionEvent] + 66
5 XXXXXX 0x0000000105d7ec84 -[SINClientImpl onPubSubSubscriptionSuccess:] + 197
6 CoreFoundation 0x0000000108740a3c __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 12
7 CoreFoundation 0x000000010874093a _CFXRegistrationPost + 442
8 CoreFoundation 0x0000000108740682 ___CFXNotificationPost_block_invoke + 50
9 CoreFoundation 0x0000000108702a02 -[_CFXNotificationRegistrar find:object:observer:enumerator:] + 1826
10 CoreFoundation 0x0000000108701b7c _CFXNotificationPost + 652
11 Foundation 0x0000000109ec0172 -[NSNotificationCenter postNotificationName:object:userInfo:] + 66
12 XXXXXX 0x0000000105d9b8c7 -[SINPubSubscriber notify:userInfo:] + 336
13 XXXXXX 0x0000000105d9ba46 -[SINPubSubscriber subscribeDidSucceedOnChannel:sequence:withRequestedTimetoken:] + 220
14 XXXXXX 0x0000000105d92515 -[PubnubSubscriber request:withInitialTimeToken:didSucceedWithResponse:] + 435
15 XXXXXX 0x0000000105d920d5 __43-[PubnubSubscriber subscribeWithTimeToken:]_block_invoke + 111
16 XXXXXX 0x0000000105d909ce __52-[PubnubService performRequest:onSuccess:onFailure:]_block_invoke.42 + 143
17 XXXXXX 0x0000000105d8ffc9 -[PubnubRequestOperation operationWillFinish] + 284
18 XXXXXX 0x0000000105d6902d -[SINQRunLoopOperation finishWithError:] + 70
19 XXXXXX 0x0000000105d68536 -[SINQHTTPOperation finishWithError:] + 41
20 CFNetwork 0x0000000107f7e0e5 __65-[NSURLConnectionInternal _withConnectionAndDelegate:onlyActive:]_block_invoke + 53
21 CFNetwork 0x0000000107f7e00a -[NSURLConnectionInternal _withConnectionAndDelegate:onlyActive:] + 198
22 CFNetwork 0x0000000107f7df32 -[NSURLConnectionInternal _withActiveConnectionAndDelegate:] + 48
23 CFNetwork 0x0000000107f823b3 ___ZN27URLConnectionClient_Classic26_delegate_didFinishLoadingEU13block_pointerFvvE_block_invoke + 100
24 CFNetwork 0x00000001081283cb ___ZN27URLConnectionClient_Classic18_withDelegateAsyncEPKcU13block_pointerFvP16_CFURLConnectionPK33CFURLConnectionClientCurrent_VMaxE_block_invoke_2 + 100
25 libdispatch.dylib 0x0000000110e8a658 _dispatch_client_callout + 8
26 libdispatch.dylib 0x0000000110e8fe6b _dispatch_block_invoke_direct + 589
27 CFNetwork 0x0000000107f7de04 _ZN19RunloopBlockContext13_invoke_blockEPKvPv + 24
28 CoreFoundation 0x00000001086f35d8 CFArrayApplyFunction + 72
29 CFNetwork 0x0000000107f7dcda _ZN19RunloopBlockContext7performEv + 132
30 CFNetwork 0x0000000107f7db78 _ZN17MultiplexerSource7performEv + 282
31 CFNetwork 0x0000000107f7d9ab _ZN17MultiplexerSource8_performEPv + 65
32 CoreFoundation 0x0000000108747e71 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
33 CoreFoundation 0x000000010872c56f __CFRunLoopDoSources0 + 271
34 CoreFoundation 0x000000010872bb1f __CFRunLoopRun + 1039
35 CoreFoundation 0x000000010872b499 CFRunLoopRunSpecific + 409
36 Foundation 0x0000000109eda22e -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 274
37 XXXXXX 0x0000000105cf8bd8 _ZN4base20MessagePumpNSRunLoop
=================================================================
Main Thread Checker: UI API called on a background thread: -[UIView layer]
PID: 96751, TID: 7066464, Thread name: (none), Queue name: com.sinch.SINVideoCapturer.session, QoS: 25
Backtrace:
4 XXXXXX 0x0000000105d66f4f -[SINVideoCapturer startWithPreset_sq:frameRate:] + 505
5 libdispatch.dylib 0x0000000110e8966d _dispatch_call_block_and_release + 12
6 libdispatch.dylib 0x0000000110e8a658 _dispatch_client_callout + 8
7 libdispatch.dylib 0x0000000110e9308c _dispatch_queue_serial_drain + 1173
8 libdispatch.dylib 0x0000000110e93aa5 _dispatch_queue_invoke + 342
9 libdispatch.dylib 0x0000000110e96d3b _dispatch_root_queue_drain + 785
10 libdispatch.dylib 0x0000000110e969c7 _dispatch_worker_thread4 + 54
11 libsystem_pthread.dylib 0x00000001112ed616 _pthread_wqthread + 1299
12 libsystem_pthread.dylib 0x00000001112ed0f1 start_wqthread + 13
2017-07-12 12:20:52.112965-0700 XXXXXX[96751:7066464] [reports] Main Thread Checker: UI API called on a background thread: -[UIView layer]
PID: 96751, TID: 7066464, Thread name: (none), Queue name: com.sinch.SINVideoCapturer.session, QoS: 25
Backtrace:
4 XXXXXX 0x0000000105d66f4f -[SINVideoCapturer startWithPreset_sq:frameRate:] + 505
5 libdispatch.dylib 0x0000000110e8966d _dispatch_call_block_and_release + 12
6 libdispatch.dylib 0x0000000110e8a658 _dispatch_client_callout + 8
7 libdispatch.dylib 0x0000000110e9308c _dispatch_queue_serial_drain + 1173
8 libdispatch.dylib 0x0000000110e93aa5 _dispatch_queue_invoke + 342
9 libdispatch.dylib 0x0000000110e96d3b _dispatch_root_queue_drain + 785
10 libdispatch.dylib 0x0000000110e969c7 _dispatch_worker_thread4 + 54
11 libsystem_pthread.dylib 0x00000001112ed616 _pthread_wqthread + 1299
12 libsystem_pthread.dylib 0x00000001112ed0f1 start_wqthread + 13
That is because Xcode 9 features a new main thread checker that checks whether UI API's are executed in Main thread. UI operations are bound to cause problems in a non-main thread. You have to update your SinchRTC to fix this runtime issue. The developers of SinchRTC should patch this and release an update. Hope this helps. For more info., refer this link.
The library should fix theses errors but if you want to disable it you can do it in the scheme, in the Diagnostics option.
A crash is occurring in my app but the crash report only shows system libraries. It is clear that my app is provoking the issue but because 1) of its size and 2) there isn't sign of any of my libraries in the stack trace, I can't figure out where it is happening. As far as I know it is related with NSUrlConnection but it is being used in lots of places.
Does any body knows how can I used Atos or lldb to symbolicate when my app is NOT being mentioned in the stack trace?
Below is the stack.
Thanks
Thread 33:: com.apple.NSURLConnectionLoader Dispatch queue: com.apple.CFFileDescriptor
0 com.apple.CoreFoundation 0x00007fff9d3a2add __CFFileDescriptorEnableCallBacks_block_invoke + 13
1 libdispatch.dylib 0x00007fff9b13440b _dispatch_client_callout + 8
2 libdispatch.dylib 0x00007fff9b1359f2 _dispatch_barrier_sync_f_invoke + 74
3 com.apple.CoreFoundation 0x00007fff9d3a2ab4 CFFileDescriptorEnableCallBacks + 180
4 com.apple.CoreFoundation 0x00007fff9d42cdaa constructCFFD + 122
5 com.apple.CoreFoundation 0x00007fff9d36e48e fileOpen + 238
6 com.apple.CoreFoundation 0x00007fff9d3626a8 _CFStreamOpen + 120
7 com.apple.CoreFoundation 0x00007fff9d36e37f CFReadStreamOpen + 95
8 com.apple.CFNetwork 0x00007fff911b27fe FileURLProtocol::_protocolInterface_startLoad(_CFCachedURLResponse const*) + 578
9 com.apple.CFNetwork 0x00007fff91041350 ___ZN19URLConnectionLoader27_private_ScheduleOriginLoadEPK12NSURLRequestPK20_CFCachedURLResponse_block_invoke_2 + 61
10 com.apple.CFNetwork 0x00007fff910412f1 ___ZNK19URLConnectionLoader25withExistingProtocolAsyncEU13block_pointerFvP11URLProtocolE_block_invoke + 25
11 libdispatch.dylib 0x00007fff9b13440b _dispatch_client_callout + 8
12 libdispatch.dylib 0x00007fff9b142039 _dispatch_block_invoke + 474
13 com.apple.CFNetwork 0x00007fff9104017c RunloopBlockContext::_invoke_block(void const*, void*) + 24
14 com.apple.CoreFoundation 0x00007fff9d33ad74 CFArrayApplyFunction + 68
15 com.apple.CFNetwork 0x00007fff91040075 RunloopBlockContext::perform() + 137
16 com.apple.CFNetwork 0x00007fff9103ff16 MultiplexerSource::perform() + 282
17 com.apple.CFNetwork 0x00007fff9103fd38 MultiplexerSource::_perform(void*) + 72
18 com.apple.CoreFoundation 0x00007fff9d398881 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
19 com.apple.CoreFoundation 0x00007fff9d377fbc __CFRunLoopDoSources0 + 556
20 com.apple.CoreFoundation 0x00007fff9d3774df __CFRunLoopRun + 927
21 com.apple.CoreFoundation 0x00007fff9d376ed8 CFRunLoopRunSpecific + 296
22 com.apple.CFNetwork 0x00007fff9101aa6d +[NSURLConnection(Loader) _resourceLoadLoop:] + 412
23 com.apple.Foundation 0x00007fff9b195e64 __NSThread__start__ + 1351
24 libsystem_pthread.dylib 0x00007fff9997a99d _pthread_body + 131
25 libsystem_pthread.dylib 0x00007fff9997a91a _pthread_start + 168
26 libsystem_pthread.dylib 0x00007fff99978351 thread_start + 13
I have an app on the Mac App Store, and I get these crash reports from my users which I cannot reproduce or figure out how to debug. It seem like something crashes due to NSManagedObjectContext reset, but it's not obvious, and users don't have a reproducible case. The main thread can have a different stack trace, but the non-main thread always has the same stack trace.
Exception Type: SIGSEGV
Exception Codes: SEGV_MAPERR at 0x41bfc026bec0
Crashed Thread: 8
Application Specific Information:
Selector name found in current argument registers: retain
Thread 0:
0 libFontParser.dylib 0x00007fff8efa7921 _ZNK20TTrueTypeFontHandler11RenderGlyphEtR27TTrueTypeQuadOutlineContextj + 89
1 libFontParser.dylib 0x00007fff8efa789e _ZNK20TTrueTypeFontHandler14GetOutlinePathEtRK18TGlyphOutlineBatch + 60
2 libFontParser.dylib 0x00007fff8efa744a FPFontCopyGlyphPath + 394
3 CoreGraphics 0x00007fff8767e913 CGFontCreateGlyphPath + 44
4 CoreGraphics 0x00007fff8767e85d CGFontCreateGlyphBitmap + 437
5 CoreGraphics 0x00007fff8767e607 _ZN14CGGlyphBuilder22create_missing_bitmapsEPK17CGGlyphIdentifiermPPK13CGGlyphBitmap + 109
6 libRIP.A.dylib 0x00007fff8b7bec2d render_glyphs + 204
7 libRIP.A.dylib 0x00007fff8b7bdf6f draw_glyph_bitmaps + 1585
8 libRIP.A.dylib 0x00007fff8b7bd8cd ripc_DrawGlyphs + 2785
9 CoreGraphics 0x00007fff87738077 draw_glyphs + 1034
10 CoreText 0x00007fff8ac50426 _ZL25DrawSbixGlyphsAtPositionsPK5TFontP6CGFontRK6TCFRefIPK8__CFDataEPKtPK7CGPointmP9CGContext17CGAffineTransformSI_ + 2990
11 CoreText 0x00007fff8abfdb73 CTFontDrawGlyphsWithAdvances + 789
12 UIFoundation 0x00007fff966f212e -[NSLineFragmentRenderingContext drawAtPoint:inContext:] + 5398
13 UIFoundation 0x00007fff96616728 __NSStringDrawingEngine + 16941
14 UIFoundation 0x00007fff966108ff _NSStringDrawingCore + 150
15 AppKit 0x00007fff93ce6d50 _NSDrawTextCell + 6954
16 AppKit 0x00007fff9421cdf8 __47-[NSTextFieldCell drawLayer:inGraphicsContext:]_block_invoke + 576
17 AppKit 0x00007fff944aa538 +[NSAppearance _performWithCurrentAppearance:usingBlock:] + 79
18 AppKit 0x00007fff93cf6739 -[NSTextFieldCell drawLayer:inGraphicsContext:] + 225
19 AppKit 0x00007fff93cf6470 +[NSGraphicsContext configureGraphicsContextForCALayer:withCGContext:andRenderWithHandler:] + 97
20 QuartzCore 0x00007fff939f1e93 CABackingStoreUpdate_ + 3306
21 QuartzCore 0x00007fff939f11a3 ___ZN2CA5Layer8display_Ev_block_invoke + 59
22 QuartzCore 0x00007fff939f115f x_blame_allocations + 81
23 QuartzCore 0x00007fff939f0c5c _ZN2CA5Layer8display_Ev + 1546
24 AppKit 0x00007fff93ce039f _NSBackingLayerDisplay + 617
25 QuartzCore 0x00007fff939f0381 _ZN2CA5Layer17display_if_neededEPNS_11TransactionE + 603
26 QuartzCore 0x00007fff939efabd _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 35
27 QuartzCore 0x00007fff939ef24e _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 242
28 QuartzCore 0x00007fff939eeea4 _ZN2CA11Transaction6commitEv + 390
29 QuartzCore 0x00007fff939ffcad _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 71
30 CoreFoundation 0x00007fff8bbd0da7 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
31 CoreFoundation 0x00007fff8bbd0d00 __CFRunLoopDoObservers + 368
32 CoreFoundation 0x00007fff8bbc2878 CFRunLoopRunSpecific + 328
33 HIToolbox 0x00007fff918f1aef RunCurrentEventLoopInMode + 235
34 HIToolbox 0x00007fff918f176e ReceiveNextEventCommon + 179
35 HIToolbox 0x00007fff918f16ab _BlockUntilNextEventMatchingListInModeWithFilter + 71
36 AppKit 0x00007fff93bb0f81 _DPSNextEvent + 964
37 AppKit 0x00007fff93bb0730 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 194
38 AppKit 0x00007fff93ba4593 -[NSApplication run] + 594
39 AppKit 0x00007fff93b8fa14 NSApplicationMain + 1832
40 libdyld.dylib 0x00007fff88d605c9 start + 1
...
Thread 7:
0 libsystem_kernel.dylib 0x00007fff94d1b94a __workq_kernreturn + 10
1 libsystem_pthread.dylib 0x00007fff9508740d start_wqthread + 13
Thread 8 Crashed:
0 libobjc.A.dylib 0x00007fff90c740dd objc_msgSend + 29
1 Foundation 0x00007fff92461d24 NSKeyValuePushPendingNotificationPerThread + 446
2 Foundation 0x00007fff9240968f NSKeyValueWillChange + 465
3 Foundation 0x00007fff924bc33e -[NSObject(NSKeyValueObservingPrivate) _willChangeValuesForKeys:] + 234
4 CoreData 0x00007fff8d9fdd6d -[NSFaultHandler turnObject:intoFaultWithContext:] + 221
5 CoreData 0x00007fff8da28641 -[NSManagedObjectContext(_NSInternalAdditions) _disposeObjects:count:notifyParent:] + 353
6 CoreData 0x00007fff8da27c78 -[NSManagedObjectContext(_NSInternalAdditions) _dispose:] + 392
7 CoreData 0x00007fff8da27821 -[NSManagedObjectContext _dealloc__] + 337
8 CoreData 0x00007fff8da563ab __internalBlockToDeallocNSManagedObjectContext_block_invoke + 75
9 CoreData 0x00007fff8da1c246 developerSubmittedBlockToNSManagedObjectContextPerform + 182
10 libdispatch.dylib 0x00007fff8f122c13 _dispatch_client_callout + 8
11 libdispatch.dylib 0x00007fff8f126365 _dispatch_queue_drain + 1100
12 libdispatch.dylib 0x00007fff8f127ecc _dispatch_queue_invoke + 202
13 libdispatch.dylib 0x00007fff8f1256b7 _dispatch_root_queue_drain + 463
14 libdispatch.dylib 0x00007fff8f133fe4 _dispatch_worker_thread3 + 91
15 libsystem_pthread.dylib 0x00007fff95089637 _pthread_wqthread + 729
16 libsystem_pthread.dylib 0x00007fff9508740d start_wqthread + 13
Any idea how to find out what's causing the issue and possibly fix it? I've tried enabling zombies, setting NSBindingDebugLogLevel to 1, and running Zombies instrument, but no luck.
I have a very specific web page that causes webview to crash with the Garnage Collector ON (does not crash when OFF).
Easy to reproduce: create a document base application, drop a webview, and have the following line (button perhaps).
- (void)connectSearch:(id)sender
{
[[webView mainFrame] loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:#"http://apple.com"]]];
}
I guess this scenario is only valid while Apple advertises their new iPad. At the bottom of the page there is two video you can watch. Click on the one on the right. When it is playing, click on the Close button (link) top left - which sends #SwapViewPreviousSelection - and that's it, it crashes.
I'm just learning about the garbage collector but I suspect something is collected that should not.
Any idea what can prevent the crash, other than turning off the garbage collector?
Thank you.
Here is what I get:
Identifier: com.yourcompany.wb
Version: 1.0 (1)
Code Type: X86-64 (Native)
Parent Process: launchd [163]
Date/Time: 2010-02-15 12:26:31.069 -0500
OS Version: Mac OS X 10.6.2 (10C540)
Report Version: 6
Interval Since Last Report: 432447 sec
Crashes Since Last Report: 7
Per-App Interval Since Last Report: 2938 sec
Per-App Crashes Since Last Report: 5
Anonymous UUID: CC123A77-1407-444A-9081-8A2B7C15C2B6
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Exception Codes: 0x0000000000000002, 0x0000000000000000
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Application Specific Information:
objc[70635]: garbage collection is ON
Thread 0 Crashed: Dispatch queue: com.apple.main-thread
0 com.apple.CoreFoundation 0x00007fff82e0a788 CFRetain + 200
1 com.apple.QuartzCore 0x00007fff81677a98 -[CALayer setSublayers:] + 486
2 com.apple.WebCore 0x00007fff87c792a1 WebCore::GraphicsLayerCA::updateSublayerList() + 433
3 com.apple.WebCore 0x00007fff87c7ebd8 WebCore::GraphicsLayerCA::commitLayerChanges() + 840
4 com.apple.WebCore 0x00007fff87c7ed05 WebCore::GraphicsLayerCA::recursiveCommitChanges() + 21
5 com.apple.WebCore 0x00007fff87c7ed31 WebCore::GraphicsLayerCA::recursiveCommitChanges() + 65
6 com.apple.WebCore 0x00007fff87705296 WebCore::FrameView::paintContents(WebCore::GraphicsContext*, WebCore::IntRect const&) + 390
7 com.apple.WebKit 0x00007fff81b3d205 -[WebFrame(WebInternal) _drawRect:contentsOnly:] + 149
8 com.apple.WebKit 0x00007fff81b3ce77 -[WebHTMLView drawSingleRect:] + 455
9 com.apple.WebKit 0x00007fff81b3cc16 -[WebHTMLView drawRect:] + 566
10 com.apple.AppKit 0x00007fff8597b05e -[NSView _drawRect:clip:] + 3566
11 com.apple.AppKit 0x00007fff85978834 -[NSView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:] + 2112
12 com.apple.WebKit 0x00007fff81b3dd6b -[WebHTMLView(WebPrivate) _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:] + 299
13 com.apple.AppKit 0x00007fff859791bf -[NSView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:] + 4555
14 com.apple.AppKit 0x00007fff859791bf -[NSView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:] + 4555
15 com.apple.AppKit 0x00007fff859791bf -[NSView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:] + 4555
16 com.apple.AppKit 0x00007fff859791bf -[NSView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:] + 4555
17 com.apple.AppKit 0x00007fff859791bf -[NSView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:] + 4555
18 com.apple.AppKit 0x00007fff859791bf -[NSView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:] + 4555
19 com.apple.AppKit 0x00007fff85977e17 -[NSThemeFrame _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:] + 254
20 com.apple.AppKit 0x00007fff859746bf -[NSView _displayRectIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:] + 2683
21 com.apple.AppKit 0x00007fff858edf37 -[NSView displayIfNeeded] + 969
22 com.apple.AppKit 0x00007fff858e8dde _handleWindowNeedsDisplay + 678
23 com.apple.CoreFoundation 0x00007fff82e74427 __CFRunLoopDoObservers + 519
24 com.apple.CoreFoundation 0x00007fff82e502d4 __CFRunLoopRun + 468
25 com.apple.CoreFoundation 0x00007fff82e4fc2f CFRunLoopRunSpecific + 575
26 com.apple.HIToolbox 0x00007fff88192a4e RunCurrentEventLoopInMode + 333
27 com.apple.HIToolbox 0x00007fff881927b1 ReceiveNextEventCommon + 148
28 com.apple.HIToolbox 0x00007fff8819270c BlockUntilNextEventMatchingListInMode + 59
29 com.apple.AppKit 0x00007fff858be1f2 _DPSNextEvent + 708
30 com.apple.AppKit 0x00007fff858bdb41 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 155
31 com.apple.AppKit 0x00007fff85883747 -[NSApplication run] + 395
32 com.apple.AppKit 0x00007fff8587c468 NSApplicationMain + 364
33 com.yourcompany.wb 0x0000000100001c86 main + 33 (main.m:14)
34 com.yourcompany.wb 0x0000000100001a44 start + 52
Thread 1: Dispatch queue: com.apple.libdispatch-manager
0 libSystem.B.dylib 0x00007fff8874bbba kevent + 10
1 libSystem.B.dylib 0x00007fff8874da85 _dispatch_mgr_invoke + 154
2 libSystem.B.dylib 0x00007fff8874d75c _dispatch_queue_invoke + 185
3 libSystem.B.dylib 0x00007fff8874d286 _dispatch_worker_thread2 + 244
4 libSystem.B.dylib 0x00007fff8874cbb8 _pthread_wqthread + 353
5 libSystem.B.dylib 0x00007fff8874ca55 start_wqthread + 13
Thread 2: JavaScriptCore: FastMalloc scavenger
0 libSystem.B.dylib 0x00007fff8876d9ee __semwait_signal + 10
1 libSystem.B.dylib 0x00007fff887717f1 _pthread_cond_wait + 1286
2 com.apple.JavaScriptCore 0x00007fff80ae62b3 WTF::TCMalloc_PageHeap::scavengerThread() + 515
3 com.apple.JavaScriptCore 0x00007fff80ae62f9 WTF::TCMalloc_PageHeap::runScavengerThread(void*) + 9
4 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
5 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 3:
0 libSystem.B.dylib 0x00007fff8874c9da __workq_kernreturn + 10
1 libSystem.B.dylib 0x00007fff8874cdec _pthread_wqthread + 917
2 libSystem.B.dylib 0x00007fff8874ca55 start_wqthread + 13
Thread 4:
0 libSystem.B.dylib 0x00007fff88732e3a mach_msg_trap + 10
1 libSystem.B.dylib 0x00007fff887334ad mach_msg + 59
2 com.apple.CoreFoundation 0x00007fff82e507a2 __CFRunLoopRun + 1698
3 com.apple.CoreFoundation 0x00007fff82e4fc2f CFRunLoopRunSpecific + 575
4 com.apple.Foundation 0x00007fff800de4cf +[NSURLConnection(NSURLConnectionReallyInternal) _resourceLoadLoop:] + 297
5 com.apple.Foundation 0x00007fff8005ee99 __NSThread__main__ + 1429
6 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
7 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 5:
0 libSystem.B.dylib 0x00007fff887769e2 select$DARWIN_EXTSN + 10
1 com.apple.CoreFoundation 0x00007fff82e72242 __CFSocketManager + 818
2 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
3 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 6:
0 libSystem.B.dylib 0x00007fff8874c9da __workq_kernreturn + 10
1 libSystem.B.dylib 0x00007fff8874cdec _pthread_wqthread + 917
2 libSystem.B.dylib 0x00007fff8874ca55 start_wqthread + 13
Thread 7:
0 libSystem.B.dylib 0x00007fff8873d426 read + 10
1 com.apple.CoreFoundation 0x00007fff82eb1ae0 __CFSocketRead + 544
2 com.apple.CFNetwork 0x00007fff88bba667 __CFSocketReadWithError(__CFSocket*, unsigned char*, long, CFStreamError*) + 35
3 com.apple.CFNetwork 0x00007fff88bba397 SocketStream::read(__CFReadStream*, unsigned char*, long, CFStreamError*, unsigned char*) + 699
4 com.apple.CoreFoundation 0x00007fff82e3ffac CFReadStreamRead + 540
5 com.apple.CFNetwork 0x00007fff88bd3dc1 HTTPReadFilter::doPlainRead(unsigned char*, long, CFStreamError*, unsigned char*) + 307
6 com.apple.CFNetwork 0x00007fff88bd3c59 HTTPReadFilter::streamRead(__CFReadStream*, unsigned char*, long, CFStreamError*, unsigned char*) + 469
7 com.apple.CoreFoundation 0x00007fff82e3ffac CFReadStreamRead + 540
8 com.apple.CFNetwork 0x00007fff88bd39e6 HTTPNetStreamInfo::streamRead(__CFReadStream*, unsigned char*, long, CFStreamError*, unsigned char*) + 562
9 com.apple.CoreFoundation 0x00007fff82e3ffac CFReadStreamRead + 540
10 com.apple.CFNetwork 0x00007fff88c23892 HTTPReadStream::streamRead(__CFReadStream*, unsigned char*, long, CFStreamError*, unsigned char*) + 82
11 com.apple.CoreFoundation 0x00007fff82e3ffac CFReadStreamRead + 540
12 com.apple.MediaToolbox 0x00007fff86b59a6f FigCFHTTPReadResponse + 855
13 com.apple.CoreFoundation 0x00007fff82eb1503 _signalEventSync + 115
14 com.apple.CoreFoundation 0x00007fff82eb1474 _cfstream_solo_signalEventSync + 116
15 com.apple.CFNetwork 0x00007fff88c228fd HTTPReadStream::streamEvent(unsigned long) + 163
16 com.apple.CoreFoundation 0x00007fff82eb1503 _signalEventSync + 115
17 com.apple.CoreFoundation 0x00007fff82eb1474 _cfstream_solo_signalEventSync + 116
18 com.apple.CoreFoundation 0x00007fff82e52271 __CFRunLoopDoSources0 + 1361
19 com.apple.CoreFoundation 0x00007fff82e50469 __CFRunLoopRun + 873
20 com.apple.CoreFoundation 0x00007fff82e4fc2f CFRunLoopRunSpecific + 575
21 com.apple.CoreFoundation 0x00007fff82e4f9b6 CFRunLoopRun + 70
22 com.apple.CoreMedia 0x00007fff803d4702 FigThreadGlobalNetworkBufferingRunloop + 119
23 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
24 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 8:
0 libSystem.B.dylib 0x00007fff8876d9ee __semwait_signal + 10
1 libSystem.B.dylib 0x00007fff887717f1 _pthread_cond_wait + 1286
2 com.apple.CoreMedia 0x00007fff803d5947 WaitOnCondition + 14
3 com.apple.CoreMedia 0x00007fff803d5b13 FigSemaphoreWaitRelative + 167
4 com.apple.MediaToolbox 0x00007fff86aee8c7 FigAIORequestThread + 398
5 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
6 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 9:
0 libSystem.B.dylib 0x00007fff8874c9da __workq_kernreturn + 10
1 libSystem.B.dylib 0x00007fff8874cdec _pthread_wqthread + 917
2 libSystem.B.dylib 0x00007fff8874ca55 start_wqthread + 13
Thread 10:
0 libSystem.B.dylib 0x00007fff88732e3a mach_msg_trap + 10
1 libSystem.B.dylib 0x00007fff887334ad mach_msg + 59
2 com.apple.CoreFoundation 0x00007fff82e507a2 __CFRunLoopRun + 1698
3 com.apple.CoreFoundation 0x00007fff82e4fc2f CFRunLoopRunSpecific + 575
4 com.apple.CoreFoundation 0x00007fff82e4f9b6 CFRunLoopRun + 70
5 com.apple.QTKit 0x00007fff830d0c49 QTFigVisualContextImageProviderWorkThread + 342
6 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
7 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 11:
0 libSystem.B.dylib 0x00007fff88732e3a mach_msg_trap + 10
1 libSystem.B.dylib 0x00007fff887334ad mach_msg + 59
2 com.apple.CoreFoundation 0x00007fff82e507a2 __CFRunLoopRun + 1698
3 com.apple.CoreFoundation 0x00007fff82e4fc2f CFRunLoopRunSpecific + 575
4 ....audio.toolbox.AudioToolbox 0x00007fff8416267a GenericRunLoopThread::RunLoop() + 42
5 ....audio.toolbox.AudioToolbox 0x00007fff841629f0 GenericRunLoopThread::Run() + 140
6 ....audio.toolbox.AudioToolbox 0x00007fff8412ded5 CAPThread::Entry(CAPThread*) + 67
7 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
8 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 12:
0 libSystem.B.dylib 0x00007fff8876d9ee __semwait_signal + 10
1 libSystem.B.dylib 0x00007fff887717f1 _pthread_cond_wait + 1286
2 com.apple.CoreMedia 0x00007fff803d5947 WaitOnCondition + 14
3 com.apple.CoreMedia 0x00007fff803d5b13 FigSemaphoreWaitRelative + 167
4 com.apple.MediaToolbox 0x00007fff86afd4dd faq_EnqueueSourceDataThread + 44
5 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
6 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 13:
0 libSystem.B.dylib 0x00007fff8876d9ee __semwait_signal + 10
1 libSystem.B.dylib 0x00007fff887717f1 _pthread_cond_wait + 1286
2 com.apple.CoreMedia 0x00007fff803d5947 WaitOnCondition + 14
3 com.apple.CoreMedia 0x00007fff803d5b13 FigSemaphoreWaitRelative + 167
4 com.apple.MediaToolbox 0x00007fff86b9b03b activitySchedulerOnThread + 69
5 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
6 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 14:
0 libSystem.B.dylib 0x00007fff8876d9ee __semwait_signal + 10
1 libSystem.B.dylib 0x00007fff887717f1 _pthread_cond_wait + 1286
2 com.apple.CoreMedia 0x00007fff803d5947 WaitOnCondition + 14
3 com.apple.CoreMedia 0x00007fff803d5b13 FigSemaphoreWaitRelative + 167
4 com.apple.MediaToolbox 0x00007fff86b26d49 audioMentorThread + 6000
5 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
6 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 15:
0 libSystem.B.dylib 0x00007fff8876d9ee __semwait_signal + 10
1 libSystem.B.dylib 0x00007fff887717f1 _pthread_cond_wait + 1286
2 com.apple.CoreMedia 0x00007fff803d5947 WaitOnCondition + 14
3 com.apple.CoreMedia 0x00007fff803d5b13 FigSemaphoreWaitRelative + 167
4 com.apple.MediaToolbox 0x00007fff86b3003a videoMentorThread + 5700
5 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
6 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 16:
0 libSystem.B.dylib 0x00007fff88732e3a mach_msg_trap + 10
1 libSystem.B.dylib 0x00007fff887334ad mach_msg + 59
2 com.apple.CoreFoundation 0x00007fff82e507a2 __CFRunLoopRun + 1698
3 com.apple.CoreFoundation 0x00007fff82e4fc2f CFRunLoopRunSpecific + 575
4 com.apple.CoreFoundation 0x00007fff82e4f9b6 CFRunLoopRun + 70
5 com.apple.QTKit 0x00007fff830cfad4 QTCALayerRendererPendingQWorkLoop + 534
6 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
7 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 17:
0 libSystem.B.dylib 0x00007fff88732e76 semaphore_wait_trap + 10
1 com.apple.VideoToolbox 0x00007fff80487f25 JVTLib_100988 + 11
2 com.apple.VideoToolbox 0x00007fff804d61d8 JVTLib_101021(void*) + 60
3 com.apple.VideoToolbox 0x00007fff804882f4 JVTLib_100971 + 552
4 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
5 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 18:
0 libSystem.B.dylib 0x00007fff88732e76 semaphore_wait_trap + 10
1 com.apple.VideoToolbox 0x00007fff80487f25 JVTLib_100988 + 11
2 com.apple.VideoToolbox 0x00007fff804d61d8 JVTLib_101021(void*) + 60
3 com.apple.VideoToolbox 0x00007fff804882f4 JVTLib_100971 + 552
4 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
5 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 19:
0 libSystem.B.dylib 0x00007fff88732e9a semaphore_timedwait_signal_trap + 10
1 libSystem.B.dylib 0x00007fff887716e2 _pthread_cond_wait + 1015
2 com.apple.CoreVideo 0x00007fff83d2988c CVDisplayLink::waitUntil(unsigned long long) + 252
3 com.apple.CoreVideo 0x00007fff83d28d91 CVDisplayLink::runIOThread() + 619
4 com.apple.CoreVideo 0x00007fff83d28aeb startIOThread(void*) + 139
5 libSystem.B.dylib 0x00007fff8876bf8e _pthread_start + 331
6 libSystem.B.dylib 0x00007fff8876be41 thread_start + 13
Thread 0 crashed with X86 Thread State (64-bit):
rax: 0x0000000000000000 rbx: 0x0000000000000000 rcx: 0x0000000000000000 rdx: 0x0000000000000018
rdi: 0x0000000000000000 rsi: 0x000000020070f7d8 rbp: 0x00007fff5fbfbcf0 rsp: 0x00007fff5fbfbce0
r8: 0x00000001010e48d0 r9: 0x000000000000f740 r10: 0x00000001010e42f0 r11: 0x00007fff87d9ca50
r12: 0x0000000101238600 r13: 0x0000000000000000 r14: 0x000000020070f7c0 r15: 0x0000000000000000
rip: 0x00007fff82e0a788 rfl: 0x0000000000000246 cr2: 0x00007fff702c13c8
The stack trace in your question is evidencing a known (and fixed) bug in WebKit
https://bugs.webkit.org/show_bug.cgi?id=31429