Commit d1f9a1f6 authored by Xavier Thompson's avatar Xavier Thompson

[feat] Allow installable DEVELOP_DIST in index

Allow DEVELOP_DIST distributions found on sys.path by package index
when they contain a setup.py or pyproject.toml, as a good heuristic
of whether they will be installable or not.
parent e7114cf3
......@@ -482,7 +482,8 @@ class Installer(object):
def filter_precedence(dist):
return (dist.precedence == WHL_DIST) == wheel and (
not source or dist.precedence == pkg_resources.SOURCE_DIST) and (
dist.precedence != pkg_resources.DEVELOP_DIST)
dist.precedence != pkg_resources.DEVELOP_DIST or
any(f in os.listdir(dist.location) for f in ('setup.py', 'pyproject.toml')))
index = self._index
if not networkcache_failed:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment