From 84e4c19d915a318c1d65015b1b59f429bda37b9d Mon Sep 17 00:00:00 2001
From: Jan David Mol <mol@astron.nl>
Date: Tue, 14 Jun 2022 12:00:40 +0200
Subject: [PATCH] Reraise exceptions too if we go to FAULT

---
 .../tangostationcontrol/devices/device_decorators.py          | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/tangostationcontrol/tangostationcontrol/devices/device_decorators.py b/tangostationcontrol/tangostationcontrol/devices/device_decorators.py
index b1dbb4b7a..88486177a 100644
--- a/tangostationcontrol/tangostationcontrol/devices/device_decorators.py
+++ b/tangostationcontrol/tangostationcontrol/devices/device_decorators.py
@@ -55,11 +55,9 @@ def fault_on_error():
             try:
                 return func(self, *args, **kwargs)
             except Exception as e:
-
                 logger.exception("Function failed.")
                 self.Fault(f"FAULT in {func.__name__}: {e.__class__.__name__}: {e}")
-
-                return None
+                raise
 
         return error_wrapper
 
-- 
GitLab