Revert "count both spans and traces"

This reverts commit d49bd89061.
This commit is contained in:
Pratyush Shukla 2025-03-12 10:19:14 +05:30
parent d49bd89061
commit 6962410976
No known key found for this signature in database
GPG key ID: AFCF7DAD6BA1FEE2

View file

@ -81,17 +81,7 @@ class BackendSpanExporter(TracingExporter):
traces: list[dict[str, Any]] = []
spans: list[dict[str, Any]] = []
# Categorize items into traces and spans
for item in items:
if hasattr(item, 'export') and callable(item.export):
export_data = item.export()
if export_data:
if isinstance(item, Trace):
traces.append(export_data)
else:
spans.append(export_data)
data = traces + spans
data = [item.export() for item in items if item.export()]
payload = {"data": data}
headers = {