We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 5bd3c86 + bd104b0 commit a02e32bCopy full SHA for a02e32b
smartdispatch/utils.py
@@ -135,10 +135,10 @@ def detect_cluster():
135
def get_slurm_cluster_name():
136
try:
137
stdout = Popen("sacctmgr list cluster", stdout=PIPE, shell=True).communicate()[0]
138
- except OSError:
+ stdout = stdout.decode()
139
+ cluster_name = stdout.splitlines()[2].strip().split(' ')[0]
140
+ except IndexError, OSError:
141
return None
- stdout = stdout.decode()
- cluster_name = stdout.splitlines()[2].strip().split(' ')[0]
142
return cluster_name
143
144
def get_launcher(cluster_name):
0 commit comments