From 1274ffdf879537f2ec13ee71b98d04693c0af179 Mon Sep 17 00:00:00 2001 From: Sunil Mohan Adapa Date: Fri, 1 Mar 2024 20:09:25 -0800 Subject: [PATCH] actions: Fix log message when action return can't be decoded return_value is not available during exception handling. Signed-off-by: Sunil Mohan Adapa Reviewed-by: James Valleroy --- plinth/actions.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/plinth/actions.py b/plinth/actions.py index b98eebab2..a9e7b7cb1 100644 --- a/plinth/actions.py +++ b/plinth/actions.py @@ -134,9 +134,8 @@ def _wait_for_return(module_name, action_name, args, kwargs, log_error, proc, try: return_value = json.loads(b''.join(buffers)) except json.JSONDecodeError: - logger.error( - 'Error decoding action return value %s..%s(*%s, **%s): %s', - module_name, action_name, args, kwargs, return_value) + logger.error('Error decoding action return value %s..%s(*%s, **%s)', + module_name, action_name, args, kwargs) raise if return_value['result'] == 'success':