'Return names of dependencies that self an other have in common.'

def common_dependencies(self, other):

    common = set((s.name for s in self.traverse(root=False)))
    common.intersection_update((s.name for s in other.traverse(root=False)))
    return common
