|
9 | 9 | # All spans created by this tracer are flat children of the Restate trace. |
10 | 10 | """ |
11 | 11 |
|
12 | | -from typing import Optional, Iterator |
| 12 | +from typing import Optional, Iterator, Sequence |
13 | 13 |
|
14 | 14 | from opentelemetry import context as context_api |
15 | | -from opentelemetry.trace import INVALID_SPAN, Span, SpanKind, Tracer, TracerProvider, use_span, _Links |
| 15 | +from opentelemetry.trace import INVALID_SPAN, Span, SpanKind, Tracer, TracerProvider, use_span, Link |
16 | 16 | from opentelemetry.trace.propagation.tracecontext import TraceContextTextMapPropagator |
17 | 17 | from opentelemetry.util import types |
18 | 18 | from opentelemetry.util._decorator import _agnosticcontextmanager |
@@ -67,7 +67,7 @@ def start_span( |
67 | 67 | context: Optional[context_api.Context] = None, |
68 | 68 | kind: SpanKind = SpanKind.INTERNAL, |
69 | 69 | attributes: types.Attributes = None, |
70 | | - links: _Links = None, |
| 70 | + links: Optional[Sequence[Link]] = None, |
71 | 71 | start_time: Optional[int] = None, |
72 | 72 | record_exception: bool = True, |
73 | 73 | set_status_on_exception: bool = True, |
@@ -97,7 +97,7 @@ def start_as_current_span( |
97 | 97 | context: Optional[context_api.Context] = None, |
98 | 98 | kind: SpanKind = SpanKind.INTERNAL, |
99 | 99 | attributes: types.Attributes = None, |
100 | | - links: _Links = None, |
| 100 | + links: Optional[Sequence[Link]] = None, |
101 | 101 | start_time: Optional[int] = None, |
102 | 102 | record_exception: bool = True, |
103 | 103 | set_status_on_exception: bool = True, |
|
0 commit comments