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

otlp-exporter-base dependency missing from exporter-metrics-otlp-grpc package.json #4676

Closed
AkselAllas opened this issue May 3, 2024 · 6 comments
Labels
bug Something isn't working priority:p3 Bugs which cause problems in user apps not related to correctness (performance, memory use, etc)

Comments

@AkselAllas
Copy link
Contributor

What happened?

Steps to Reproduce

Do yarn install with @opentelemetry/exporter-metrics-otlp-grpc on version 0.51.0 using yarn pnp strict dependency rules

Expected Result

Yarn install works without error

Actual Result

Detailed stack trace: Error: @opentelemetry/exporter-metrics-otlp-grpc tried to access @opentelemetry/otlp-exporter-base, but it isn't declared in its dependencies; this makes the require call ambiguous and unsound.
Required package: @opentelemetry/otlp-exporter-base
Required by: @opentelemetry/exporter-metrics-otlp-grpc@virtual:0e8d30257f6e33936217598ef900b94f1b294bbce7b03c20ed9c3af65702595842b2f981b404c2463ceedd52ea9047bc333bca7e68fff8c8980a6a79afccaa5a#npm:0.51.0 (via /workspace/.yarn/__virtual__/@opentelemetry-exporter-metrics-otlp-grpc-virtual-450b745067/0/cache/@opentelemetry-exporter-metrics-otlp-grpc-npm-0.51.0-46e1e63463-69d3c14e6a.zip/node_modules/@opentelemetry/exporter-metrics-otlp-grpc/build/src/)
Require stack:
- /workspace/.yarn/__virtual__/@opentelemetry-exporter-metrics-otlp-grpc-virtual-450b745067/0/cache/@opentelemetry-exporter-metrics-otlp-grpc-npm-0.51.0-46e1e63463-69d3c14e6a.zip/node_modules/@opentelemetry/exporter-metrics-otlp-grpc/build/src/OTLPMetricExporter.js
- /workspace/.yarn/__virtual__/@opentelemetry-exporter-metrics-otlp-grpc-virtual-450b745067/0/cache/@opentelemetry-exporter-metrics-otlp-grpc-npm-0.51.0-46e1e63463-69d3c14e6a.zip/node_modules/@opentelemetry/exporter-metrics-otlp-grpc/build/src/index.js

Additional Details

This is caused by
https://github.com/open-telemetry/opentelemetry-js/blob/main/experimental/packages/opentelemetry-exporter-metrics-otlp-grpc/package.json
missing require for
https://github.com/open-telemetry/opentelemetry-js/blob/main/experimental/packages/opentelemetry-exporter-metrics-otlp-grpc/src/OTLPMetricExporter.ts#L35

OpenTelemetry Setup Code

No response

package.json

No response

Relevant log output

No response

@AkselAllas AkselAllas added bug Something isn't working triage labels May 3, 2024
@AkselAllas AkselAllas changed the title otlp-exporter-base dependency missing from `exporter-metrics-otlp-grpc package.json otlp-exporter-base dependency missing from exporter-metrics-otlp-grpc package.json May 3, 2024
@AkselAllas
Copy link
Contributor Author

@dyladan ?

@dyladan
Copy link
Member

dyladan commented May 3, 2024

No need to ping me directly when creating an issue as I get a notification when it's created

@dyladan
Copy link
Member

dyladan commented May 3, 2024

Looks like this hasn't caused problems so far because otlp-exporter-base is a subdependency so the require doesn't fail. Yarn is more strict about requiring explicit dependencies in package.json. @AkselAllas are you planning to open a PR?

@dyladan dyladan added priority:p3 Bugs which cause problems in user apps not related to correctness (performance, memory use, etc) and removed triage labels May 3, 2024
@dyladan
Copy link
Member

dyladan commented May 3, 2024

Marking this as p3 because it is possible to make yarn be less strict with flags, although it is definitely a bug.

@AkselAllas
Copy link
Contributor Author

AkselAllas commented May 3, 2024

@dyladan seems simple enough 🤔 #4678

@pichlermarc
Copy link
Member

Closed by #4678

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working priority:p3 Bugs which cause problems in user apps not related to correctness (performance, memory use, etc)
Projects
None yet
Development

No branches or pull requests

3 participants