get_dep_chain: add "set" node type v2.1.9.36
authorZac Medico <zmedico@gentoo.org>
Sat, 5 Feb 2011 03:20:37 +0000 (19:20 -0800)
committerZac Medico <zmedico@gentoo.org>
Sat, 5 Feb 2011 03:37:29 +0000 (19:37 -0800)
pym/_emerge/depgraph.py

index 7b74a265e910576cf3b5320e06fe2082f682c35a..d41ab825fa3d5faa73b304445c48dd4fa58e6789 100644 (file)
@@ -2213,7 +2213,11 @@ class depgraph(object):
                        traversed_nodes.add(node)
 
                        if isinstance(node, DependencyArg):
-                               dep_chain.append((_unicode_decode("%s") % (node,), "argument"))
+                               if self._dynamic_config.digraph.parent_nodes(node):
+                                       node_type = "set"
+                               else:
+                                       node_type = "argument"
+                               dep_chain.append((_unicode_decode("%s") % (node,), node_type))
 
                        elif node is not start_node:
                                for ppkg, patom in all_parents[child]:
@@ -2655,7 +2659,6 @@ class depgraph(object):
                        # It's redundant to show parent for AtomArg since
                        # it's the same as 'xinfo' displayed above.
                        dep_chain = self._get_dep_chain(myparent, atom)
-
                        for node, node_type in dep_chain:
                                msg.append('(dependency required by "%s" [%s])' % \
                                                (colorize('INFORM', _unicode_decode("%s") % \