-
Notifications
You must be signed in to change notification settings - Fork 821
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe your environment
OS: Ubuntu
Python version: Python 3.12.7
Package version: 1.38.0/0.59b0
An app instrumented with DjangoInstrumentor via auto-instrumentation.
What happened?
If exemplars are enabled (by setting exemplar filter), some metrics generated by some instrumentors export incomplete exemplars that have timestamps and values, but are missing trace ID and span ID (not very useful). Specific metrics affected include semconv-defined http.server.request.duration and http.server.duration from DjangoInstrumentor histogram record calls.
Steps to Reproduce
- Follow the example and provide MeterProvider with exemplar_filter=AlwaysOnExemplarFilter.
- Run an otel-collector locally with debug metrics export.
- Auto-instrument and run a Django app, with a route that responds after about 500ms.
- Make requests to that route and check exported metrics.
Expected Result
Exemplar #0
-> Trace ID: <a_valid_trace_id>
-> Span ID: <a_valid_span_id>
-> Timestamp: 2025-11-14 21:47:09.021649 +0000 UTC
-> Value: 167.652562
Actual Result
Exemplar #0
-> Trace ID:
-> Span ID:
-> Timestamp: 2025-11-14 21:47:09.021649 +0000 UTC
-> Value: 167.652562
Additional context
Related to
- FlaskInstrumentor
http.server.request.durationexemplars are missing span context #3913 - Fix exemplar support #3031
Would you like to implement a fix?
Yes
Tip
React with 👍 to help prioritize this issue. Please use comments to provide useful context, avoiding +1 or me too, to help us triage it. Learn more here.
cheempz
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working