[issue41907] Regression in IntFlag behaviour in f-string
Ethan Furman
report at bugs.python.org
Fri Oct 2 09:56:19 EDT 2020
Ethan Furman <ethan at stoneleaf.us> added the comment:
Thank you for the bug report.
Another solution would be to subclass IntFlag and specify the `__format__` method:
from enum import IntFlag as _IntFlag
class IntFlag(_IntFlag):
def __format__(self, spec):
return format(self.value, spec)
----------
assignee: -> ethan.furman
stage: -> needs patch
versions: +Python 3.10, Python 3.9
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue41907>
_______________________________________
More information about the Python-bugs-list
mailing list