From a5308cc6b7c27b8261104c1236b7686dc80abaab Mon Sep 17 00:00:00 2001 From: "Andrew S. Rosen" Date: Sun, 17 Dec 2023 21:39:43 -0800 Subject: [PATCH] More error-prone `shutil.move`-ing of job files --- src/quacc/runners/prep.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/quacc/runners/prep.py b/src/quacc/runners/prep.py index 7532f05ed4..95bb60f65a 100644 --- a/src/quacc/runners/prep.py +++ b/src/quacc/runners/prep.py @@ -104,7 +104,7 @@ def calc_cleanup(tmpdir: Path, job_results_dir: Path) -> None: # Move files from tmpdir to job_results_dir for file_name in os.listdir(tmpdir): - if Path(job_results_dir / file_name).exists(): + if Path(job_results_dir / file_name).is_dir(): remove(job_results_dir / file_name) move(tmpdir / file_name, job_results_dir / file_name)