This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ethan.furman
Recipients barry, eli.bendersky, ethan.furman, serhiy.storchaka, terry.reedy
Date 2020-09-19.19:20:58
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Due to the nature of `str`, if an Enum tries to mixin the str type, all of it's members will be strings -- even if they didn't start out that way:

  class MyStrEnum(str, Enum):
     tuple = 'oops',
     okay = 'correct'

  >>> list(MyStrEnum)
  [<MyStrEnum.tuple: "('oops',)">, MyStrEnum.okay: 'correct'>]

The StrEnum class will have a check to ensure that each value was already a string, or can be converted to a string via

  str(bytes, encoding, errors)
Date User Action Args
2020-09-19 19:20:58ethan.furmansetrecipients: + ethan.furman, barry, terry.reedy, eli.bendersky, serhiy.storchaka
2020-09-19 19:20:58ethan.furmansetmessageid: <>
2020-09-19 19:20:58ethan.furmanlinkissue41816 messages
2020-09-19 19:20:58ethan.furmancreate