--- a/appobject.py Thu Jan 20 13:16:30 2011 +0100
+++ b/appobject.py Fri Jan 21 12:51:58 2011 +0100
@@ -214,6 +214,9 @@
return NotImplementedError("selector %s must implement its logic "
"in its __call__ method" % self.__class__)
+ def __repr__(self):
+ return u'<Selector %s at %x>' % (self.__class__.__name__, id(self))
+
class MultiSelector(Selector):
"""base class for compound selector classes"""
--- a/selectors.py Thu Jan 20 13:16:30 2011 +0100
+++ b/selectors.py Fri Jan 21 12:51:58 2011 +0100
@@ -1156,8 +1156,8 @@
rql = 'Any COUNT(X) WHERE X eid %%(x)s, %s' % expression
self.rql = rql
- def __repr__(self):
- return u'<rql_condition "%s" at %x>' % (self.rql, id(self))
+ def __str__(self):
+ return '%s(%r)' % (self.__class__.__name__, self.rql)
def score(self, req, rset, row, col):
try: