[damned-lies] Force creating parents for ITS_DATA_DIR



commit cb9564ef7434e2ab0dd92475084479e5fa5f8952
Author: Claude Paroz <claude 2xlibre net>
Date:   Wed Mar 17 22:45:06 2021 +0100

    Force creating parents for ITS_DATA_DIR

 stats/utils.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/stats/utils.py b/stats/utils.py
index 20aed1eb..0b8224a1 100644
--- a/stats/utils.py
+++ b/stats/utils.py
@@ -654,7 +654,7 @@ def collect_its_data():
     from .models import Module, ModuleLock
 
     if not ITS_DATA_DIR.exists():
-        ITS_DATA_DIR.mkdir()
+        ITS_DATA_DIR.mkdir(parents=True)
     data_to_collect = getattr(settings, 'GETTEXT_ITS_DATA', {})
     for module_name, files in data_to_collect.items():
         mod = Module.objects.get(name=module_name)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]