Commit aa861eda authored by Xavier Thompson's avatar Xavier Thompson

[fix] Use requirement.key for index lookup

parent 4d36bf00
......@@ -351,7 +351,7 @@ class Installer(object):
return '\n '.join(output)
def _satisfied(self, req, source=None):
dists = [dist for dist in self._env[req.project_name] if dist in req]
dists = [dist for dist in self._env[req.key] if dist in req]
if not dists:
logger.debug('We have no distributions for %s that satisfies %r.',
req.project_name, str(req))
......@@ -509,7 +509,7 @@ class Installer(object):
if operator == '==':
# But first, avoid any network access by checking local
# urls. PackageIndex.add_find_links scans them immediately.
dists = [dist for dist in index[requirement.project_name]
dists = [dist for dist in index[requirement.key]
if dist in requirement and filter_precedence(dist) and (
FILE_SCHEME(dist.location) or
not URL_SCHEME(dist.location))]
......@@ -542,7 +542,7 @@ class Installer(object):
return None
# Filter the available dists for the requirement and source flag
dists = [dist for dist in index[requirement.project_name]
dists = [dist for dist in index[requirement.key]
if dist in requirement and filter_precedence(dist)]
# If we prefer final dists, filter for final and use the
......
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