From: Zac Medico Date: Tue, 19 Mar 2013 18:36:44 +0000 (-0700) Subject: Task: implement __repr__ X-Git-Tag: v2.2.0_alpha167~8 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=38358b20857bb048ad6ba2fce514df3319a2f349;p=portage.git Task: implement __repr__ --- diff --git a/pym/_emerge/Task.py b/pym/_emerge/Task.py index 40f5066c0..769884bcf 100644 --- a/pym/_emerge/Task.py +++ b/pym/_emerge/Task.py @@ -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)))