I have an Objective-C macOS application that has a window with essentially a NSTableView on the left and a details view on the right, in a NSSplitView. The window also has labels and other controls. Some of the elements are driven by bindings, some other via referencing outlets. As soon as I open the window, if I don't touch anything, it works. If, as soon as the window opens, I immediately scroll fast with the mouse on any part of the window, I get a crash with this stack trace:
And the nasty "Unexpected outstanding background CATransaction" error in the log. I know this condition is almost always due to an update to the UI in a background thread, but I am checking my code in countless hours and could not find a single update to the UI done in background. The strangest thing is that the crash only occurs when running the app through Xcode. If I run the app from the Finder it never happens. The NSTableView is driven via datasource and delegate, and I tried to remove the connections and it still happens. I tried to exclude parts of the code with a return statement for example in WindowDidLoad, but it still happens. Also removing the bindings did not solve the situation. Can anybody suggest a powerful technique for finding out the instruction causing the crash?
Edit:
I have removed all objects from the window in the NSWindowController and left only the NSScrollView with the embedded NSTableView. It still happens, even if I return manually 0 from numberOfRowsInTableView. I have a possible hint that could lead to a solution: If I set the NSTableView to not enabled, or hidden, or both, it still happens. If I set the NSScrollView to hidden it does not happen any more. I hope this can ring a bell for somebody, as I am really running out of strategies. Thanks again.
