schema.py
changeset 10797 b4f8c0b98c29
parent 10791 22611236983d
child 10813 ab626726a70a
--- a/schema.py	Fri Oct 16 16:44:36 2015 +0200
+++ b/schema.py	Thu Oct 08 13:45:00 2015 +0200
@@ -1207,11 +1207,11 @@
         return ';%s;%s\n%s' % (','.join(sorted(self.mainvars)), self.expression,
                                self.msg or '')
 
+    @classmethod
     def deserialize(cls, value):
         value, msg = value.split('\n', 1)
         _, mainvars, expression = value.split(';', 2)
         return cls(expression, mainvars, msg)
-    deserialize = classmethod(deserialize)
 
     def repo_check(self, session, eidfrom, rtype, eidto=None):
         """raise ValidationError if the relation doesn't satisfy the constraint