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

no exported member 'LogLevel' #2145

Closed
rgarcia opened this issue Apr 21, 2021 · 3 comments · Fixed by #2504
Closed

no exported member 'LogLevel' #2145

rgarcia opened this issue Apr 21, 2021 · 3 comments · Fixed by #2504
Assignees
Labels
document Documentation-related

Comments

@rgarcia
Copy link

rgarcia commented Apr 21, 2021

Please answer these questions before submitting a bug report.

What version of OpenTelemetry are you using?

latest published release

What version of Node are you using?

v12

Please provide the code you used to setup the OpenTelemetry SDK

the example here https://github.com/open-telemetry/opentelemetry-js/blob/main/getting-started/ts-example/README.md#initialize-a-global-tracer

What did you do?

ran that example code

What did you expect to see?

successfully compiled code

What did you see instead?

two compile errors

Module '".../node_modules/@opentelemetry/core/build/src/ index"' has no exported member 'LogLevel'. (2305)
tracing.ts (9,3): Argument of type '{ logLevel: any; }' is not assignable to parameter of type 'NodeTracerConfig'.

Additional context

Add any other context about the problem here.

@rgarcia rgarcia added the bug Something isn't working label Apr 21, 2021
@weyert
Copy link
Contributor

weyert commented Apr 22, 2021

I think you are looking for:

import api, { DiagConsoleLogger, DiagLogLevel } from '@opentelemetry/api'
api.diag.setLogger(new DiagConsoleLogger(), DiagLogLevel.DEBUG)

@gruber76
Copy link

gruber76 commented May 20, 2021

Documentation will need to be updated. Not sure where else this may be but the NodeJS Getting Started page step 1 doesn't work as written, any more. (Possibly this is a bug belongs on the .io registry, under the circumstances.)

@mustafain117
Copy link
Contributor

@alolita I would like to work on this issue(updating getting started docs for typescript), please assign this to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
document Documentation-related
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants