fix(grouping): Match Dart bootstrap stub frames by trimmed function name#117161
Merged
buenaflor merged 1 commit intoJun 10, 2026
Merged
Conversation
Real symbolicated native frames keep the `stub ` prefix in `raw_function`/`symbol` while `function` holds the trimmed name (e.g. `InvokeDartCode`). Because `raw_function` is set, the grouping matcher uses `function` unchanged, so the rules must match the trimmed name rather than the `stub ...` form, which never occurs in `function` for production frames. Co-authored-by: Cursor <cursoragent@cursor.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes native grouping enhancement rules for Dart VM bootstrap stub frames so they correctly match production-symbolicated frame shapes and are consistently marked out-of-app on the native platform.
Changes:
- Update the native enhancement rules to match trimmed Dart VM bootstrap
functionvalues (InvokeDartCode,CallBootstrapNative) instead of thestub ...raw symbol form. - Update the regression test to reflect real symbolicated frames where
functionis trimmed whileraw_function/symbolretain thestubprefix.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| tests/sentry/grouping/test_enhancer_dart_flutter_native.py | Adjusts the test frame shape to match real symbolicated native frames (trimmed function, stub ... in raw_function/symbol). |
| src/sentry/grouping/enhancer/enhancement-configs/all-platforms@2026-01-20.txt | Updates Dart VM bootstrap stub matching rules to target the trimmed function name so they match when raw_function is present. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
armenzg
approved these changes
Jun 10, 2026
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.
Dart VM bootstrap frames (
InvokeDartCode,CallBootstrapNative) are now reliably marked out-of-app on the native platform.On real symbolicated native frames the symbolicator keeps the
stubprefix inraw_function/symbolwhilefunctionalready holds the trimmed name (e.g.InvokeDartCode). Sinceraw_functionis set, the grouping matcher usesfunctionunchanged, so the previousfunction:"stub ..."rules never matched a production frame.Rule change
The two rules now match the trimmed
functionvalue:This is also robust when
raw_functionis absent:trim_native_function_name("stub InvokeDartCode")collapses toInvokeDartCode, so the rule still fires.The regression test was updated to use the real frame shape (trimmed
functionplusstub ...inraw_function/symbol) instead of the previous artificial frame that putstub ...directly infunction.Made with Cursor