Skip to content

ref(grouping): Simplify recursive frame handling #97539

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

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions src/sentry/grouping/strategies/configurations.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,6 @@
],
delegates=["frame:v1", "stacktrace:v1", "single-exception:v1"],
initial_context={
# This is a flag that can be used by any delegate to respond to
# a detected recursion. This is currently used by the frame
# strategy to disable itself. Recursion is detected by the outer
# strategy.
"is_recursion": False,
# Perform automatic message trimming and parameter substitution in the message strategy.
# (Should be kept on - only configurable so it can be turned off in tests.)
"normalize_message": True,
Expand Down
9 changes: 3 additions & 6 deletions src/sentry/grouping/strategies/newstyle.py
Original file line number Diff line number Diff line change
Expand Up @@ -370,9 +370,6 @@ def frame(
):
frame_component.update(contributes=False, hint="ignored low quality javascript frame")

if context["is_recursion"]:
frame_component.update(contributes=False, hint="ignored due to recursion")

return {variant_name: frame_component}


Expand Down Expand Up @@ -437,9 +434,9 @@ def _single_stacktrace_variant(
found_in_app_frame = False

for frame in frames:
with context:
context["is_recursion"] = _is_recursive_frame(frame, prev_frame)
frame_component = context.get_single_grouping_component(frame, event=event, **kwargs)
frame_component = context.get_single_grouping_component(frame, event=event, **kwargs)
if _is_recursive_frame(frame, prev_frame):
frame_component.update(contributes=False, hint="ignored due to recursion")

if variant_name == "app":
if frame.in_app:
Expand Down
Loading