Skip to content

fix: skip recover frames on panic - #1364

Merged
giortzisg merged 2 commits into
masterfrom
fix/recover-panic-stacktrace
Jul 16, 2026
Merged

giortzisg merged 2 commits into
masterfrom
fix/recover-panic-stacktrace

Conversation

@giortzisg

@giortzisg giortzisg commented Jul 15, 2026 •

Copy link
Copy Markdown
Collaborator

Description

This PR changes the stacktrace parsing behavior to throw away confusing sentry.Recover frames being reported. In active panics the frames would consist of a runtime.gopanic frame which indicates the boundary of where the panic originated from. In those cases the SDK should throw away the rest of the frames and keep only the panic origin.

Issues

Changelog Entry Instructions

To add a custom changelog entry, uncomment the section above. Supports:

  • Single entry: just write text
  • Multiple entries: use bullet points
  • Nested bullets: indent 4+ spaces

For more details: custom changelog entries

Reminders

Changelog Entry

  • fix: skip recover frames on panic. This changes stacktrace behavior for captured panics, removing sentry.Recover frames to focus on the actual panic frames. The changes might affect issue grouping.

@linear-code

linear-code Bot commented Jul 15, 2026

Copy link
Copy Markdown

GO-149

Comment thread stacktrace.go
@giortzisg
giortzisg merged commit 96509cc into master Jul 16, 2026
21 checks passed
@giortzisg
giortzisg deleted the fix/recover-panic-stacktrace branch July 16, 2026 12:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Stack trace has confusing top frame when using sentry.CurrentHub().Recover(err)

2 participants