Skip to content

Commit e99609f

Browse files
committed
Now the code seems to work properly even for the effective charges
1 parent a366570 commit e99609f

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

Modules/Cluster.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -326,8 +326,12 @@ def ExecuteCMD(self, cmd, raise_error = True, return_output = False, on_cluster
326326
if not isinstance(output, str):
327327
try:
328328
output = str(output.decode("utf-8"))
329-
except:
330-
pass
329+
except Exception as e:
330+
sys.stderr.write("Error in the following command:\n")
331+
sys.stderr.write(e)
332+
sys.stderr.write("\n")
333+
sys.stderr.flush()
334+
331335
output = output.strip()
332336
status = p.wait()
333337
if not err is None:
@@ -766,6 +770,8 @@ def batch_submission(self, list_of_structures, calc, indices,
766770
except Exception as e:
767771
sys.stderr.write("JOB {} | {} resulted in error:\n".format(i, lbl))
768772
sys.stderr.write(e)
773+
sys.stderr.write("\n")
774+
sys.stderr.flush()
769775

770776

771777
return results

0 commit comments

Comments
 (0)