Browse Source

Hopefully, fix LaterGuage error handling

Richard van der Hoff 6 years ago
parent
commit
694968fa81
1 changed files with 6 additions and 3 deletions
  1. 6 3
      synapse/metrics/__init__.py

+ 6 - 3
synapse/metrics/__init__.py

@@ -60,10 +60,13 @@ class LaterGauge(object):
 
         try:
             calls = self.caller()
-        except Exception as e:
-            print(e)
-            logger.err()
+        except Exception:
+            logger.exception(
+                "Exception running callback for LaterGuage(%s)",
+                self.name,
+            )
             yield g
+            return
 
         if isinstance(calls, dict):
             for k, v in calls.items():