Skip to content

Commit fe27100

Browse files
committed
ref(transport) Refactor class names to reflect previous functionality
Refactored class names such that BaseHttpTransport now has the same functionality as before the hierarchy refactor GH-4568
1 parent 19f7211 commit fe27100

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

sentry_sdk/client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
)
2626
from sentry_sdk.serializer import serialize
2727
from sentry_sdk.tracing import trace
28-
from sentry_sdk.transport import BaseHttpTransport, make_transport
28+
from sentry_sdk.transport import HttpTransportCore, make_transport
2929
from sentry_sdk.consts import (
3030
SPANDATA,
3131
DEFAULT_MAX_VALUE_LENGTH,
@@ -403,7 +403,7 @@ def _capture_envelope(envelope: Envelope) -> None:
403403
self.monitor
404404
or self.log_batcher
405405
or has_profiling_enabled(self.options)
406-
or isinstance(self.transport, BaseHttpTransport)
406+
or isinstance(self.transport, HttpTransportCore)
407407
):
408408
# If we have anything on that could spawn a background thread, we
409409
# need to check if it's safe to use them.

sentry_sdk/transport.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ def _parse_rate_limits(
168168
continue
169169

170170

171-
class BaseHttpTransport(Transport):
171+
class HttpTransportCore(Transport):
172172
"""The base HTTP transport."""
173173

174174
TIMEOUT = 30 # seconds
@@ -502,7 +502,7 @@ def kill(self: Self) -> None:
502502
self._worker.kill()
503503

504504

505-
class BaseSyncHttpTransport(BaseHttpTransport):
505+
class BaseHttpTransport(HttpTransportCore):
506506

507507
def _send_envelope(self: Self, envelope: Envelope) -> None:
508508
_prepared_envelope = self._prepare_envelope(envelope)
@@ -568,7 +568,7 @@ def flush(
568568
self._worker.flush(timeout, callback)
569569

570570

571-
class HttpTransport(BaseSyncHttpTransport):
571+
class HttpTransport(BaseHttpTransport):
572572
if TYPE_CHECKING:
573573
_pool: Union[PoolManager, ProxyManager]
574574

@@ -685,7 +685,7 @@ def __init__(self: Self, options: Dict[str, Any]) -> None:
685685

686686
else:
687687

688-
class Http2Transport(BaseSyncHttpTransport): # type: ignore
688+
class Http2Transport(BaseHttpTransport): # type: ignore
689689
"""The HTTP2 transport based on httpcore."""
690690

691691
TIMEOUT = 15

0 commit comments

Comments
 (0)