Even when socket is not specified, python will connect to socket unless host != localhost, for this reason we should add checking the socket to the error message