Permalink
Browse files

Merge #7751: test_framework: python3.4 authproxy compat

e7e48ba test_framework: Py3.4 compat: Specify timeout parameter by name (Luke Dashjr)
d7b80b5 test_framework: Avoid infinite loop in encoding Decimal (Wladimir J. van der Laan)
  • Loading branch information...
laanwj committed Mar 28, 2016
2 parents 0b98dd7 + e7e48ba commit 84370d58ffc6d5ea22efa0e579dea00f860ad369
Showing with 3 additions and 4 deletions.
  1. +3 −4 qa/rpc-tests/test_framework/authproxy.py
@@ -61,7 +61,7 @@ def __init__(self, rpc_error):
def EncodeDecimal(o):
if isinstance(o, decimal.Decimal):
return round(o, 8)
return str(o)
raise TypeError(repr(o) + " is not JSON serializable")
class AuthServiceProxy(object):
@@ -92,11 +92,10 @@ def __init__(self, service_url, service_name=None, timeout=HTTP_TIMEOUT, connect
self.__conn = connection
elif self.__url.scheme == 'https':
self.__conn = httplib.HTTPSConnection(self.__url.hostname, port,
None, None, False,
timeout)
timeout=timeout)
else:
self.__conn = httplib.HTTPConnection(self.__url.hostname, port,
False, timeout)
timeout=timeout)
def __getattr__(self, name):
if name.startswith('__') and name.endswith('__'):

0 comments on commit 84370d5

Please sign in to comment.