From 27bbd916353ac391a5adbe7fdf03aecedc5f72b9 Mon Sep 17 00:00:00 2001 From: Alex Grintsvayg Date: Fri, 4 Oct 2019 11:25:01 -0400 Subject: [PATCH] include fn name and args in jsonrpc error message --- lbry/lbry/extras/daemon/Daemon.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lbry/lbry/extras/daemon/Daemon.py b/lbry/lbry/extras/daemon/Daemon.py index 93659266c..71238fadf 100644 --- a/lbry/lbry/extras/daemon/Daemon.py +++ b/lbry/lbry/extras/daemon/Daemon.py @@ -591,7 +591,9 @@ class Daemon(metaclass=JSONRPCServerType): except Exception as e: # pylint: disable=broad-except log.exception("error handling api request") return JSONRPCError( - str(e), JSONRPCError.CODE_APPLICATION_ERROR, format_exc() + f"Error calling {function_name} with args {args}\n" + str(e), + JSONRPCError.CODE_APPLICATION_ERROR, + format_exc() ) def _verify_method_is_callable(self, function_path):