From 6c8b60cf3438f84e9a517f4ed5f3cbb56a3a2b16 Mon Sep 17 00:00:00 2001 From: Salvo 'LtWorf' Tomaselli Date: Wed, 9 Sep 2015 17:28:12 +0200 Subject: [PATCH] Improve error handling Provide a better error in case of operator missing --- relational/parser.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/relational/parser.py b/relational/parser.py index 30add2b..4fdc065 100644 --- a/relational/parser.py +++ b/relational/parser.py @@ -165,7 +165,7 @@ class Node (object): self.child = node(expression[2 + i]) return - raise ParserException(u"Unable to parse tokens") + raise ParserException("Expected operator in '%s'" % ' '.join(expression)) pass def toCode(self):