Skip to content

Commit 09b7206

Browse files
committed
fix: handle orphan errors better
1 parent f4d4913 commit 09b7206

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/sentry/api/endpoints/organization_trace.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -168,10 +168,10 @@ def query_trace_data(self, snuba_params: SnubaParams, trace_id: str) -> list[Ser
168168
else:
169169
result.append(span)
170170
if span["id"] in id_to_error:
171-
error = id_to_error[span["id"]]
171+
error = id_to_error.pop(span["id"])
172172
span["errors"].append(error)
173-
else:
174-
result.append(error)
173+
for error in id_to_error.values():
174+
result.append(error)
175175
return [self.serialize_rpc_event(root) for root in result]
176176

177177
def has_feature(self, organization: Organization, request: Request) -> bool:

0 commit comments

Comments
 (0)