[issue18738] String formatting (% and str.format) issues with Enum

Serhiy Storchaka report at bugs.python.org
Wed Aug 21 13:37:37 CEST 2013


Serhiy Storchaka added the comment:

>> print(member)
>> "%s" % member
>> "{}".format(member)
>
> Would you seriously use either of those last two in either the debugger 
or the command line?

Yes, of course. When you need debug output from function or loop inners.

    for ...:
        ...
        print('stage1(%s) = [%s:%s] %s' % (i, start, stop, result))

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue18738>
_______________________________________


More information about the Python-bugs-list mailing list