mirror of
https://github.com/facebook/sapling.git
synced 2024-10-05 14:28:17 +03:00
py: raise a TimeoutError instead of using socket.timeout
Summary: The latter is deprecated, and since this file doesn't import socket, this code simply doesn't run. Reviewed By: fanzeyi Differential Revision: D34317839 fbshipit-source-id: 91baf5750153f7251385ec676edcd82dd5c331be
This commit is contained in:
parent
48473ab389
commit
00a924a2b5
@ -182,7 +182,7 @@ class WindowsSocketHandle(object):
|
||||
"Windows UDS: Connection refused",
|
||||
)
|
||||
elif errcode == WSAETIMEDOUT:
|
||||
raise socket.timeout()
|
||||
raise TimeoutError(errno.ETIMEDOUT, "Windows UDS: Socket timeout")
|
||||
elif errcode == WSAEWOULDBLOCK:
|
||||
raise OSError(
|
||||
errno.EWOULDBLOCK,
|
||||
|
Loading…
Reference in New Issue
Block a user