From 8c203cf0e1b9558b54030c284ddf7706d64cdde2 Mon Sep 17 00:00:00 2001 From: Sebastian Falbesoner Date: Sat, 7 Aug 2021 13:47:57 +0200 Subject: contrib: catch bitcoin-cli RPC call errors in getcoins.py --- contrib/signet/getcoins.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'contrib') diff --git a/contrib/signet/getcoins.py b/contrib/signet/getcoins.py index d0a12beb29..86755e6305 100755 --- a/contrib/signet/getcoins.py +++ b/contrib/signet/getcoins.py @@ -31,6 +31,10 @@ def bitcoin_cli(rpc_command_and_params): except FileNotFoundError: print('The binary', args.cmd, 'could not be found.') exit() + except subprocess.CalledProcessError: + cmdline = ' '.join(argv) + print(f'-----\nError while calling "{cmdline}" (see output above).') + exit() if args.faucet.lower() == DEFAULT_GLOBAL_FAUCET: -- cgit v1.2.3