Closed
Description
Python 3.8 / Flask injector 0.17b0
Steps to reproduce
If jaeger is the text map and you do not send a carrier header then the parser fails when it tries to parse the carrier header.
if context is None:
context = get_current()
fields = _extract_first_element(
getter.get(carrier, self.TRACE_ID_KEY)
).split(":")
**What is the expected **
Parse as invalid span. Code continues.
What is the actual behavior?
File "/usr/local/lib/python3.8/site-packages/opentelemetry/propagators/jaeger/__init__.py", line 48, in extract
fields = _extract_first_element(
AttributeError: 'NoneType' object has no attribute ‘split’
Additional context
TraceContextTextMapPropagator does this:
header = getter.get(carrier, self._TRACEPARENT_HEADER_NAME)
if not header:
return trace.set_span_in_context(trace.INVALID_SPAN, context)