-
-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Device/Unity context to native events #650
Comments
Possible solution: Capturing "what we can" and things that don't change (i.e. not memory usage) and set it to the Scope as context and pass it down to the Native Layer. |
RFC: I'm not 100 % sure about the approach for this... What I've started in #747 is make a |
That means everything "static" from #744 makes it to the native layer? |
I don't think there's anything we can do at the time of an event. Even though there are callback hooks we could assign, I don't feel confident doing c# interop calls from native code at the time of a crash - I wouldn't be confident they're signal-safe, which is a requirement because they run in a signal handler at the time of a crash. Therefore, the only option I see is setting the contexts on the scope. Also, if we want to, we could make notifications on some context changes, like adding new ones, clearing, etc. But changing properties on existing contexts would still go unnoticed... Overall, this all feels like expanding the scope of the issue, which is about setting "Device/Unity" context to native events - those that don't change. |
To get around the cost of early init & native sync, even though it's likely negligible, we could have it run in a coroutine. For native error context sync, that should be just fine even with a slight delay (unlike for dotnet errors where it was more noticeable, #744) |
Data that's applied to the event through the Unity layer (UnityEventProcessor) should also be available in crashes from native layers.
This is gap is more visible in Windows (minidump) crashes which don't have the rich device info that comes on iOS and Android crashes.
The text was updated successfully, but these errors were encountered: