Merge pull request #18121 from mvdbeek/dont_report_exception_for_file_not_found

[24.0] Don't log exception if cancelled slurm job doesn't have stderr file
This commit is contained in:
Marius van den Beek
2024-05-10 16:40:01 +02:00
committed by GitHub
+3
View File
@@ -222,6 +222,9 @@ class SlurmJobRunner(DRMAAJobRunner):
return OUT_OF_MEMORY_MSG
elif any(_ in stripped_line for _ in SLURM_MEMORY_LIMIT_EXCEEDED_PARTIAL_WARNINGS):
return PROBABLY_OUT_OF_MEMORY_MSG
except FileNotFoundError:
# Entirely expected, as __check_memory_limit is only called if the job state is CANCELLED
return False
except Exception:
log.exception("Error reading end of %s:", efile_path)