Fix ignore_priority logic in depgraph.altlist() in order
authorZac Medico <zmedico@gentoo.org>
Fri, 2 Nov 2007 04:31:28 +0000 (04:31 -0000)
committerZac Medico <zmedico@gentoo.org>
Fri, 2 Nov 2007 04:31:28 +0000 (04:31 -0000)
to handle some cases where it was possible for nodes to
be selected without their PDEPENDs being propperly added
to the asap_nodes list.

svn path=/main/trunk/; revision=8360

pym/_emerge/__init__.py

index d477394380444bcc497ff9481568459c29be8c5d..0eb66250e2463f47ae9d1e39ec199cf6d93242b7 100644 (file)
@@ -2810,6 +2810,14 @@ class depgraph(object):
                                                if selected_nodes:
                                                        break
 
+                                       # If any nodes have been selected here, it's always
+                                       # possible that anything up to a MEDIUM_SOFT priority
+                                       # relationship has been ignored. This state is recorded
+                                       # in ignore_priority so that relevant nodes will be
+                                       # added to asap_nodes when appropriate.
+                                       if selected_nodes:
+                                               ignore_priority = DepPriority.MEDIUM_SOFT
+
                                        if prefer_asap and asap_nodes and not selected_nodes:
                                                # We failed to find any asap nodes to merge, so ignore
                                                # them for the next iteration.