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

index d5a104b05955b620e00282532ec28de6573b6285..e607b2fcc8ae0a540f3e2dbc00ea72b9ec36798a 100644 (file)
@@ -1,5 +1,5 @@
 [bumpversion]
-current_version = 60.1.0
+current_version = 60.1.1
 commit = True
 tag = True
 
index 096925441f2c2e5ce02bc938676b70980997e503..554ee73ed3e6bc235cdd2457440a9bc0549b5343 100644 (file)
@@ -1,3 +1,12 @@
+v60.1.1
+-------
+
+
+Misc
+^^^^
+* #2980: Bypass distutils loader when setuptools module is no longer available on sys.path.
+
+
 v60.1.0
 -------
 
index fab411188696b99bff4e87fbfc7afecf32ccd6b1..7ea2b70ebec82614d10b32c038ea1e8f2ec41ce8 100644 (file)
 .. image:: https://tidelift.com/badges/github/pypa/setuptools?style=flat
    :target: https://tidelift.com/subscription/pkg/pypi-setuptools?utm_source=pypi-setuptools&utm_medium=readme
 
+.. image:: https://img.shields.io/discord/803025117553754132
+   :target: https://discord.com/channels/803025117553754132/815945031150993468
+   :alt: Discord
+
 See the `Installation Instructions
 <https://packaging.python.org/installing/>`_ in the Python Packaging
 User's Guide for instructions on installing, upgrading, and uninstalling
index 85a51370b6ac747798f3c213181d568f278bc728..55ea082565390a65a728d9f268cdb086b08c5667 100644 (file)
@@ -86,6 +86,13 @@ class DistutilsMetaFinder:
         import importlib.abc
         import importlib.util
 
+        # In cases of path manipulation during sitecustomize,
+        # Setuptools might actually not be present even though
+        # the hook has been loaded. Allow the caller to fall
+        # back to stdlib behavior. See #2980.
+        if not importlib.util.find_spec('setuptools'):
+            return
+
         class DistutilsLoader(importlib.abc.Loader):
 
             def create_module(self, spec):
index 98e34c19a8587474f3bc86f06c071421aeeb8261..da904babcad8a1b80f305cfc302df90b6309607a 100644 (file)
@@ -14,9 +14,9 @@ Python packaging at a glance
 ============================
 The landscape of Python packaging is shifting and ``Setuptools`` has evolved to
 only provide backend support, no longer being the de-facto packaging tool in
-the market. All python package must provide a ``pyproject.toml`` and specify
+the market. Every python package must provide a ``pyproject.toml`` and specify
 the backend (build system) it wants to use. The distribution can then
-be generated with whatever tools that provides a ``build sdist``-alike
+be generated with whatever tool that provides a ``build sdist``-like
 functionality. While this may appear cumbersome, given the added pieces,
 it in fact tremendously enhances the portability of your package. The
 change is driven under :pep:`PEP 517 <517#build-requirements>`. To learn more about Python packaging in general,
@@ -76,7 +76,7 @@ This is what your project would look like::
         setup.cfg # or setup.py
         mypackage/__init__.py
 
-Then, you need an builder, such as :std:doc:`PyPA build <pypa-build:index>`
+Then, you need a builder, such as :std:doc:`PyPA build <pypa-build:index>`
 which you can obtain via ``pip install build``. After downloading it, invoke
 the builder::
 
@@ -89,15 +89,15 @@ Of course, before you release your project to PyPI, you'll want to add a bit
 more information to your setup script to help people find or learn about your
 project.  And maybe your project will have grown by then to include a few
 dependencies, and perhaps some data files and scripts. In the next few sections,
-we will walk through those additional but essential information you need
+we will walk through the additional but essential information you need
 to specify to properly package your project.
 
 
 Automatic package discovery
 ===========================
 For simple projects, it's usually easy enough to manually add packages to
-the ``packages`` keyword in ``setup.cfg``.  However, for very large projects
-it can be a big burden to keep the package list updated. ``setuptools``
+the ``packages`` keyword in ``setup.cfg``.  However, for very large projects
+it can be a big burden to keep the package list updated. ``setuptools``
 therefore provides two convenient tools to ease the burden: :literal:`find:\ ` and
 :literal:`find_namespace:\ `. To use it in your project:
 
@@ -110,11 +110,11 @@ therefore provides two convenient tools to ease the burden: :literal:`find:\ ` a
     include=pkg1, pkg2
     exclude=pk3, pk4
 
-When you pass the above information, alongside other necessary ones,
+When you pass the above information, alongside other necessary information,
 ``setuptools`` walks through the directory specified in ``where`` (omitted
-here as the package reside in current directory) and filters the packages
-it can find following the ``include``  (default to none), then remove
-those that match the ``exclude`` and return a list of Python packages. Note
+here as the package resides in the current directory) and filters the packages
+it can find following the ``include``  (defaults to none), then removes
+those that match the ``exclude`` and returns a list of Python packages. Note
 that each entry in the ``[options.packages.find]`` is optional. The above
 setup also allows you to adopt a ``src/`` layout. For more details and advanced
 use, go to :ref:`package_discovery`
@@ -122,7 +122,7 @@ use, go to :ref:`package_discovery`
 
 Entry points and automatic script creation
 ===========================================
-Setuptools support automatic creation of scripts upon installation, that runs
+Setuptools supports automatic creation of scripts upon installation, that runs
 code within your package if you specify them with the ``entry_points`` keyword.
 This is what allows you to run commands like ``pip install`` instead of having
 to type ``python -m pip install``. To accomplish this, add the entry_points
@@ -157,7 +157,7 @@ operators <, >, <=, >=, == or !=, followed by a version identifier):
 
 When your project is installed, all of the dependencies not already installed
 will be located (via PyPI), downloaded, built (if necessary), and installed.
-This, of course, is a simplified scenarios. ``setuptools`` also provide
+This, of course, is a simplified scenarios. ``setuptools`` also provides
 additional keywords such as ``setup_requires`` that allows you to install
 dependencies before running the script, and ``extras_require`` that take
 care of those needed by automatically generated scripts. It also provides
@@ -207,7 +207,7 @@ associate with your source code. For more information, see :doc:`development_mod
 
 Uploading your package to PyPI
 ==============================
-After generating the distribution files, next step would be to upload your
+After generating the distribution files, the next step would be to upload your
 distribution so others can use it. This functionality is provided by
 `twine <https://pypi.org/project/twine/>`_ and we will only demonstrate the
 basic use here.
index 3daca1df8d7afd852bfd4b9dbb2a5e6c0259f036..23c7d1ea840070bd73e7851313fe6f655772dc57 100644 (file)
--- a/setup.cfg
+++ b/setup.cfg
@@ -1,6 +1,6 @@
 [metadata]
 name = setuptools
-version = 60.1.0
+version = 60.1.1
 author = Python Packaging Authority
 author_email = distutils-sig@python.org
 description = Easily download, build, install, upgrade, and uninstall Python packages
index 00f5f1859e127101bf6971ad2e876b4ffc4175be..61d239aa750e05d16f35d7cfe5ee2b25ca7cee3d 100644 (file)
@@ -82,7 +82,7 @@ def _get_pip_versions():
         'pip<22',
         mark(
             'https://github.com/pypa/pip/archive/main.zip',
-            pytest.mark.skipif('sys.version_info < (3, 7)'),
+            pytest.mark.xfail(reason='#2975'),
         ),
     ]