--- a/RefactoringRope/JsonClient.py Sat Nov 10 17:40:03 2018 +0100 +++ b/RefactoringRope/JsonClient.py Sun Nov 11 17:44:55 2018 +0100 @@ -122,13 +122,21 @@ Public method implementing the main loop of the client. """ try: + selectErrors = 0 while True: try: rrdy, wrdy, xrdy = select.select( [self.__connection], [], []) except (select.error, KeyboardInterrupt, socket.error): - # just carry on - continue + selectErrors += 1 + if selectErrors <= 10: # selected arbitrarily + # just carry on + continue + else: + break + + # reset select errors + selectErrors = 0 if self.__connection in rrdy: method, params = self.__receiveJson()