We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c017b01 commit b47bc70Copy full SHA for b47bc70
sentry_sdk/integrations/opentelemetry/sampler.py
@@ -120,8 +120,8 @@ def should_sample(
120
if not has_tracing_enabled(client.options):
121
return dropped_result(parent_span_context, attributes)
122
123
- has_parent = parent_span_context.is_valid
124
- is_root_span = not has_parent or parent_span_context.is_remote
+ # parent_span_context.is_valid means this span has a parent, remote or local
+ is_root_span = not parent_span_context.is_valid or parent_span_context.is_remote
125
126
# Explicit sampled value provided at start_span
127
if attributes.get(SentrySpanAttribute.CUSTOM_SAMPLED) is not None:
0 commit comments