From ee9c9bbaad5e2f16e33c63ee12f783d7e705d85f Mon Sep 17 00:00:00 2001 From: Sven Augustin Date: Mon, 20 Oct 2025 16:38:05 +0200 Subject: [PATCH] print -> logging; fixed "peakfinder parameters" --- dap/worker.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dap/worker.py b/dap/worker.py index 46d32c8..d0dbb8d 100644 --- a/dap/worker.py +++ b/dap/worker.py @@ -2,6 +2,7 @@ import argparse from time import time_ns import numpy as np +from logzero import logger as log from algos import ( calc_apply_aggregation, calc_apply_threshold, calc_mask_pixels, calc_peakfinder_analysis, @@ -67,8 +68,8 @@ def work(backend_addr, accumulator_addr, visualisation_addr, fn_config, skip_fra try: config = config_file.load() - except Exception as e: - print(f"({pulse_id}) cannot read peakfinder parameters file: {e}", flush=True) #TODO: logging? + except: + log.exception(f"({pulse_id}) cannot read config file") results = metadata.copy()