Closed haritha-mohan closed 7 months ago
- Unexpected crashes: The app tends to crash at some point after opening a session/upon closing a session.
Is anything printed to the terminal when it crashes (if you launch the app from the command line)?
@rolfbjarne when launching from command line, this is the output that gets displayed. the crash happened right after all the media files were loaded in, but afaik no explicit info about the crash..
That's really weird, something more useful should have been printed to the terminal.
Can you zip up /Users/harithamohan/mac-samples/CameraBrowser/CameraBrowserSample/bin/Debug/net7.0-macos/osx-x64/CameraBrowserSample.app
and attach it here?
@rolfbjarne The compressed file is too large to attach here, but I went ahead and just pushed my latest changes to the branch. Just a note the pr is still a wip- I need to integrate the updated changes with the updated thumbnail selector. So it might be easier to debug this once the pr lands?
Here's a stack trace with lldb:
(lldb) bt
* thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x3eadde8ac820)
* frame #0: 0x00007ff80350939c libobjc.A.dylib`class_getMethodImplementation + 39
frame #1: 0x00007ff804696d0f Foundation`_NSKVONotifyingOriginalClassForIsa + 21
frame #2: 0x00007ff8046b7d57 Foundation`_NSKeyValueObservationInfoGetObservances + 251
frame #3: 0x00007ff8046b0735 Foundation`-[NSObject(NSKeyValueObservingPrivate) _notifyObserversForKeyPath:change:] + 132
frame #4: 0x00007ff8069b3b10 AppKit`-[NSController _notifyObserversForKeyPath:change:] + 188
frame #5: 0x00007ff806a4c093 AppKit`-[NSArrayController didChangeValuesForArrangedKeys:objectKeys:indexKeys:] + 93
frame #6: 0x00007ff806a4bd11 AppKit`-[NSArrayController _selectObjectsAtIndexesNoCopy:avoidsEmptySelection:sendObserverNotifications:forceUpdate:] + 528
frame #7: 0x00007ff8046b4441 Foundation`-[NSObject(NSKeyValueCoding) setValue:forKey:] + 353
frame #8: 0x00007ff806c04905 AppKit`-[NSBinder _setValue:forKeyPath:ofObject:mode:validateImmediately:raisesForNotApplicableKeys:error:] + 445
frame #9: 0x00007ff806c046f8 AppKit`-[NSBinder setValue:forBinding:error:] + 238
frame #10: 0x00007ff806c11474 AppKit`-[NSTableBinder tableView:didChangeToSelectedRowIndexes:] + 118
frame #11: 0x00007ff806c07537 AppKit`-[_NSBindingAdaptor tableView:didChangeToSelectedRowIndexes:] + 156
frame #12: 0x00007ff806af38ac AppKit`-[NSTableView _sendSelectionChangedNotificationForRows:columns:] + 128
frame #13: 0x00007ff806d01492 AppKit`-[NSTableView mouseDown:] + 5954
frame #14: 0x00007ff806bc4362 AppKit`-[NSWindow(NSEventRouting) _handleMouseDownEvent:isDelayedEvent:] + 4283
frame #15: 0x00007ff806b3a53e AppKit`-[NSWindow(NSEventRouting) _reallySendEvent:isDelayedEvent:] + 2595
frame #16: 0x00007ff806b398ff AppKit`-[NSWindow(NSEventRouting) sendEvent:] + 345
frame #17: 0x00007ff806b37c6e AppKit`-[NSApplication(NSEvent) sendEvent:] + 358
frame #18: 0x00007ff806df6655 AppKit`-[NSApplication _handleEvent:] + 65
frame #19: 0x00007ff8069c677c AppKit`-[NSApplication run] + 623
frame #20: 0x00007ff80699a797 AppKit`NSApplicationMain + 817
frame #21: 0x000000012411e902
frame #22: 0x000000012411e7fd
frame #23: 0x000000012411a3de
frame #24: 0x000000010a6ff969 libcoreclr.dylib`CallDescrWorkerInternal + 124
frame #25: 0x000000010a551382 libcoreclr.dylib`MethodDescCallSite::CallTargetWorker(unsigned long const*, unsigned long*, int) + 1522
frame #26: 0x000000010a442ede libcoreclr.dylib`RunMain(MethodDesc*, short, int*, PtrArray**) + 734
frame #27: 0x000000010a443215 libcoreclr.dylib`Assembly::ExecuteMainMethod(PtrArray**, int) + 421
frame #28: 0x000000010a46da1b libcoreclr.dylib`CorHost2::ExecuteAssembly(unsigned int, char16_t const*, int, char16_t const**, unsigned int*) + 619
frame #29: 0x000000010a42fac4 libcoreclr.dylib`coreclr_execute_assembly + 180
frame #30: 0x000000010002d987 CameraBrowserSample`mono_jit_exec + 167
frame #31: 0x000000010003132f CameraBrowserSample`xamarin_main + 815
frame #32: 0x00000001000c40c4 CameraBrowserSample`main + 52
frame #33: 0x000000020044e310 dyld`start + 2432
or a full crash report: https://gist.github.com/rolfbjarne/27d22b3954d867f8a8b91bc2e13dec64
Unfortunately neither help much :/ it seems to be a problem with key-value observation, but it might take a while to track it down (I would simplify the app as much as possible, to try to create a minimised sample, and then hopefully end up understanding what's happening in the process).
Microsoft support for Xamarin will end on May 1, 2024 for all Xamarin SDKs. In preparation for this, all issues and PRs in this repository are being closed.
After recently updating to macOS Ventura 13.2 (22D49), there have been a number of issues running the Camera Browser application. The app runs successfully with no issues on macOS Monterey (12.3.1), which makes me think the Ventura update is the culprit.
Key issues:
Ref: example crash report