mypy does not detect this as a problem because EnumMeta has a `.__len__` method https://github.com/python/typeshed/blob/60939b00afede13feeec3cee6f6dfe6eb2df1593/stdlib/enum.pyi#L121
what would the type hints look like if len(Enum) failed but class Foo(Enum): pass len(Foo) succeeds? _______________________________________________ Python-ideas mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/[email protected]/message/RTAF57ZHKB2B75T3OJ73WBNT6JRUQF44/ Code of Conduct: http://python.org/psf/codeofconduct/
