diff --git a/sentry_sdk/tracing.py b/sentry_sdk/tracing.py index 13d9f63d5e..a3212a7745 100644 --- a/sentry_sdk/tracing.py +++ b/sentry_sdk/tracing.py @@ -595,6 +595,11 @@ def set_tag(self, key, value): def set_data(self, key, value): # type: (str, Any) -> None + warnings.warn( + "`Span.set_data` is deprecated and will be replaced in the next major version by a new method named `Span.set_attribute`.", + DeprecationWarning, + stacklevel=2, + ) self._data[key] = value def set_status(self, value):