Skip to content

Commit 53516df

Browse files
committed
feat: Set sentry.trace_lifecycle attr in span streaming
1 parent 5dabd02 commit 53516df

2 files changed

Lines changed: 2 additions & 0 deletions

File tree

sentry_sdk/traces.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,7 @@ def __init__(
275275
self._active: bool = active
276276
self._attributes: "Attributes" = {
277277
"sentry.origin": "manual",
278+
"sentry.trace_lifecycle": "stream",
278279
}
279280

280281
if attributes:

tests/tracing/test_span_streaming.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1722,6 +1722,7 @@ def test_default_attributes(sentry_init, capture_envelopes):
17221722
"sentry.dist": {"value": "1.0", "type": "string"},
17231723
"sentry.origin": {"value": "manual", "type": "string"},
17241724
"sentry.sdk.integrations": {"value": mock.ANY, "type": "array"},
1725+
"sentry.trace_lifecycle": {"value": "stream", "type": "string"},
17251726
"process.runtime.name": {
17261727
"type": "string",
17271728
"value": mock.ANY,

0 commit comments

Comments
 (0)