|
42 | 42 | import certifi |
43 | 43 | import urllib3 |
44 | 44 |
|
45 | | -import sentry_sdk |
46 | 45 | from sentry_sdk.consts import EndpointType |
47 | 46 | from sentry_sdk.envelope import Envelope, Item, PayloadRef |
48 | 47 | from sentry_sdk.utils import ( |
@@ -234,9 +233,6 @@ def __init__(self: "Self", options: "Dict[str, Any]") -> None: |
234 | 233 |
|
235 | 234 | self._pool = self._make_pool() |
236 | 235 |
|
237 | | - # Backwards compatibility for deprecated `self.hub_class` attribute |
238 | | - self._hub_cls = sentry_sdk.Hub |
239 | | - |
240 | 236 | experiments = options.get("_experiments", {}) |
241 | 237 | compression_level = experiments.get( |
242 | 238 | "transport_compression_level", |
@@ -715,27 +711,6 @@ def flush( |
715 | 711 | self._worker.submit(lambda: self._flush_client_reports(force=True)) |
716 | 712 | self._worker.flush(timeout, callback) |
717 | 713 |
|
718 | | - @staticmethod |
719 | | - def _warn_hub_cls() -> None: |
720 | | - """Convenience method to warn users about the deprecation of the `hub_cls` attribute.""" |
721 | | - warnings.warn( |
722 | | - "The `hub_cls` attribute is deprecated and will be removed in a future release.", |
723 | | - DeprecationWarning, |
724 | | - stacklevel=3, |
725 | | - ) |
726 | | - |
727 | | - @property |
728 | | - def hub_cls(self: "Self") -> "type[sentry_sdk.Hub]": |
729 | | - """DEPRECATED: This attribute is deprecated and will be removed in a future release.""" |
730 | | - HttpTransport._warn_hub_cls() |
731 | | - return self._hub_cls |
732 | | - |
733 | | - @hub_cls.setter |
734 | | - def hub_cls(self: "Self", value: "type[sentry_sdk.Hub]") -> None: |
735 | | - """DEPRECATED: This attribute is deprecated and will be removed in a future release.""" |
736 | | - HttpTransport._warn_hub_cls() |
737 | | - self._hub_cls = value |
738 | | - |
739 | 714 |
|
740 | 715 | class HttpTransport(BaseHttpTransport): |
741 | 716 | if TYPE_CHECKING: |
|
0 commit comments