diff options
author | Jason R. Coombs <jaraco@jaraco.com> | 2021-04-25 18:05:55 -0400 |
---|---|---|
committer | Jason R. Coombs <jaraco@jaraco.com> | 2021-04-25 18:05:55 -0400 |
commit | b720937d0af9e8382c8b9e00b2c0d5715b7cfbe5 (patch) | |
tree | c29ce9e7423c4f89e79634991941e5bdf9d07a15 /docs/pkg_resources.rst | |
parent | 8b494633df0f6770946092498aed76fd30be99b1 (diff) | |
parent | b5fa6ad11e1344648b470ff0d847a7d940b4c99d (diff) | |
download | python-setuptools-git-feature/distutils-docs.tar.gz |
Merge branch 'main' into feature/distutils-docsfeature/distutils-docs
Diffstat (limited to 'docs/pkg_resources.rst')
-rw-r--r-- | docs/pkg_resources.rst | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/docs/pkg_resources.rst b/docs/pkg_resources.rst index 364e2183..994bea6f 100644 --- a/docs/pkg_resources.rst +++ b/docs/pkg_resources.rst @@ -10,6 +10,13 @@ eggs, support for merging packages that have separately-distributed modules or subpackages, and APIs for managing Python's current "working set" of active packages. +Use of ``pkg_resources`` is discouraged in favor of +`importlib.resources <https://docs.python.org/3/library/importlib.html#module-importlib.resources>`_, +`importlib.metadata <https://docs.python.org/3/library/importlib.metadata.html>`_, +and their backports (`resources <https://pypi.org/project/importlib_resources>`_, +`metadata <https://pypi.org/project/importlib_metadata>`_). +Please consider using those libraries instead of pkg_resources. + .. contents:: **Table of Contents** @@ -703,7 +710,7 @@ entry point group and look for entry points named "pre_process" and To advertise an entry point, a project needs to use ``setuptools`` and provide an ``entry_points`` argument to ``setup()`` in its setup script, so that the entry points will be included in the distribution's metadata. For more -details, see the [``setuptools`` documentation](https://setuptools.readthedocs.io/en/latest/setuptools.html#dynamic-discovery-of-services-and-plugins). +details, see :ref:`Advertising Behavior<dynamic discovery of services and plugins>`. Each project distribution can advertise at most one entry point of a given name within the same entry point group. For example, a distutils extension @@ -1939,4 +1946,3 @@ History 0.3a1 * Initial release. - |