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

Only Include Top Most SDK Frame in Generated Stacktraces #1544

Open
sindresorhus opened this issue Dec 2, 2021 · 10 comments
Open

Only Include Top Most SDK Frame in Generated Stacktraces #1544

sindresorhus opened this issue Dec 2, 2021 · 10 comments

Comments

@sindresorhus
Copy link

Environment

SaaS (https://sentry.io/)

Version

No response

Steps to Reproduce

  • View a crash report for a report submitted by SentrySDK.captureError() (Sentry Cocoa 7.5.2)
  • Make sure it's showing "App Only" view.

Expected Result

I expected it to only show stack traces for my app.

Actual Result

The first stack trace is:

-[SentryStacktraceBuilder buildStacktraceForCurrentThread]

While I understand it sometimes can be useful to see where it crashed in a system framework. Seeing internal Sentry stack traces is not useful.

@getsentry-release
Copy link
Collaborator

Routing to @getsentry/team-mobile for triage. ⏲️

@bruno-garcia
Copy link
Member

Thanks for raising @sindresorhus . Sentry's frames shouldn't be included in In App.
We'll take a look

@bruno-garcia
Copy link
Member

To confirm: Do you see the Sentry frame like this:

image

As in: Crashed in?

Because it's not showing as In App on our samples:
image

@bruno-garcia
Copy link
Member

If you're using the SaaS, could you please share the link of an event in Sentry?

@sindresorhus
Copy link
Author

@philipphofmann
Copy link
Member

@bruno-garcia and @sindresorhus, Sentry doesn't mark the frames of the Cocoa SDK as in-app, see.

Screen Shot 2021-12-06 at 13 53 46

This grouping rule makes sure to mark frames starting with Sentry as non -n-app.
https://github.com/getsentry/sentry/blob/d81985575e1b0a9eebdb65f240db02c6f52ec2ff/src/sentry/grouping/enhancer/enhancement-configs/mobile%402021-04-02.txt#L68

@sindresorhus, above you mentioned

While I understand it sometimes can be useful to see where it crashed in a system framework. Seeing internal Sentry stack traces is not useful.

Do you think we should remove the whole stacktrace of the SentrySDK from captureError to buildStacktraceForCurrentThread?

@philipphofmann philipphofmann self-assigned this Dec 6, 2021
@sindresorhus
Copy link
Author

Do you think we should remove the whole stacktrace of the SentrySDK from captureError to buildStacktraceForCurrentThread?

Yes. Or at least only show the single (first) [SentrySDK captureError] stack frame. Everything after is just noise.

@philipphofmann philipphofmann transferred this issue from getsentry/sentry Dec 13, 2021
@philipphofmann philipphofmann changed the title "App Only" stack trace view should not show internal Sentry stack trace feat: Only Include Top Most SDK Frame in Generated Stacktraces Dec 13, 2021
@philipphofmann
Copy link
Member

philipphofmann commented Dec 13, 2021

It kind of makes sense, @sindresorhus. I add this to our backlog. It should be an easy fix (last famous words 😁) as these frames are not marked as in-app they shouldn't have an impact on grouping, but we should double-check that.

@philipphofmann philipphofmann changed the title feat: Only Include Top Most SDK Frame in Generated Stacktraces Only Include Top Most SDK Frame in Generated Stacktraces Dec 13, 2021
@philipphofmann philipphofmann moved this from Needs Discussion to Backlog in Mobile & Cross Platform SDK Dec 29, 2021
@github-actions
Copy link

This issue has gone three weeks without activity. In another week, I will close it.

But! If you comment or otherwise update it, I will reset the clock, and if you label it Status: Backlog or Status: In Progress, I will leave it alone ... forever!


"A weed is but an unloved flower." ― Ella Wheeler Wilcox 🥀

@sindresorhus
Copy link
Author

Please keep this open.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Backlog
Development

No branches or pull requests

7 participants