Skip to content

Commit fab9899

Browse files
author
MarcoFalke
committed
test: Try once more when RPC connection fails on Windows
1 parent faa6557 commit fab9899

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

test/functional/test_framework/authproxy.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,15 @@ def _request(self, method, path, postdata):
112112
self.__conn.close()
113113
self.__conn.request(method, path, postdata, headers)
114114
return self._get_response()
115+
except OSError as e:
116+
retry = (
117+
'[WinError 10053] An established connection was aborted by the software in your host machine' in str(e))
118+
if retry:
119+
self.__conn.close()
120+
self.__conn.request(method, path, postdata, headers)
121+
return self._get_response()
122+
else:
123+
raise
115124

116125
def get_request(self, *args, **argsn):
117126
AuthServiceProxy.__id_count += 1

0 commit comments

Comments
 (0)