Skip to content

Commit 4fe61bf

Browse files
committed
ref(transport): Add missing transport instantiation in non-async context
GH-4582
1 parent 176a1d1 commit 4fe61bf

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

sentry_sdk/transport.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1027,6 +1027,8 @@ def make_transport(options: Dict[str, Any]) -> Optional[Transport]:
10271027
# No event loop running, fall back to sync transport
10281028
logger.warning("No event loop running, falling back to sync transport.")
10291029
transport_cls = Http2Transport if use_http2_transport else HttpTransport
1030+
else:
1031+
transport_cls = Http2Transport if use_http2_transport else HttpTransport
10301032

10311033
if isinstance(ref_transport, Transport):
10321034
return ref_transport

0 commit comments

Comments
 (0)