This commit is contained in:
Alex Hall 2025-03-17 23:56:42 +02:00
parent 2d2e8f0e34
commit 7eb2bcee15

View file

@ -85,6 +85,7 @@ def fetch_normalized_spans():
traces = []
for trace_obj in fetch_traces():
trace = trace_obj.export()
assert trace
assert trace.pop("object") == "trace"
assert trace.pop("id").startswith("trace_")
trace = {k: v for k, v in trace.items() if v is not None}
@ -96,6 +97,7 @@ def fetch_normalized_spans():
for span_obj in fetch_ordered_spans():
span = span_obj.export()
assert span
assert span.pop("object") == "trace.span"
assert span.pop("id").startswith("span_")
assert datetime.fromisoformat(span.pop("started_at"))