REQUEST
Method: {{ trace.http_method }}
URL: {{ trace.http_url }}
Status:
{% if trace.status == 'ok' %}✓{% else %}✗{% endif %} {{ trace.http_status_code }}
TIMING
Start: {{ trace.start_time.strftime('%Y-%m-%d %H:%M:%S.%f')[:-3] }}
End: {{ trace.end_time.strftime('%Y-%m-%d %H:%M:%S.%f')[:-3] if trace.end_time else 'In Progress' }}
Duration:
{{ "%.2f"|format(trace.duration_ms) }} ms
USER CONTEXT
User: {{ trace.user_email or 'anonymous' }}
IP: {{ trace.ip_address or 'N/A' }}
User Agent: {{ (trace.user_agent[:50] + '...') if trace.user_agent and trace.user_agent|length > 50 else (trace.user_agent or 'N/A') }}
{% if trace.status_message %}
STATUS MESSAGE
{{ trace.status_message }}
{% endif %}
{% if trace.spans %}
Execution Timeline
{% set total_duration = trace.duration_ms %}
{% set trace_start = trace.start_time %}
{% for span in trace.spans|sort(attribute='start_time') %}
{{ ' ' * (0 if not span.parent_span_id else 1) }}{{ span.name }}
{% set span_duration_ms = span.duration_ms or 0 %}
{% set span_offset_ms = ((span.start_time - trace_start).total_seconds() * 1000) %}
{% set left_percent = (span_offset_ms / total_duration * 100) if total_duration > 0 else 0 %}
{% set width_percent = (span_duration_ms / total_duration * 100) if total_duration > 0 else 0 %}
{% if width_percent > 10 %}{{ span.name }}{% endif %}
{{ "%.2f"|format(span_duration_ms) }} ms
{% if span.events %}
{% for event in span.events %}
{{ event.name }}
{% if event.message %}: {{ event.message }}{% endif %}
{% endfor %}
{% endif %}
{% endfor %}
{% else %}
No spans recorded for this trace
{% endif %}
{% if trace.attributes %}
Additional Attributes
{{ trace.attributes|tojson(indent=2) }}
{% endif %}