From 4da6a6c1f6cba96a9e7ad9db96dada97902f77db Mon Sep 17 00:00:00 2001
From: simondreutter <simon.dreutter@awi.de>
Date: Wed, 11 Sep 2024 12:38:43 +0200
Subject: [PATCH] more robust Path bugfix

---
 process/config.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/process/config.py b/process/config.py
index e4dc7b0..775ef01 100644
--- a/process/config.py
+++ b/process/config.py
@@ -438,6 +438,8 @@ DONT_DELETE = [
 
 # function to clean up temporary files if they are not in the DONT_DELETE list
 def cleanup(dataset):
+    if isinstance(dataset, str):
+        dataset = Path(dataset)
     if dataset not in DONT_DELETE:
         if dataset.is_file():
             dataset.unlink()
-- 
GitLab