getsentry / getsentry/sentry-dotnet

See if we can replace with UnhandledException handler

Open
#4,180 1 comment 2 reactions 0 assignees View on GitHub
.NET 3: medium Improvement iOS
Dominant language
C#
Stars
770
Forks
248
Avg merge
3d 4h
Merged PRs (30d)
49

Description

In order to reliably catch unhandled exceptions on iOS we listen to `Runtime.MarshalManagedException` rather than `AppDomain.UnhandledException`. Whilst this seems to work, it has the disadvantage that the args passed to `Runtime.MarshalManagedException` don't indicate whether the exception is terminal or not (we just assume it is).

Apparently this should be fixed in .NET 10:
- https://github.com/dotnet/macios/issues/15252#issuecomment-2871164622

We'd need to test this out of course. If it works though, we could do away with the `Runtime.MarshalManagedException` callback.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.