Skip to content

Commit

Permalink
fix the blocking delay fix
Browse files Browse the repository at this point in the history
  • Loading branch information
jp-agenta committed Nov 1, 2024
1 parent 98a7dc3 commit 8684e40
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion agenta-cli/agenta/sdk/tracing/processors.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ def on_start(

if span.context.trace_id not in self._registry:
self._registry[span.context.trace_id] = dict()
self.spans[span.context.trace_id] = list()

self._registry[span.context.trace_id][span.context.span_id] = True

Expand All @@ -60,7 +59,11 @@ def on_end(
):
super().on_end(span)

if span.context.trace_id not in self.spans:
self.spans[span.context.trace_id] = list()

self.spans[span.context.trace_id].append(span)

del self._registry[span.context.trace_id][span.context.span_id]

if self.is_ready(span.get_span_context().trace_id):
Expand Down

0 comments on commit 8684e40

Please sign in to comment.