Make name and value read-only for Enums (#6576)

This commit is contained in:
Alex Waygood
2021-12-13 15:08:49 +00:00
committed by GitHub
parent c3cd88ba91
commit 0f2e87e42a
2 changed files with 12 additions and 2 deletions

View File

@@ -83,6 +83,8 @@ distutils.command.bdist_packager # It exists in docs as package name but not in
distutils.version.Version._cmp # class should have declared this
distutils.version.Version.parse # class should have declared this
email.headerregistry.BaseHeader.max_count # docs say subclasses should have this property
enum.Enum.name # A special property that exists at runtime, but stubtest can't detect https://github.com/python/typeshed/pull/6576#issuecomment-992538677
enum.Enum.value # A special property that exists at runtime, but stubtest can't detect https://github.com/python/typeshed/pull/6576#issuecomment-992538677
http.HTTPStatus.description # set in __new__
http.HTTPStatus.phrase # set in __new__
http.client.HTTPConnection.response_class # the actual type at runtime is abc.ABCMeta