expand_new_virt: don't traverse blockers
authorZac Medico <zmedico@gentoo.org>
Wed, 27 Apr 2011 16:13:51 +0000 (09:13 -0700)
committerZac Medico <zmedico@gentoo.org>
Wed, 4 May 2011 19:27:40 +0000 (12:27 -0700)
pym/_emerge/actions.py

index 68b82825608133f77a1714fc0df5e31b89520f58..1c68298165713d0792bf67cdd2a28b345bf97653 100644 (file)
@@ -1295,11 +1295,17 @@ def expand_new_virt(vardb, atom):
        or it does not match an installed package then it is
        yielded without any expansion.
        """
+       if not isinstance(atom, Atom):
+               atom = Atom(atom)
        traversed = set()
        stack = [atom]
 
        while stack:
                atom = stack.pop()
+               if atom.blocker:
+                       yield atom
+                       continue
+
                matches = vardb.match(atom)
                if not (matches and matches[-1].startswith("virtual/")):
                        yield atom