Imported Upstream version 60.5.0 upstream/60.5.0
authorJinWang An <jinwang.an@samsung.com>
Mon, 27 Mar 2023 08:02:43 +0000 (17:02 +0900)
committerJinWang An <jinwang.an@samsung.com>
Mon, 27 Mar 2023 08:02:43 +0000 (17:02 +0900)
.bumpversion.cfg
CHANGES.rst
_distutils_hack/__init__.py
setup.cfg
setuptools/tests/test_distutils_adoption.py

index 57c382391f3dc42cdd6cc5e14186c0e08ece9360..542ed8459ec0a9654130811d4c81430ae89f15a7 100644 (file)
@@ -1,5 +1,5 @@
 [bumpversion]
-current_version = 60.4.0
+current_version = 60.5.0
 commit = True
 tag = True
 
index 2f3676789046c6a646838b4712239d9cef7e1177..2fee370f733848dc209cd38c35ef52cb70aab80d 100644 (file)
@@ -1,3 +1,12 @@
+v60.5.0
+-------
+
+
+Changes
+^^^^^^^
+* #2990: Set the ``.origin`` attribute of the ``distutils`` module to the module's ``__file__``.
+
+
 v60.4.0
 -------
 
index 0307734d886165bb2adb976265cc299a1ba06426..ab462f95086167b63d9fe71e118d4dc7b5f8fcc7 100644 (file)
@@ -125,7 +125,9 @@ class DistutilsMetaFinder:
             def exec_module(self, module):
                 pass
 
-        return importlib.util.spec_from_loader('distutils', DistutilsLoader())
+        return importlib.util.spec_from_loader(
+            'distutils', DistutilsLoader(), origin=mod.__file__
+        )
 
     def spec_for_pip(self):
         """
index 2095916682d12d43be73afbb68d435475bae6d8b..e91d8aed47c1ce5f8e4e28a9123c6a3c10508c69 100644 (file)
--- a/setup.cfg
+++ b/setup.cfg
@@ -1,6 +1,6 @@
 [metadata]
 name = setuptools
-version = 60.4.0
+version = 60.5.0
 author = Python Packaging Authority
 author_email = distutils-sig@python.org
 description = Easily download, build, install, upgrade, and uninstall Python packages
index 70075483688dec3e4f8cfa741aa584679cd0344f..366f2928a8d62430cded49ed83e26b1ec91cad65 100644 (file)
@@ -86,3 +86,10 @@ def test_pip_import(venv):
     """
     cmd = ['python', '-c', 'import pip']
     popen_text(venv.run)(cmd)
+
+
+def test_distutils_has_origin():
+    """
+    Distutils module spec should have an origin. #2990.
+    """
+    assert __import__('distutils').__spec__.origin