1
1
Fork 0
mirror of https://github.com/pypa/pip synced 2023-12-13 21:30:23 +01:00

Revert "Drop code for nicer diffs later"

This reverts commit f927f9ae39.
This commit is contained in:
Pradyun Gedam 2020-04-24 19:57:58 +05:30
parent 746f47cc3a
commit e6853336fe
No known key found for this signature in database
GPG key ID: DA17C4B29CB32E4B

View file

@ -129,6 +129,13 @@ class Resolver(BaseResolver):
graph = self._result.graph
weights = get_topological_weights(graph)
sorted_items = sorted(
req_set.requirements.items(),
key=functools.partial(_req_set_item_sorter, weights=weights),
reverse=True,
)
return [ireq for _, ireq in sorted_items]
def get_topological_weights(graph):
# type: (Graph) -> Dict[str, int]