diff --git a/beat/backend/python/algorithm.py b/beat/backend/python/algorithm.py index fa63584ad3b5e399c0c431232080d6a46d888bad..a32285325e25d2f7869c7f71c869b53261904d9a 100644 --- a/beat/backend/python/algorithm.py +++ b/beat/backend/python/algorithm.py @@ -287,7 +287,13 @@ class Runner(object): if not self.prepared: raise exc("Algorithm '%s' is not yet prepared" % self.name) - return loader.run(self.obj, 'validate', self.exc, result) + + answer = loader.run(self.obj, 'validate', self.exc, result) + + if not isinstance(answer, tuple): + raise exc("Improper implementation: validate must return a tuple") + + return answer def __getattr__(self, key):