Skip to content

auto_queues failed if TRES=(null) for partition #864

@xpillons

Description

@xpillons

The parsing of TRES consider that the value cannot be null.

hsh[:tres] = hsh[:TRES].nil? ? {} : hsh[:TRES].to_s.split(',').map { |str| str.split('=') }.to_h

We have clusters with dynamic partitions being configured which end into having TRES=(null) when no nodes are present

PartitionName=dynamic AllowGroups=ALL AllowAccounts=ALL AllowQos=ALL AllocNodes=ALL Default=NO QoS=N/A DefaultTime=NONE DisableRootJobs=NO ExclusiveUser=NO ExclusiveTopo=NO GraceTime=0 Hidden=NO MaxNodes=UNLIMITED MaxTime=UNLIMITED MinNodes=0 LLN=NO MaxCPUsPerNode=UNLIMITED MaxCPUsPerSocket=UNLIMITED NodeSets=dynamicns Nodes=(null) PriorityJobFactor=1 PriorityTier=1 RootOnly=NO ReqResv=NO OverSubscribe=NO OverTimeLimit=NONE PreemptMode=OFF State=UP TotalCPUs=0 TotalNodes=0 SelectTypeParameters=NONE JobDefaults=(null) DefMemPerNode=UNLIMITED MaxMemPerNode=UNLIMITED TRES=(null) ResumeTimeout=GLOBAL SuspendTimeout=GLOBAL SuspendTime=GLOBAL PowerDownOnIdle=NO

App 18237 output: [2025-01-29 08:55:38 +0000 ]  WARN "Did not get queues from system with error wrong array length at 0 (expected 2, was 1)"
App 18237 output: [2025-01-29 08:55:38 +0000 ]  WARN "/opt/ood/gems/gems/ood_core-0.27.0/lib/ood_core/job/adapters/slurm.rb:377:in `to_h'\n/opt/ood/gems/gems/ood_core-0.27.0/lib/ood_core/job/adapters/slurm.rb:377:in `str_to_queue_info'\n/opt/ood/gems/gems/ood_core-0.27.0/lib/ood_core/job/adapters/slurm.rb:331:in `block (2 levels) in queues'\n/opt/ood/gems/gems/ood_core-0.27.0/lib/ood_core/job/adapters/slurm.rb:330:in `each_line'\n/opt/ood/gems/gems/ood_core-0.27.0/lib/ood_core/job/adapters/slurm.rb:330:in `block in queues'\n<internal:kernel>:90:in `tap'\n/opt/ood/gems/gems/ood_core-0.27.0/lib/ood_core/job/adapters/slurm.rb:329:in `queues'\n/opt/ood/gems/gems/ood_core-0.27.0/lib/ood_core/job/adapters/slurm.rb:696:in `queues'\n/var/www/ood/apps/sys/dashboard/app/lib/account_cache.rb:152:in `block (3 levels) in queues_per_cluster'\n/opt/ood/gems/gems/ood_core-0.27.0/lib/ood_core/clu

It would be great to consider that case and filter our these partitions from the list

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions