Skip to content

[deps][core] Bump OpenTelemetry to 1.40 / 0.61b0 to fix headers - #66698

Open
maurerle wants to merge 1 commit into
ray-project:masterfrom
maurerle:deps/otel-1.40-exporter-prometheus-0.61
Open

maurerle wants to merge 1 commit into
ray-project:masterfrom
maurerle:deps/otel-1.40-exporter-prometheus-0.61

Conversation

@maurerle

@maurerle maurerle commented Oct 3, 2026

Copy link
Copy Markdown

Description

Duplicate Prometheus HELP/TYPE headers were sent with 0.60b0.

opentelemetry-exporter-prometheus 0.60b0 emits a separate HELP/TYPE block when samples of one metric carry different label-key sets (for example ray_serve_event_loop_scheduling_latency_ms from the Serve proxy and from a replica). The text exposition format allows one HELP line per metric name, so strict parsers reject the whole /metrics page. 0.61b0 fixes this in the exporter.

The exporter is unpinned in setup.py and requirements.txt; its version comes from the compiled locks, which follow the family pins in test-requirements.txt. Bump api, sdk, proto and exporter-otlp-proto-grpc to 1.40.0, and exporter-prometheus, semantic-conventions and instrumentation-fastapi to 0.61b0 (fastapi pins semantic-conventions to its own version).

Related issues

Fixes #64609

Additional information

Regenerated with:
./ci/ci.sh compile_pip_dependencies (Python 3.11, pip-tools 7.4.1)
bazelisk run //ci/raydepsets:raydepsets -- build --all-configs

requirements_compiled_py3.14.txt and the py3.14 locks are left as they are.

…metheus HELP/TYPE headers

opentelemetry-exporter-prometheus 0.60b0 emits a separate HELP/TYPE block
when samples of one metric carry different label-key sets (for example
ray_serve_event_loop_scheduling_latency_ms from the Serve proxy and from a
replica). The text exposition format allows one HELP line per metric name,
so strict parsers reject the whole /metrics page. 0.61b0 fixes this in the
exporter.

The exporter is unpinned in setup.py and requirements.txt; its version comes
from the compiled locks, which follow the family pins in
test-requirements.txt. Bump api, sdk, proto and exporter-otlp-proto-grpc to
1.40.0, and exporter-prometheus, semantic-conventions and
instrumentation-fastapi to 0.61b0 (fastapi pins semantic-conventions
to its own version).

Regenerated with:
  ./ci/ci.sh compile_pip_dependencies          (Python 3.11, pip-tools 7.4.1)
  bazelisk run //ci/raydepsets:raydepsets -- build --all-configs

requirements_compiled_py3.14.txt and the py3.14 locks are left as they are.

Fixes ray-project#64609

Assisted-by: claude:sonnet-5-5
Signed-off-by: Florian Maurer <[email protected]>
@maurerle
maurerle requested review from a team as code owners October 3, 2026 21:33

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates OpenTelemetry dependencies across multiple Python dependency lock files and requirement definitions. Specifically, it upgrades core OpenTelemetry packages (such as opentelemetry-api, opentelemetry-sdk, and opentelemetry-proto) from version 1.39.0 to 1.40.0, and related instrumentation and exporter packages from version 0.60b0 to 0.61b0. I have no feedback to provide as these are standard dependency updates.

@ray-gardener ray-gardener Bot added core Issues that should be addressed in Ray Core community-contribution Contributed by the community labels Oct 4, 2026
@MortalHappiness MortalHappiness removed their assignment Oct 15, 2026
@github-actions

github-actions Bot commented Nov 7, 2026

Copy link
Copy Markdown

This pull request has been automatically marked as stale because it has not had
any activity for 14 days. It will be closed in another 14 days if no further activity occurs.
Thank you for your contributions.

You can always ask for help on our discussion forum or Ray's public slack channel.

If you'd like to keep this open, just leave any comment, and the stale label will be removed.

@github-actions github-actions Bot added the stale The issue is stale. It will be closed within 7 days unless there are further conversation label Nov 7, 2026
@maurerle

maurerle commented Nov 7, 2026

Copy link
Copy Markdown
Author

@elliot-barn can you check this please?

@github-actions github-actions Bot added unstale A PR that has been marked unstale. It will not get marked stale again if this label is on it. and removed stale The issue is stale. It will be closed within 7 days unless there are further conversation labels Nov 7, 2026
jeffreywang88 added a commit that referenced this pull request Nov 20, 2026
…12+ (#68360)

## Overview

vLLM 0.34.0 needs `opentelemetry>=1.45.1` and `filelock>=4.2.4`. Ray
pins OpenTelemetry 1.39.0 and filelock 3.29.0 in
`requirements_compiled.txt`, and the rayllm depsets are built on top of
that, so the vLLM bump can't resolve. This PR lifts both pins for all of
Ray. The vLLM bump itself is stacked on top in #68361.

## Approach

- **OpenTelemetry:** bump the family pins in `test-requirements.txt` to
1.45.2 (api, sdk, proto, exporter-otlp-proto-grpc) and 0.66b2
(exporter-prometheus, semantic-conventions, instrumentation-fastapi).
- **filelock:** add a `>=4.2.4` floor on Python 3.12+ only. `aim` (tune
tests, Python < 3.12) caps filelock below 4, even in its latest release,
so 3.10/3.11 stay on 3.29.0. The same floor goes in
`base-test-requirements.txt`, which only the rayllm base depset reads.
- Regenerated `requirements_compiled.txt` (`ci/ci.sh
compile_pip_dependencies`, Python 3.11, pip-tools 7.4.1),
`requirements_compiled_py3.14.txt` (`compile_pip_dependencies_py314`),
and every depset (`raydepsets build --all-configs`). Apart from
OpenTelemetry and filelock, the only other change is
`snowflake-connector-python` 4.8 → 5.2 on Python 3.14, because 4.8 caps
filelock below 4.
- #66698 bumps OpenTelemetry to 1.40 to fix duplicate Prometheus
headers. This PR goes further to 1.45.2, so it would replace that one.

## Validation

- `python/ray/tests/test_open_telemetry_metric_recorder.py`: 19 passed.
- `python/ray/serve/tests/test_serve_with_tracing.py`: passed.
- Drove `OpenTelemetryMetricRecorder` through `PrometheusMetricReader`
with a gauge, counter, sum and histogram, including one metric with two
different label sets. The scraped output parses with
`prometheus_client`, has one HELP block per metric, and is identical on
1.39.0 and 1.45.2.
- `test_metrics_agent.py` and `dashboard/.../test_reporter.py`: the
failures I saw locally come from my dev box (a Ray cluster already
running there, no dashboard frontend build, no DNS). The same 17 tests
fail the same way with the old pins, so I'm relying on CI for these.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Signed-off-by: Jeffrey Wang <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community-contribution Contributed by the community core Issues that should be addressed in Ray Core unstale A PR that has been marked unstale. It will not get marked stale again if this label is on it.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Core][metrics] Duplicate metric headers being emitted

3 participants