Closed jeffsawatzky closed 5 years ago
According to "https://docs.python.org/2/library/socket.html#socket.error" a socket error should be raised with either a string, or a pair (errno, string).
(errno, string)
I seem to be getting error: 104 from: https://github.com/Lukasa/hyper/blob/070dd32ec9caafebe7fa766fe9e73ff85babf07a/hyper/ssl_compat.py#L130
error: 104
which suggests that the error is being raised with just the error code and therefore the errno property is not available to compare to a constant in the errno module.
errno
Ah, in Python 3 socket.error is an OSError which is why the code is written this way.
socket.error
OSError
If you can write a failing test for Python 2 I'd be happy to add a fix for this.
According to "https://docs.python.org/2/library/socket.html#socket.error" a socket error should be raised with either a string, or a pair
(errno, string)
.I seem to be getting
error: 104
from: https://github.com/Lukasa/hyper/blob/070dd32ec9caafebe7fa766fe9e73ff85babf07a/hyper/ssl_compat.py#L130which suggests that the error is being raised with just the error code and therefore the
errno
property is not available to compare to a constant in the errno module.