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 your environment
Python 3.9 on mac; opentelemetry 1.0.0; jaeger tracer
Steps to reproduce
Trying to set status code of a span to StatusCode.ERROR span.set_status(tracer.status.StatusCode.ERROR) fails due Status object not having status_code set
What is the expected behavior?
The default value should have worked for Status.status_code
What is the actual behavior?
if status.status_code is not StatusCode.UNSET:
AttributeError: 'StatusCode' object has no attribute 'status_code'
I think leaving this as it is an invitation to have people fall into this pit, like I just di. Either the interface should be extended to see if the caller passed a valid code or improve the documentation to make it clear what is expected and how someone can work around it. I am happy to do the documentation update if someone can tell me how I can propose a documentation change.
Describe your environment
Python 3.9 on mac; opentelemetry 1.0.0; jaeger tracer
Steps to reproduce
Trying to set status code of a span to
StatusCode.ERROR
span.set_status(tracer.status.StatusCode.ERROR)
fails due Status object not havingstatus_code
setWhat is the expected behavior?
The default value should have worked for
Status.status_code
What is the actual behavior?
Additional context
Workaround:
The text was updated successfully, but these errors were encountered: