add_pkg_dep_string: respect traverse_ignored_deps
authorZac Medico <zmedico@gentoo.org>
Wed, 4 May 2011 17:20:58 +0000 (10:20 -0700)
committerZac Medico <zmedico@gentoo.org>
Wed, 4 May 2011 17:20:58 +0000 (10:20 -0700)
I don't think this makes any difference now, but it clarifies how
traverse_ignored_deps should behave.

pym/_emerge/depgraph.py

index ebfbdd498a921f604f79ad28d7036ff4559daea0..9dcc5b96bf928dcb2bee000579debd8e0a3892fb 100644 (file)
@@ -1543,7 +1543,8 @@ class depgraph(object):
                                        self._dynamic_config._ignored_deps.append(dep)
 
                        if not ignored:
-                               if dep_priority.ignored:
+                               if dep_priority.ignored and \
+                                       not self._dynamic_config._traverse_ignored_deps:
                                        if is_virt and dep.child is not None:
                                                traversed_virt_pkgs.add(dep.child)
                                        dep.child = None
@@ -1573,7 +1574,8 @@ class depgraph(object):
                                        (virt_pkg.cpv, [str(x) for x in atoms]),
                                        noiselevel=-1, level=logging.DEBUG)
 
-                       if not dep_priority.ignored:
+                       if not dep_priority.ignored or \
+                               self._dynamic_config._traverse_ignored_deps:
                                if not self._add_pkg(virt_pkg, virt_dep):
                                        return 0
 
@@ -1635,7 +1637,8 @@ class depgraph(object):
                                                self._dynamic_config._ignored_deps.append(dep)
 
                                if not ignored:
-                                       if dep_priority.ignored:
+                                       if dep_priority.ignored and \
+                                               not self._dynamic_config._traverse_ignored_deps:
                                                if is_virt and dep.child is not None:
                                                        traversed_virt_pkgs.add(dep.child)
                                                dep.child = None