Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions contrib/pyln-testing/pyln/testing/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -364,16 +364,18 @@ class SimpleBitcoinProxy:
throwaway connections. This is easier than to reach into the RPC
library to close, reopen and reauth upon failure.
"""
def __init__(self, btc_conf_file, *args, **kwargs):
def __init__(self, btc_conf_file, timeout=TIMEOUT, *args, **kwargs):
self.__btc_conf_file__ = btc_conf_file
self.__timeout__ = timeout

def __getattr__(self, name):
if name.startswith('__') and name.endswith('__'):
# Python internal stuff
raise AttributeError

# Create a callable to do the actual call
proxy = BitcoinProxy(btc_conf_file=self.__btc_conf_file__)
proxy = BitcoinProxy(btc_conf_file=self.__btc_conf_file__,
timeout=self.__timeout__)

def f(*args):
logging.debug("Calling {name} with arguments {args}".format(
Expand Down
Loading