Commit 97d7523e authored by Floreal Cabanettes's avatar Floreal Cabanettes
Browse files

Fix find of errors

parent 16c08430
......@@ -352,11 +352,10 @@ class JobManager:
def find_error_in_log(log_file):
error = ""
with open(log_file, "r") as log:
lines = log.readlines()
if lines[-1].startswith("###ERR### "):
error = lines[-1][10:].rstrip()
elif lines[-2].startswith("###ERR### "):
error = lines[-2][10:].rstrip()
for line in log:
if line.startswith("###ERR### "):
error = line[10:].rstrip()
break
return error
def launch_to_cluster(self, step, batch_system_type, command, args, log_out, log_err):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment