Commit ea335b56 by Randy Döring Committed by Bjorn Neergaard

perf(solver): reduce the number of overrides by avoiding adding dummy…

perf(solver): reduce the number of overrides by avoiding adding dummy dependencies if the project's python constraint does not allow any version compatible with the marker of the dependency
parent 02dbe014
......@@ -631,7 +631,9 @@ class Provider:
dep_other.set_constraint(
dep_other.constraint.intersect(dep_any.constraint)
)
elif not inverted_marker.is_empty():
elif not inverted_marker.is_empty() and self._python_constraint.allows_any(
get_python_constraint_from_marker(inverted_marker)
):
# if there is no any marker dependency
# and the inverted marker is not empty,
# a dependency with the inverted union of all markers is required
......
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