"ImportInTheMiddle" will crash at run-time #4691
Labels
bug
Something isn't working
priority:p1
Bugs which cause problems in end-user applications such as crashes, data inconsistencies, etc
What happened?
Warning output from
esbuild
bundler.From the code, I would have to agree with the warning that this will crash if used.
I don't understand how you could import like this:It is not valid to import like this:
opentelemetry-js/experimental/packages/opentelemetry-instrumentation/src/platform/node/instrumentation.ts
Line 28 in ca027b5
And then instantiate like this:
opentelemetry-js/experimental/packages/opentelemetry-instrumentation/src/platform/node/instrumentation.ts
Lines 308 to 313 in ca027b5
It will absolutely throw an exception.
For ESM, the instantiation would need to look like:
But there are lots of things I do not know, so would be interested to hear if this would actually work!The text was updated successfully, but these errors were encountered: