]> granicus.if.org Git - python/commitdiff
bpo-34282: Remove deprecated enum _convert method (GH-13823)
authorZachary Ware <zach@python.org>
Tue, 4 Jun 2019 21:03:10 +0000 (16:03 -0500)
committerVictor Stinner <vstinner@redhat.com>
Tue, 4 Jun 2019 21:03:10 +0000 (23:03 +0200)
Lib/enum.py
Misc/NEWS.d/next/Library/2019-06-04-15-39-14.bpo-34282.aAK54n.rst [new file with mode: 0644]

index 6ef17c7f6dc8466eb8de21a5ac7142eef7a9619a..403f747d22a4ea04605506151f1d5560a97d0aee 100644 (file)
@@ -464,12 +464,6 @@ class EnumMeta(type):
         module_globals[name] = cls
         return cls
 
-    def _convert(cls, *args, **kwargs):
-        import warnings
-        warnings.warn("_convert is deprecated and will be removed in 3.9, use "
-                      "_convert_ instead.", DeprecationWarning, stacklevel=2)
-        return cls._convert_(*args, **kwargs)
-
     @staticmethod
     def _get_mixins_(bases):
         """Returns the type for creating enum members, and the first inherited
diff --git a/Misc/NEWS.d/next/Library/2019-06-04-15-39-14.bpo-34282.aAK54n.rst b/Misc/NEWS.d/next/Library/2019-06-04-15-39-14.bpo-34282.aAK54n.rst
new file mode 100644 (file)
index 0000000..66c388e
--- /dev/null
@@ -0,0 +1 @@
+Remove ``Enum._convert`` method, deprecated in 3.8.