Skip to content

Commit a4c422a

Browse files
committed
add span pointers to root (inferred) span if it exists instead of execution span
1 parent e40f4a8 commit a4c422a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

datadog_lambda/tracing.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1368,8 +1368,9 @@ def create_function_execution_span(
13681368
if parent_span:
13691369
span.parent_id = parent_span.span_id
13701370
if span_pointers:
1371+
root_span = parent_span if parent_span else span
13711372
for span_pointer_description in span_pointers:
1372-
span._add_span_pointer(
1373+
root_span._add_span_pointer(
13731374
pointer_kind=span_pointer_description.pointer_kind,
13741375
pointer_direction=span_pointer_description.pointer_direction,
13751376
pointer_hash=span_pointer_description.pointer_hash,

0 commit comments

Comments
 (0)