def GetWantedNodes(lu, short_node_names):
  if short_node_names:
    node_uuids = [ExpandNodeUuidAndName(lu.cfg, None, name)[0]
                  for name in short_node_names]
  else:
    node_uuids = lu.cfg.GetNodeList()

  return (node_uuids, [lu.cfg.GetNodeName(uuid) for uuid in node_uuids])
Returns list of checked and expanded node names.
dataset/ETHPy150Open ganeti/ganeti/lib/cmdlib/common.py/GetWantedNodes