'Search in tree for the ProcessTreeNode owning process.
Return it or None if not found.'

def find_process(self, process):

    nodes_to_search = collections.deque([self])
    while nodes_to_search:
        current_node = nodes_to_search.pop()
        if ((not current_node.is_root) and (current_node.process.pid == process.pid)):
            return current_node
        nodes_to_search.extend(current_node.children)
