Skip to content

feat(scope): Add process runtime attributes to span context#6564

Merged
ericapisani merged 8 commits into
masterfrom
py-2401-migrate-stdlib-event-processor
Jun 18, 2026
Merged

feat(scope): Add process runtime attributes to span context#6564
ericapisani merged 8 commits into
masterfrom
py-2401-migrate-stdlib-event-processor

update some of the tests

bb23e2b
Select commit
Loading
Failed to load commit list.
@sentry/warden / warden: find-bugs completed Jun 16, 2026 in 0s

2 issues

find-bugs: Found 2 issues (1 medium, 1 low)

Medium

`process.runtime.description` never set on segments that complete without error events - `sentry_sdk/integrations/stdlib.py:58-66`

Setting process.runtime.description inside a global event processor means it is only applied to the currently active segment when an error event fires; segments that complete normally (without any captured errors) will never receive this attribute, making the three runtime attributes inconsistent.

Low

`process.runtime.description` never appears in log/event attributes

set_global_attributes in scope.py sets process.runtime.name and process.runtime.version but omits process.runtime.description (sys.version), so log and error events will never carry that attribute. The only code path that sets it (stdlib.py:65) places it on the active segment span and only when span streaming is enabled — it is never surfaced as a scope attribute on events.


⏱ 6m 21s · 1.8M in / 71.8k out · $2.31

Annotations

Check warning on line 66 in sentry_sdk/integrations/stdlib.py

See this annotation in the file changed.

@sentry-warden sentry-warden / warden: find-bugs

`process.runtime.description` never set on segments that complete without error events

Setting `process.runtime.description` inside a global event processor means it is only applied to the currently active segment when an error event fires; segments that complete normally (without any captured errors) will never receive this attribute, making the three runtime attributes inconsistent.