[sources] include source's class in its repr stable
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Mon, 13 Feb 2012 15:15:24 +0100
branchstable
changeset 8228 fe53c7e1625f
parent 8227 884405bf3621
child 8232 8c29253105ba
[sources] include source's class in its repr
server/sources/__init__.py
--- a/server/sources/__init__.py	Mon Feb 13 12:49:49 2012 +0100
+++ b/server/sources/__init__.py	Mon Feb 13 15:15:24 2012 +0100
@@ -135,7 +135,8 @@
         source_config.pop('type')
 
     def __repr__(self):
-        return '<%s source %s @%#x>' % (self.uri, self.eid, id(self))
+        return '<%s %s source %s @%#x>' % (self.uri, self.__class__.__name__,
+                                           self.eid, id(self))
 
     def __cmp__(self, other):
         """simple comparison function to get predictable source order, with the