Skip to content

Commit 2120e18

Browse files
committed
Use new status property
1 parent 73e333b commit 2120e18

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sentry_sdk/tracing.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1646,7 +1646,7 @@ def is_success(self):
16461646

16471647
def finish(self, end_timestamp=None):
16481648
# type: (Optional[Union[float, datetime]]) -> Optional[str]
1649-
if hasattr(self._otel_span, "status") and self._otel_span.status.status_code == StatusCode.UNSET:
1649+
if self.status is None:
16501650
self.set_status(SPANSTATUS.OK)
16511651

16521652
if end_timestamp is not None:

0 commit comments

Comments
 (0)