From 8d4598bb21697089bc30fddc2ead501f5a68f3ed Mon Sep 17 00:00:00 2001 From: belikor Date: Sun, 11 Jul 2021 18:35:35 -0500 Subject: [PATCH] cli.py: print exception if there is a problem As reported in issue #2769, the `lbrynet` daemon doesn't respond correctly when it is compiled against Python 3.8+, only with Python 3.7. In this case it will raise the exception `aiohttp.ClientConnectionError` We want to print this exception for the future to know what went wrong. --- lbry/extras/cli.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lbry/extras/cli.py b/lbry/extras/cli.py index 5df93f9e13..18c12e8582 100644 --- a/lbry/extras/cli.py +++ b/lbry/extras/cli.py @@ -37,7 +37,8 @@ async def execute_command(conf, method, params, callback=display): return callback(data['error']) except Exception as e: log.exception('Could not process response from server:', exc_info=e) - except aiohttp.ClientConnectionError: + except aiohttp.ClientConnectionError as cce: + log.exception("Exception: ", exc_info=cce) print("Could not connect to daemon. Are you sure it's running?")