Task: implement __repr__
authorZac Medico <zmedico@gentoo.org>
Tue, 19 Mar 2013 18:36:44 +0000 (11:36 -0700)
committerZac Medico <zmedico@gentoo.org>
Tue, 19 Mar 2013 18:36:44 +0000 (11:36 -0700)
pym/_emerge/Task.py

index 40f5066c011d5a8788815ee73af46130dfdb956b..769884bcf5a25177e69db01aeb406c7067ebffc3 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 1999-2012 Gentoo Foundation
+# Copyright 1999-2013 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 from portage.util.SlotObject import SlotObject
@@ -41,3 +41,7 @@ class Task(SlotObject):
                strings.
                """
                return "(%s)" % ", ".join(("'%s'" % x for x in self._hash_key))
+
+       def __repr__(self):
+               return "<%s (%s)>" % (self.__class__.__name__,
+                       ", ".join(("'%s'" % x for x in self._hash_key)))