[Python-checkins] bpo-31947: remove None default for names param in Enum._create_ GH-4288 (GH-6485)

Ethan Furman webhook-mailer at python.org
Tue May 15 11:19:54 EDT 2018


https://github.com/python/cpython/commit/c50e5b1f1f2501f697aa52d9c9a440bdeced7006
commit: c50e5b1f1f2501f697aa52d9c9a440bdeced7006
branch: 3.6
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: Ethan Furman <ethan at stoneleaf.us>
date: 2018-05-15T08:19:50-07:00
summary:

bpo-31947: remove None default for names param in Enum._create_ GH-4288 (GH-6485)

(cherry picked from commit b8e21f12891382bc0aac5ccd13dcb4a990d65e0a)

Co-authored-by: anentropic <ego at anentropic.com>

files:
M Lib/enum.py

diff --git a/Lib/enum.py b/Lib/enum.py
index 73dd613887d2..112523e998f7 100644
--- a/Lib/enum.py
+++ b/Lib/enum.py
@@ -361,7 +361,7 @@ def __setattr__(cls, name, value):
             raise AttributeError('Cannot reassign members.')
         super().__setattr__(name, value)
 
-    def _create_(cls, class_name, names=None, *, module=None, qualname=None, type=None, start=1):
+    def _create_(cls, class_name, names, *, module=None, qualname=None, type=None, start=1):
         """Convenience method to create a new Enum class.
 
         `names` can be:



More information about the Python-checkins mailing list