Skip to content

Commit

Permalink
Merge branch 'main' into feat/tolerate-missing-resource-detector
Browse files Browse the repository at this point in the history
  • Loading branch information
lzchen authored Jan 15, 2025
2 parents ac836fd + 59b225f commit a37d5c6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions opentelemetry-api/src/opentelemetry/trace/span.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def get_span_context(self) -> "SpanContext":

@abc.abstractmethod
def set_attributes(
self, attributes: typing.Dict[str, types.AttributeValue]
self, attributes: typing.Mapping[str, types.AttributeValue]
) -> None:
"""Sets Attributes.
Expand Down Expand Up @@ -529,7 +529,7 @@ def end(self, end_time: typing.Optional[int] = None) -> None:
pass

def set_attributes(
self, attributes: typing.Dict[str, types.AttributeValue]
self, attributes: typing.Mapping[str, types.AttributeValue]
) -> None:
pass

Expand Down
3 changes: 2 additions & 1 deletion opentelemetry-sdk/src/opentelemetry/sdk/trace/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
Dict,
Iterator,
List,
Mapping,
MutableMapping,
Optional,
Sequence,
Expand Down Expand Up @@ -842,7 +843,7 @@ def get_span_context(self):
return self._context

def set_attributes(
self, attributes: Dict[str, types.AttributeValue]
self, attributes: Mapping[str, types.AttributeValue]
) -> None:
with self._lock:
if self._end_time is not None:
Expand Down

0 comments on commit a37d5c6

Please sign in to comment.