From 2fbaea191fb9f72867d1cf91dd80f2a0d3f13fea Mon Sep 17 00:00:00 2001 From: Sunil Mohan Adapa Date: Thu, 25 Sep 2025 15:12:00 -0700 Subject: [PATCH] setup: Log full exception traceback when setup fails - When an error occurs during setup thread execution and the error is not due a failed privileged action, we are left with very little information about what went run. On the other than when a privileged action fails, we will be logging the exception twice. But this is okay. Tests: - Increment the setup version of one of installed apps and raise an exception in setup() method. Notice that exception traceback in the logged message. - Increment the setup version of one of installed apps and raise an exception in setup's privileged action. Notice that exception traceback in the logged message twice. Signed-off-by: Sunil Mohan Adapa Reviewed-by: Veiko Aasa --- plinth/setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plinth/setup.py b/plinth/setup.py index a90e3f3f4..9676eadcb 100644 --- a/plinth/setup.py +++ b/plinth/setup.py @@ -350,7 +350,7 @@ def run_setup_on_apps(app_ids, allow_install=True): else: setup_apps(app_ids, allow_install=allow_install) except Exception as exception: - logger.error('Error running setup - %s', exception) + logger.exception('Error running setup - %s', exception) raise