From c35d4ebb3ac790d0a5fbe99584a2100bc591b272 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Brunner?= Date: Wed, 12 Jul 2023 15:48:03 +0200 Subject: [PATCH] Add more messages --- scan_to_paperless/process.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/scan_to_paperless/process.py b/scan_to_paperless/process.py index bf9579c5..1b2e63a0 100755 --- a/scan_to_paperless/process.py +++ b/scan_to_paperless/process.py @@ -1840,7 +1840,13 @@ def main() -> None: shutil.rmtree(root_folder) elif job_type == JobType.CODE: assert name is not None - _process_code(name) + print(f"Process code '{name}'") + try: + _process_code(name) + except Exception as exception: + print(exception) + trace = traceback.format_exc() + print(trace) elif job_type == JobType.NONE: status.set_global_status("Waiting...") status.set_current_folder(None)