NSPrincipalClass not found on macOS application


#1

I’m using Sentry with a macOS application and I’m having some issues to set up the Sentry NSApplication to caught the uncaught crashes. As explained in the documentation, I set the NSPrincipalClass as SentryCrashExceptionApplication but it crashes at launch throwing the following error:

Unable to find class: SentryCrashExceptionApplication, exiting

I tried using Sentry.SentryCrashExceptionApplication instead but the same thing happen. I think it’s because it tries to find the class in the application bundle instead of the framework bundle.

Has anyone had the same issue? How could I solve it?

Thank you very much.
Pedro


#2

Hey Pedro,

Sorry for the late reply…
I suppose your are using Swift, right?

I definitely worked with Objc.