slurm.ParsedDrainReason
A parsed drain reason object containing tags and cleaned reason.
Members
get_tags
slurm.ParsedDrainReason.get_tags()Get a list of all tag names present in the drain reason
Returns
tagslist[string]List of all tag nameshas_all_tags
slurm.ParsedDrainReason.has_all_tags(tags)Check if all of the specified tags are present in the drain reason
Parameters
tagslist[string]List of tag names to check forReturns
presentboolTrue if all of the tags are present, false otherwisehas_any_tag
slurm.ParsedDrainReason.has_any_tag(tags)Check if any of the specified tags are present in the drain reason
Parameters
tagslist[string]List of tag names to check forReturns
presentboolTrue if any of the tags are present, false otherwisehas_only_tags_from
slurm.ParsedDrainReason.has_only_tags_from(allowed_tags)Check if all tags present in the drain reason are in the allowed list. Returns true if there are no tags.
Parameters
allowed_tagslist[string]List of allowed tag namesReturns
validboolTrue if all present tags are in the allowed list, false otherwisehas_tag
slurm.ParsedDrainReason.has_tag(tag)Check if a specific tag is present in the drain reason
Parameters
tagstringThe tag name to check forReturns
presentboolTrue if the tag is present, false otherwise