Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
graingert authored Jan 7, 2025
1 parent 06c77dc commit 2387f99
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/anyio/_core/_sockets.py
Original file line number Diff line number Diff line change
Expand Up @@ -237,12 +237,12 @@ async def try_connect(remote_host: str, event: Event) -> None:
oserrors[0]
if len(oserrors) == 1
else ExceptionGroup(
"multiple connection attempts failed", oserrors.copy()
"multiple connection attempts failed", oserrors
)
)
raise OSError("All connection attempts failed") from cause
finally:
oserrors.clear()
del oserrors

if tls or tls_hostname or ssl_context:
try:
Expand Down

0 comments on commit 2387f99

Please sign in to comment.