Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions importlib_metadata/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
from ._itertools import always_iterable, bucket, unique_everseen
from ._meta import PackageMetadata, SimplePath
from ._typing import md_none
from .compat import py39, py311
from .compat import py311

__all__ = [
'Distribution',
Expand Down Expand Up @@ -340,7 +340,7 @@ def select(self, **params) -> EntryPoints:
Select entry points from self that match the
given parameters (typically group and/or name).
"""
return EntryPoints(ep for ep in self if py39.ep_matches(ep, **params))
return EntryPoints(ep for ep in self if ep.matches(**params))

@property
def names(self) -> set[str]:
Expand Down Expand Up @@ -1088,7 +1088,7 @@ def version(distribution_name: str) -> str:

_unique = functools.partial(
unique_everseen,
key=py39.normalized_name,
key=operator.attrgetter('_normalized_name'),
)
"""
Wrapper for ``distributions`` to return unique distributions by name.
Expand Down
42 changes: 0 additions & 42 deletions importlib_metadata/compat/py39.py

This file was deleted.

2 changes: 1 addition & 1 deletion tests/compat/py312.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import contextlib

from .py39 import import_helper
from test.support import import_helper


@contextlib.contextmanager
Expand Down
8 changes: 0 additions & 8 deletions tests/compat/py39.py

This file was deleted.

74 changes: 0 additions & 74 deletions tests/compat/test_py39_compat.py

This file was deleted.

7 changes: 6 additions & 1 deletion tests/fixtures.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,16 @@
import textwrap
from importlib import resources

from jaraco.test.cpython import from_test_support, try_import

from . import _path
from ._path import FilesSpec
from .compat.py39 import os_helper
from .compat.py312 import import_helper

os_helper = try_import('os_helper') or from_test_support(
'FS_NONASCII', 'skip_unless_symlink', 'temp_dir'
)

Comment thread
jaraco marked this conversation as resolved.
Outdated

@contextlib.contextmanager
def tmp_path():
Expand Down
2 changes: 1 addition & 1 deletion tests/test_main.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

from . import fixtures
from ._path import Symlink
from .compat.py39 import os_helper
from .fixtures import os_helper
Comment thread
jaraco marked this conversation as resolved.
Outdated


class BasicTests(fixtures.DistInfoPkg, unittest.TestCase):
Expand Down
Loading