lst_auto_rta.utils.slurm.parse_nodes_in_scontrol_show_res_output

lst_auto_rta.utils.slurm.parse_nodes_in_scontrol_show_res_output(scontrol_output: str) List[str][source]

Parse a string containing scontrol show res output to find nodes names.

Search for the substring “Nodes” then parses the nodes ID string, and then the nodes numerical ID, which can be a number, list of number, a list of ranges, or a list of the combination of all of that. Examples of strings: …Nodes=cp[12,34-47] …

…Nodes=tcs12 … …Nodes=lsfj[32-36]

Raises:

ValueError – If the node’s names could not be parsed from the string

Returns:

List of node names in the reservations

Return type:

List[str]