Skip to content

Port iter_matching_entrypoints to importlib.metadata #513

@flying-sheep

Description

@flying-sheep

When calling _version_from_entrypointsiter_matching_entrypoints, we should use importlib.metadata instead of pkg_resources, as pkg_resources isn’t the standard way to do this, and is also buggy in this context (see pypa/setuptools#2531)

The changes required would be pretty minimal:

requirements:

importlib_metadata; python_version < "3.8"

code:

try:
    from importlib.metadata import entry_points
except ImportError:
    from importlib_metadata import entry_points

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions