openai / openai/codex

OTLP metrics exporter emits only target_info while OTLP logs succeed

Open
#38,655 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

app app-server bug
Dominant language
Rust
Stars
125k
Forks
19.5k
PR merge metrics
PR metrics pending

Description

What version of the Codex App are you using (From “About Codex” dialog)?

Codex App 26.810.41047 (observed app-server version: 0.148.0-alpha.9)

What subscription do you have?

Enterprise

What platform is your computer?

Darwin 25.5.0 arm64 arm (macOS)

What issue are you seeing?

With managed OTLP HTTP/protobuf exporters configured separately for logs and metrics, the log exporter successfully delivers structured Codex events to Grafana Loki. The metrics exporter directed to the OTLP /v1/metrics endpoint does not yield Codex application metrics in Prometheus/Mimir.

After a fresh Codex start and activity, the only Codex-associated series is target_info. It has service_name=codex-app-server and resource/SDK labels with value 1. No request, token, tool, error, or latency metric series appear.

Loki receives codex.api_request, codex.sse_event, codex.user_prompt, and codex.websocket_request events, so connectivity and authentication for the log path are working.

What steps can reproduce the bug?

  1. In an Enterprise managed Codex configuration, configure separate OTLP HTTP/protobuf log and metrics exporters, using the respective /v1/logs and /v1/metrics endpoints.
  2. Refresh the signed managed configuration cache and start Codex after the refresh.
  3. Generate Codex activity.
  4. Confirm recent Codex events in Loki.
  5. Query Prometheus/Mimir after the same start time for service_name=codex-app-server, excluding a synthetic codex_otel_pipeline_probe.
  6. Observe target_info but no Codex application metric series.

What is the expected behavior?

The metrics exporter should emit documented Codex application metrics to /v1/metrics, such as request/token counters or latency metrics, after Codex activity. At minimum, the telemetry documentation should clarify if target_info is the only metric currently emitted by the Codex App.

Additional information

target_info is resource metadata, not evidence of request activity or a metrics heartbeat. Collector endpoint URLs and authorization headers have been redacted.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the managed OTLP exporter configuration and comparing the /v1/logs and /v1/metrics paths described in the report. Reproduce the query for service_name=codex-app-server after generating activity, then inspect whether documented Codex application metrics are emitted or whether the telemetry documentation needs to state that target_info is currently the only metric.

Written by the indexing model from the issue text.

Assessment

Tech stack
grafana, prometheus
Domain
observability
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.