Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions snakemake_executor_plugin_slurm/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ def clean_old_logs(self) -> None:
return
cutoff_secs = age_cutoff * 86400
current_time = time.time()
self.logger.info(f"Cleaning up log files older than {age_cutoff} day(s).")
self.logger.info(f"Cleaning up SLURM log files older than {age_cutoff} day(s).")

for path in self.slurm_logdir.rglob("*.log"):
if path.is_file():
Expand Down Expand Up @@ -525,15 +525,15 @@ async def check_active_jobs(
active_jobs_seen_by_sacct.remove(j.external_jobid)
if not self.workflow.executor_settings.keep_successful_logs:
self.logger.debug(
"removing log for successful job "
"removing SLURM log for successful job "
f"with SLURM ID '{j.external_jobid}'"
)
try:
if j.aux["slurm_logfile"].exists():
j.aux["slurm_logfile"].unlink()
except (OSError, FileNotFoundError) as e:
self.logger.warning(
"Could not remove log file"
"Could not remove SLURM log file"
f" {j.aux['slurm_logfile']}: {e}"
)
elif status == "PREEMPTED" and not self._preemption_warning:
Expand Down