ref(native): scope application to event#1769
Open
bitsandfoxes wants to merge 6 commits into
Open
Conversation
jpnurmi
reviewed
May 29, 2026
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
There are 2 total unresolved issues (including 1 from previous review).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit a26c756. Configure here.
jpnurmi
approved these changes
Jun 1, 2026
native_backend_flush_scope runs on every scope mutation (set_tag, set_context, set_user, ...). Folding breadcrumbs into the flushed base event re-serialized the entire breadcrumb ring on each of those calls - prohibitive on a hot path such as a 60fps game main thread. Give apply_scope a scope-mode argument: the continuous flush now passes SENTRY_SCOPE_NONE, while the crash handler still passes SENTRY_SCOPE_BREADCRUMBS to capture them at crash time (the process's last chance to record them). This matches the pre-existing behavior before breadcrumbs were added to the shared flush path. Co-Authored-By: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Enables #1742
This PR does not change the current output at all. For #1742 the daemon needs to be able to create non-crash events (i.e. app hangs).
build_native_crash_event->build_native_eventwith updated signature. This is what the app hang feature will then also usenative_backend_apply_scopeis the "source of truth" for all paths (update file & actual event)#skip-changelog