You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
There is a conflict arising from multiple versions of the opentelemetry crate being pulled into the same dependency graph, causing the compiler to see traits (like Tracer) as coming from different crates. Despite explicitly aligning dependencies (e.g., opentelemetry, opentelemetry-jaeger, and tracing-opentelemetry) to the same version, transitive dependencies still bring in older or newer opentelemetry versions. This leads to errors such as “the trait comes from a different crate version,” as well as a nested “overflow evaluating the requirement” involving ordered_float and thrift. The issue persists when building or testing, resulting in compilation failures and Clippy checks that cannot complete successfully.
To Reproduce
Below is a minimal project setup demonstrating the issue. Attempting to build this project will produce errors related to multiple versions of the opentelemetry crate.
Place the following code in any testing module (This behavior was originally reserved in the range check test plan)
(Note this may or may not work, the behavior is very inconsistent.)
Expected behavior
After aligning the opentelemetry dependencies to a single version, we expect the project to compile successfully without trait-version conflicts. The Jaeger tracer should install cleanly, allowing spans to be emitted through tracing-opentelemetry or any other instrumentation layer, with no errors related to multiple opentelemetry crates in the dependency graph.
Additional context
This conflict often arises when multiple crates (like opentelemetry-jaeger and tracing-opentelemetry) have different semver ranges for opentelemetry, pulling in mismatched versions (e.g., 0.21.x and 0.22.x).
The issue can manifest as both trait-incompatibility errors (the trait comes from a different crate version) and infinite nesting errors for crates like ordered-float, especially if thrift is involved.
Workarounds might? involve consolidating all crates on the same version of opentelemetry (this failed in my attempts so far) (and possibly thrift), or using the HTTP transport instead of Thrift to avoid older ordered-float. (havent tried this yet)
The text was updated successfully, but these errors were encountered:
Describe the bug
There is a conflict arising from multiple versions of the
opentelemetry
crate being pulled into the same dependency graph, causing the compiler to see traits (likeTracer
) as coming from different crates. Despite explicitly aligning dependencies (e.g.,opentelemetry
,opentelemetry-jaeger
, andtracing-opentelemetry
) to the same version, transitive dependencies still bring in older or neweropentelemetry
versions. This leads to errors such as “the trait comes from a different crate version,” as well as a nested “overflow evaluating the requirement” involvingordered_float
andthrift
. The issue persists when building or testing, resulting in compilation failures and Clippy checks that cannot complete successfully.To Reproduce
Below is a minimal project setup demonstrating the issue. Attempting to build this project will produce errors related to multiple versions of the
opentelemetry
crate.Place the following code in any testing module (This behavior was originally reserved in the range check test plan)
(Note this may or may not work, the behavior is very inconsistent.)
Expected behavior
After aligning the
opentelemetry
dependencies to a single version, we expect the project to compile successfully without trait-version conflicts. The Jaeger tracer should install cleanly, allowing spans to be emitted throughtracing-opentelemetry
or any other instrumentation layer, with no errors related to multipleopentelemetry
crates in the dependency graph.Additional context
opentelemetry-jaeger
andtracing-opentelemetry
) have different semver ranges foropentelemetry
, pulling in mismatched versions (e.g.,0.21.x
and0.22.x
).the trait comes from a different crate version
) and infinite nesting errors for crates likeordered-float
, especially ifthrift
is involved.opentelemetry
(this failed in my attempts so far) (and possiblythrift
), or using the HTTP transport instead of Thrift to avoid olderordered-float
. (havent tried this yet)The text was updated successfully, but these errors were encountered: