Skip to content

Commit 085f013

Browse files
authored
Merge pull request #2249 from AppDaemon/persistent_namespace
namespace filename fix
2 parents af371a8 + b3e7bb9 commit 085f013

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

appdaemon/utils.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,8 @@ class PersistentDict(shelve.DbfilenameShelf):
9191
Dict-like object that uses a Shelf to persist its contents.
9292
"""
9393

94-
def __init__(self, filename, safe: bool, *args, **kwargs):
94+
def __init__(self, filename: Path, safe: bool, *args, **kwargs):
95+
filename = Path(filename).resolve().as_posix()
9596
# writeback=True allows for mutating objects in place, like with a dict.
9697
super().__init__(filename, writeback=True)
9798
self.safe = safe

0 commit comments

Comments
 (0)