File tree Expand file tree Collapse file tree 1 file changed +1
-3
lines changed Expand file tree Collapse file tree 1 file changed +1
-3
lines changed Original file line number Diff line number Diff line change @@ -492,8 +492,6 @@ async def read_from_socket(
492
492
# data was read from the socket and added to the buffer.
493
493
# return True to indicate that data was read.
494
494
return True
495
- except asyncio .CancelledError :
496
- raise
497
495
except (socket .timeout , asyncio .TimeoutError ):
498
496
if raise_on_timeout :
499
497
raise TimeoutError ("Timeout reading from socket" ) from None
@@ -708,7 +706,7 @@ async def connect(self):
708
706
try :
709
707
await self ._connect ()
710
708
except asyncio .CancelledError :
711
- raise
709
+ raise # in 3.7 and earlier, this is an Exception, not BaseException
712
710
except (socket .timeout , asyncio .TimeoutError ):
713
711
raise TimeoutError ("Timeout connecting to server" )
714
712
except OSError as e :
You can’t perform that action at this time.
0 commit comments