From b88bac0523cebb92c5c78fcda452e767aa891527 Mon Sep 17 00:00:00 2001 From: Nils Brederlow <62596379+dingodoppelt@users.noreply.github.com> Date: Tue, 7 Apr 2026 12:25:33 +0200 Subject: [PATCH] Trigger storage hook on sharing/delete with files backend Unlike with the csv backend the files backend acquired only a reading lock which didn't trigger the storage hook. --- radicale/sharing/files.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/radicale/sharing/files.py b/radicale/sharing/files.py index 13ca15a6..6c9a87a5 100644 --- a/radicale/sharing/files.py +++ b/radicale/sharing/files.py @@ -372,8 +372,8 @@ class Sharing(sharing.BaseSharing): if not os.path.isfile(sharing_config_file): return {"status": "not-found"} - # read content - with self._storage.acquire_lock("r", path=sharing_config_file): + # open writable so storage hook triggers + with self._storage.acquire_lock("w", path=sharing_config_file): # read file with open(sharing_config_file, "rb") as fb: (version, row) = pickle.load(fb)