We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b3c1999 commit 64fbe2bCopy full SHA for 64fbe2b
datajoint/connection.py
@@ -258,11 +258,10 @@ def set_query_cache(self, query_cache=None):
258
def purge_query_cache(self):
259
"""Purges all query cache."""
260
if (
261
- cache_key in config
262
- and isinstance(config[cache_key], str)
+ isinstance(config.get(cache_key), str)
263
and pathlib.Path(config[cache_key]).is_dir()
264
):
265
- for path in pathlib.Path(config[cache_key].iterdir()):
+ for path in pathlib.Path(config[cache_key]).iterdir():
266
if not path.is_dir():
267
path.unlink()
268
0 commit comments