Skip to content

Fix #4511: Widen opentelemetry version constraints to support >=1.34.0,<2#4512

Open
devin-ai-integration[bot] wants to merge 1 commit intomainfrom
devin/1771430089-widen-opentelemetry-version
Open

Fix #4511: Widen opentelemetry version constraints to support >=1.34.0,<2#4512
devin-ai-integration[bot] wants to merge 1 commit intomainfrom
devin/1771430089-widen-opentelemetry-version

Conversation

@devin-ai-integration
Copy link
Contributor

Fix #4511: Widen opentelemetry version constraints to >=1.34.0,<2

Summary

The three opentelemetry dependencies (opentelemetry-api, opentelemetry-sdk, opentelemetry-exporter-otlp-proto-http) were pinned with ~=1.34.0, which resolves to >=1.34.0, <1.35.0. This prevented users from installing newer OpenTelemetry versions (e.g. >=1.38 or >=1.39.1) required by tools like Langfuse.

This PR widens the constraint to >=1.34.0,<2. crewAI only uses stable trace-related OpenTelemetry APIs (spans, tracer providers, baggage, context), and the only breaking change in recent releases (1.39.0) affects Log signal classes which crewAI does not use.

Adds a regression test suite (test_opentelemetry_version_compatibility.py) that verifies all OpenTelemetry imports used by crewAI resolve correctly and that the Telemetry singleton initializes successfully.

Review & Testing Checklist for Human

  • Verify the OpenTelemetry trace APIs used in telemetry/telemetry.py, telemetry/utils.py, crew.py, and flow/flow.py remain stable across 1.34–1.39+ (the only known breaking change in 1.39.0 is Log-related, not trace-related)
  • Confirm no other dependencies in the tree have conflicting OpenTelemetry version requirements that would cause resolution failures with the wider range
  • Test plan: In a fresh environment, install crewai alongside opentelemetry-exporter-otlp-proto-http>=1.39.1 (the version from the issue report) and verify dependency resolution succeeds and basic crew execution works

Notes

  • The added tests verify imports and minimum version at runtime but cannot truly validate that newer versions install correctly — that's a dependency resolution concern best verified manually or via the test plan above.
  • The uv.lock diff only updates specifier strings; the actual resolved versions may remain at 1.34.x until a uv lock --upgrade is run.

Link to Devin run: https://app.devin.ai/sessions/66fa037370db4cdca14e1cbc72abd12a
Requested by: João

Fixes #4511

The opentelemetry packages were pinned with ~=1.34.0 (>=1.34.0, <1.35.0)
which prevented users from installing newer versions needed by tools like
Langfuse. Widened to >=1.34.0,<2 since crewAI only uses stable trace APIs
that have no breaking changes across 1.x versions.

Co-Authored-By: João <joao@crewai.com>
@devin-ai-integration
Copy link
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Supporting opentelemetry-exporter-otlp-proto-http>=1.39.1

0 participants

Comments