Find distributions. Return an iterable of all Distribution instances capable of loading the metadata for packages matching ``context.name`` (or all names if ``None`` indicated) along the paths in the list of directories ``context.path``.
(
cls, context=DistributionFinder.Context()
)
| 983 | class MetadataPathFinder(DistributionFinder): |
| 984 | @classmethod |
| 985 | def find_distributions( |
| 986 | cls, context=DistributionFinder.Context() |
| 987 | ) -> Iterable[PathDistribution]: |
| 988 | """ |
| 989 | Find distributions. |
| 990 | |
| 991 | Return an iterable of all Distribution instances capable of |
| 992 | loading the metadata for packages matching ``context.name`` |
| 993 | (or all names if ``None`` indicated) along the paths in the list |
| 994 | of directories ``context.path``. |
| 995 | """ |
| 996 | found = cls._search_paths(context.name, context.path) |
| 997 | return map(PathDistribution, found) |
| 998 | |
| 999 | @classmethod |
| 1000 | def _search_paths(cls, name, paths): |
nothing calls this directly
no test coverage detected