Skip to content

Commit f0e7ef5

Browse files
committed
.
1 parent 72d336e commit f0e7ef5

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

sentry_sdk/scope.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1237,7 +1237,7 @@ def start_streamed_span(
12371237
)
12381238

12391239
if parent_span is None or isinstance(parent_span, NoOpStreamedSpan):
1240-
parent_span = self.span or self.get_current_scope().span # type: ignore
1240+
parent_span = self.span # type: ignore
12411241

12421242
# If no eligible parent_span was provided and there is no currently
12431243
# active span, this is a segment

sentry_sdk/traces.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -206,14 +206,14 @@ class StreamedSpan:
206206
"_sampled",
207207
"_parent_sampled",
208208
"_start_timestamp",
209+
"_start_timestamp_monotonic_ns",
209210
"_timestamp",
211+
"_finished",
210212
"_status",
211-
"_start_timestamp_monotonic_ns",
212213
"_scope",
213214
"_context_manager_state",
214215
"_continuous_profile",
215216
"_baggage",
216-
"_finished",
217217
"_sample_rand",
218218
"_sample_rate",
219219
)
@@ -252,6 +252,8 @@ def __init__(
252252
self._sample_rate = sample_rate
253253

254254
self._start_timestamp = datetime.now(timezone.utc)
255+
self._timestamp: "Optional[datetime]" = None
256+
self._finished: bool = False
255257

256258
try:
257259
# profiling depends on this value and requires that
@@ -260,8 +262,6 @@ def __init__(
260262
except AttributeError:
261263
pass
262264

263-
self._timestamp: "Optional[datetime]" = None
264-
self._finished: bool = False
265265
self._span_id: "Optional[str]" = None
266266

267267
self._status = SpanStatus.OK.value

0 commit comments

Comments
 (0)