Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OPA SDK fails 'go mod tidy' for applications depending on go.opentelemetry.io/otel v1.16.0 #6003

Closed
ghaskins opened this issue Jun 12, 2023 · 4 comments · Fixed by #6062
Closed
Labels

Comments

@ghaskins
Copy link
Contributor

Short description

Golang applications that depend on both:

  • go.opentelemetry.io/otel v1.16.0
  • github.com/open-policy-agent/opa v0.53.1

will fail with 'go mod tidy'. I believe this is due to the transitive dependency on otel v1.14.0 in OPA.

@ghaskins ghaskins added the bug label Jun 12, 2023
@ghaskins
Copy link
Contributor Author

$ go mod tidy
go: finding module for package go.opentelemetry.io/otel/metric/global
go: finding module for package go.opentelemetry.io/otel/metric/instrument/syncfloat64
go: finding module for package go.opentelemetry.io/otel/metric/instrument/syncint64
go.temporal.io/server/common/authorization imports
	github.com/open-policy-agent/opa/rego imports
	github.com/open-policy-agent/opa/plugins tested by
	github.com/open-policy-agent/opa/plugins.test imports
	github.com/open-policy-agent/opa/internal/distributedtracing imports
	github.com/open-policy-agent/opa/features/tracing imports
	go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp imports
	go.opentelemetry.io/otel/metric/global: module go.opentelemetry.io/otel/metric@latest found (v1.16.0), but does not contain package go.opentelemetry.io/otel/metric/global
go.temporal.io/server/common/authorization imports
	github.com/open-policy-agent/opa/rego imports
	github.com/open-policy-agent/opa/plugins tested by
	github.com/open-policy-agent/opa/plugins.test imports
	github.com/open-policy-agent/opa/internal/distributedtracing imports
	github.com/open-policy-agent/opa/features/tracing imports
	go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp imports
	go.opentelemetry.io/otel/metric/instrument/syncfloat64: module go.opentelemetry.io/otel/metric@latest found (v1.16.0), but does not contain package go.opentelemetry.io/otel/metric/instrument/syncfloat64
go.temporal.io/server/common/authorization imports
	github.com/open-policy-agent/opa/rego imports
	github.com/open-policy-agent/opa/plugins tested by
	github.com/open-policy-agent/opa/plugins.test imports
	github.com/open-policy-agent/opa/internal/distributedtracing imports
	github.com/open-policy-agent/opa/features/tracing imports
	go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp imports
	go.opentelemetry.io/otel/metric/instrument/syncint64: module go.opentelemetry.io/otel/metric@latest found (v1.16.0), but does not contain package go.opentelemetry.io/otel/metric/instrument/syncint64

@ghaskins
Copy link
Contributor Author

Reference: temporalio/temporal#4481

@1046102779
Copy link

The metric of Opentelemetry is currently in a mixed status. It seems that it has been changing a lot all the time, and it is too uncomfortable to upgrade every time.

@srenatus
Copy link
Contributor

There's no use fighting it, I guess. Let's get #6004 over the line.

srenatus pushed a commit to srenatus/opa that referenced this issue Jun 29, 2023
Fixes issue open-policy-agent#6003

Signed-off-by: Greg Haskins <greg@manetu.com>
srenatus pushed a commit to srenatus/opa that referenced this issue Jun 30, 2023
Fixes issue open-policy-agent#6003

Signed-off-by: Greg Haskins <greg@manetu.com>
srenatus added a commit that referenced this issue Jun 30, 2023
Fixes #6003

* test/e2e: fix distributed tracing tests
   Fixes provided by @zregvart, thank you!
* build: give up golang 1.18, it blocks OTel 1.16.0

Signed-off-by: Greg Haskins <greg@manetu.com>
Signed-off-by: Stephan Renatus <stephan@styra.com>
Co-authored-by: Greg Haskins <greg@manetu.com>
Co-authored-by: Zoran Regvart <zoran@regvart.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants