Skip to content
Merged
Changes from all 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
8 changes: 8 additions & 0 deletions importlib_metadata/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,14 @@ def __getitem__(self, name: str) -> EntryPoint: # type: ignore[override]
except StopIteration:
raise KeyError(name)

def __repr__(self):
"""
Repr with classname and tuple constructor to
signal that we deviate from regular tuple behavior.
"""
return '%s(%r)' % (self.__class__.__name__, tuple(self))


def select(self, **params):
"""
Select entry points from self that match the
Expand Down