diff --git a/PFERD/tmp_dir.py b/PFERD/tmp_dir.py index 850d886..fc132b8 100644 --- a/PFERD/tmp_dir.py +++ b/PFERD/tmp_dir.py @@ -18,6 +18,7 @@ class TmpDir(Location): """Create a new temporary folder for the given path.""" super().__init__(path) self._counter = 0 + self.cleanup() self.path.mkdir(parents=True, exist_ok=True) def __str__(self) -> str: diff --git a/PFERD/utils.py b/PFERD/utils.py index e2b69be..7b8e86c 100644 --- a/PFERD/utils.py +++ b/PFERD/utils.py @@ -88,7 +88,7 @@ class Location: """ def __init__(self, path: Path): - self._path = path + self._path = path.resolve() @property def path(self) -> Path: