Skip to content

Commit 320e98b

Browse files
committed
Fix unlinking old job out/err files.
1 parent 71f1e9e commit 320e98b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cylc/flow/job_runner_mgr.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -568,8 +568,8 @@ def _job_submit_impl(
568568
# Create NN symbolic link, if necessary
569569
self._create_nn(job_file_path)
570570
for name in JOB_LOG_ERR, JOB_LOG_OUT:
571-
with suppress(OSError):
572-
os.unlink(os.path.join(job_file_path, name))
571+
with suppress(FileNotFoundError):
572+
os.unlink(os.path.join(os.path.dirname(job_file_path), name))
573573

574574
# Start new status file
575575
with open(f"{job_file_path}.status", "w") as job_status_file:

0 commit comments

Comments
 (0)