From 1b91b2f628a22110d0f1d5775516670f667101a5 Mon Sep 17 00:00:00 2001 From: Sandor Kertesz Date: Sun, 24 Nov 2024 12:10:15 +0000 Subject: [PATCH] Cannot free chache space due to sqlite row assignment error (#46) --- src/earthkit/regrid/utils/caching.py | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/src/earthkit/regrid/utils/caching.py b/src/earthkit/regrid/utils/caching.py index 328c551..ae4ed17 100644 --- a/src/earthkit/regrid/utils/caching.py +++ b/src/earthkit/regrid/utils/caching.py @@ -373,13 +373,10 @@ def _delete_entry(self, entry): except OSError: pass - if entry["size"] is None: - entry["size"] = 0 - - path, size = ( - entry["path"], - entry["size"], - ) + path = entry["path"] + size = entry["size"] + if size is None: + size = 0 # path, size, owner, args = ( # entry["path"],