pypa / setuptools

Official project repository for the Setuptools build system
https://pypi.org/project/setuptools/
MIT License
2.34k stars 1.14k forks source link

Using `setuptools.extern.importlib_metadata.EntryPoints.names` is incompatible with older versions of `importlib_metadata` and/or `importlib.metadata` #4338

Closed abravalheri closed 2 weeks ago

abravalheri commented 2 weeks ago

importlib_metadata.EntryPoints.names was introduced in 3.6.0 and it is currently being used in https://github.com/pypa/setuptools/blob/963dbd25cb64898b6f3ee247440db0421f16ca18/setuptools/dist.py#L538

This potentially cause problems when MetaPathFinders in Python 3.8 that use importlib.metadata APIs to implement find_distributions.

This problem was identified in https://github.com/pypa/pyproject-hooks/pull/195#issuecomment-2088695300.