diff --git a/resalloc/client.py b/resalloc/client.py index 3db5530..1826320 100644 --- a/resalloc/client.py +++ b/resalloc/client.py @@ -23,15 +23,6 @@ class _WrappedXMLRPCClient(object): def __init__(self, connection_string, survive_server_restart): self._conn = C_XMLRPC(connection_string) self.survive_server_restart = survive_server_restart - self._retry_errors = [ - errno.ECONNREFUSED, - errno.ECONNABORTED, - errno.ECONNRESET, - errno.ENETUNREACH, - errno.ENETRESET, - errno.ENETDOWN, - errno.EADDRNOTAVAIL, - ] def call(self, name, *args): """ @@ -43,11 +34,10 @@ def call(self, name, *args): while True: try: return fcall(*args) - except socket.error as os_e: + except socket.error as sock_err: + print(str(sock_err), file=sys.stderr) if not self.survive_server_restart: raise - if os_e.errno not in self._retry_errors: - raise except RPCEXCEPTION as ex: print(str(ex), file=sys.stderr) time.sleep(3)