daq: automation log message split between success and error

This commit is contained in:
2026-06-24 15:30:05 +02:00
committed by appleb_m
parent 7e78433974
commit 680e1561e7
+4 -2
View File
@@ -2607,6 +2607,7 @@ class AareDAQ:
if error:
msg += f"with an error"
logger.error(f"{msg}, time taken {time.perf_counter() - start} seconds.")
try:
if self.__cfg.state_busy:
self.__set_state(BeamlineStateEnum.RobotSampleExchange)
@@ -2620,9 +2621,10 @@ class AareDAQ:
logger.exception(
"Failed to transition to RobotSampleExchange during error recovery"
)
else:
msg += f"successfully"
logger.error(f"{msg}, time taken {time.perf_counter() - start} seconds.")
msg += f" successfully"
logger.info(f"{msg}, time taken {time.perf_counter() - start} seconds.")
self.__cfg.state_busy = False
end = time.perf_counter()
return end - start