Skip to content
This repository has been archived by the owner on May 14, 2024. It is now read-only.

Commit

Permalink
getting the lock state should look for billing as well
Browse files Browse the repository at this point in the history
  • Loading branch information
Comeani committed Feb 28, 2024
1 parent a016f80 commit e3dae8c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bank/system/slurm.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ def get_locked_state(self, cluster: str) -> bool:
raise ClusterNotFoundError(f'Cluster {cluster} is not configured with Slurm')

cmd = f'sacctmgr -n -P show assoc account={self.account_name} format=GrpTresRunMins clusters={cluster}'
return 'cpu=0' in ShellCmd(cmd).out
return 'billing=0' in ShellCmd(cmd).out

def set_locked_state(self, lock_state: bool, cluster: str) -> None:
"""Lock or unlock the current slurm account
Expand Down

0 comments on commit e3dae8c

Please sign in to comment.