Skip to content
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

Several Stacktraces can ignored when an event was reported #489

Closed
km-jiaxiu opened this issue Jan 30, 2024 · 5 comments · Fixed by #537
Closed

Several Stacktraces can ignored when an event was reported #489

km-jiaxiu opened this issue Jan 30, 2024 · 5 comments · Fixed by #537
Labels
Feature New feature or request

Comments

@km-jiaxiu
Copy link

We made our own delegate to report the Android platform's assertions,But the top couple of Stacktraces we don't want to report,or that's what happens:we want the "UEngine:PerformError" to be top so that the title is displayed correctly.
Otherwise all assertions are displayed “SentrySubsystemAndroid::OnCrashing” ,[Issue Grouping]--[FINGERPRINT RULES]--[stack.*] only get the top stack so i cannot make a correctly title
image
Or is there another way to solve this problem?
thanks~

@tustanivsky
Copy link
Collaborator

@km-jiaxiu I don't think you can alter the stack trace of the event being captured by native SDK on Android. Can you elaborate on what that delegate you've mentioned above is responsible for and how exactly it works?

@km-jiaxiu
Copy link
Author

@km-jiaxiu I don't think you can alter the stack trace of the event being captured by native SDK on Android. Can you elaborate on what that delegate you've mentioned above is responsible for and how exactly it works?

SentrySubsystemAndroid.cpp :

  1. add the code: FCoreDelegates::OnHandleSystemError.AddRaw(this, &SentrySubsystemAndroid::OnCrashing); to the InitWithSettings Function
  2. Add a function to the SentrySubsystemAndroid class:void SentrySubsystemAndroid::OnCrashing() { *(int32 *)3 = 123; }
  3. Set Configuration to Development, Package Android, Launch the App, Input command: debug check

@km-jiaxiu
Copy link
Author

We want to invoke the function in Unreal which in the class io.sentry.SentryEvent , so that we can remove stacktraces we do not need before send.
image

@bitsandfoxes
Copy link
Contributor

If you want to modify the event before it gets sent you can take a look at the beforeSend callback. We've got an example here

USentryEvent* UCppBeforeSendHandler::HandleBeforeSend_Implementation(USentryEvent* Event, USentryHint* Hint)

@tustanivsky
Copy link
Collaborator

@km-jiaxiu We've managed to resolve this issue in #537. The fix should be available with the next plugin release or you can try to download the corresponding package from our GitHub CI here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature New feature or request
Projects
Archived in project
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants