Better error message

This commit is contained in:
Salvo 'LtWorf' Tomaselli
2020-08-18 16:41:39 +02:00
parent aea763021c
commit 5259921bb1

View File

@@ -145,7 +145,7 @@ class Relation(NamedTuple):
if eval(c_expr, attributes): if eval(c_expr, attributes):
content.append(i) content.append(i)
except Exception as e: except Exception as e:
raise Exception(f'Failed to evaluate {expr}\n{e}') raise Exception(f'Failed to evaluate {expr} with {attributes}\n{e}')
return Relation(self.header, frozenset(content)) return Relation(self.header, frozenset(content))
def product(self, other: 'Relation') -> 'Relation': def product(self, other: 'Relation') -> 'Relation':