def get_node_lineage(node):
 lineage = [node._id]
 while node.parent_id:
  node = node.parent_node
  lineage = ([node._id] + lineage)
 return lineage

def get_node_lineage ( node ) : lineage = [ node . _id ] while node . parent_id : node = node . parent_node lineage = ( [ node . _id ] + lineage ) return lineage
get a list of node ids in order from the node to top most project e .