Skip to content

Commit e1d7cdb

Browse files
committed
ref(transport): Fix type errors in async transport
Fix type errors resulting from async override and missing type definition in the async transport. GH-4582
1 parent b90daf4 commit e1d7cdb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sentry_sdk/transport.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -578,7 +578,7 @@ def __init__(self: Self, options: Dict[str, Any]) -> None:
578578
super().__init__(options)
579579
# Requires event loop at init time
580580
self._loop = asyncio.get_running_loop()
581-
self.background_tasks = set()
581+
self.background_tasks: set[asyncio.Task[None]] = set()
582582

583583
async def _send_envelope(self: Self, envelope: Envelope) -> None:
584584
_prepared_envelope = self._prepare_envelope(envelope)
@@ -616,7 +616,7 @@ async def _send_request(
616616
finally:
617617
response.close()
618618

619-
async def _request(
619+
async def _request( # type: ignore[override]
620620
self: Self,
621621
method: str,
622622
endpoint_type: EndpointType,

0 commit comments

Comments
 (0)