From: JinWang An Date: Mon, 27 Mar 2023 08:02:52 +0000 (+0900) Subject: Imported Upstream version 63.4.1 X-Git-Tag: upstream/63.4.1^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=546fd150fba930eb17f3b0de68215a5945fa6237;p=platform%2Fupstream%2Fpython-setuptools.git Imported Upstream version 63.4.1 --- diff --git a/.bumpversion.cfg b/.bumpversion.cfg index 4cb7145..f462bfa 100644 --- a/.bumpversion.cfg +++ b/.bumpversion.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 63.4.0 +current_version = 63.4.1 commit = True tag = True diff --git a/CHANGES.rst b/CHANGES.rst index 6b58d06..eca0fc0 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -1,3 +1,12 @@ +v63.4.1 +------- + + +Misc +^^^^ +* #3482: Sync with pypa/distutils@274758f1c02048d295efdbc13d2f88d9923547f8, restoring compatibility shim in bdist.format_commands. + + v63.4.0 ------- @@ -5,7 +14,6 @@ v63.4.0 Changes ^^^^^^^ * #2971: ``upload_docs`` command is deprecated once again. -* #3475: Merge with pypa/distutils@129480b, including substantial delinting and cleanup, some refactoring around compiler logic, better messaging in cygwincompiler (pypa/distutils#161). Documentation changes ^^^^^^^^^^^^^^^^^^^^^ @@ -25,11 +33,6 @@ v63.3.0 Changes ^^^^^^^ -* #3460: <<<<<<< HEAD - Limit the scope of the _distutils_hack workaround for pip. - ======= - Remove the pip workaround in _distutils_hack. - >>>>>>> 46344cf0 (Remove pip workaround in _distutils_hack.) * #3475: Merge with pypa/distutils@129480b, including substantial delinting and cleanup, some refactoring around compiler logic, better messaging in cygwincompiler (pypa/distutils#161). diff --git a/setup.cfg b/setup.cfg index 736ca91..5f6b9a5 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = setuptools -version = 63.4.0 +version = 63.4.1 author = Python Packaging Authority author_email = distutils-sig@python.org description = Easily download, build, install, upgrade, and uninstall Python packages diff --git a/setuptools/_distutils/command/bdist.py b/setuptools/_distutils/command/bdist.py index 4af1b8e..c9fdbf1 100644 --- a/setuptools/_distutils/command/bdist.py +++ b/setuptools/_distutils/command/bdist.py @@ -4,6 +4,8 @@ Implements the Distutils 'bdist' command (create a built [binary] distribution).""" import os +import warnings + from distutils.core import Command from distutils.errors import DistutilsPlatformError, DistutilsOptionError from distutils.util import get_platform @@ -20,6 +22,16 @@ def show_formats(): pretty_printer.print_help("List of available distribution formats:") +class ListCompat(dict): + # adapter to allow for Setuptools compatibility in format_commands + def append(self, item): + warnings.warn( + """format_commands is now a dict. append is deprecated.""", + DeprecationWarning, + stacklevel=2, + ) + + class bdist(Command): description = "create a built (binary) distribution" @@ -65,18 +77,23 @@ class bdist(Command): default_format = {'posix': 'gztar', 'nt': 'zip'} # Define commands in preferred order for the --help-formats option - format_commands = dict( - rpm=('bdist_rpm', "RPM distribution"), - gztar=('bdist_dumb', "gzip'ed tar file"), - bztar=('bdist_dumb', "bzip2'ed tar file"), - xztar=('bdist_dumb', "xz'ed tar file"), - ztar=('bdist_dumb', "compressed tar file"), - tar=('bdist_dumb', "tar file"), - wininst=('bdist_wininst', "Windows executable installer"), - zip=('bdist_dumb', "ZIP file"), - msi=('bdist_msi', "Microsoft Installer"), + format_commands = ListCompat( + { + 'rpm': ('bdist_rpm', "RPM distribution"), + 'gztar': ('bdist_dumb', "gzip'ed tar file"), + 'bztar': ('bdist_dumb', "bzip2'ed tar file"), + 'xztar': ('bdist_dumb', "xz'ed tar file"), + 'ztar': ('bdist_dumb', "compressed tar file"), + 'tar': ('bdist_dumb', "tar file"), + 'wininst': ('bdist_wininst', "Windows executable installer"), + 'zip': ('bdist_dumb', "ZIP file"), + 'msi': ('bdist_msi', "Microsoft Installer"), + } ) + # for compatibility until consumers only reference format_commands + format_command = format_commands + def initialize_options(self): self.bdist_base = None self.plat_name = None