Explorar el Código

Merge pull request #18516 from tobiasge/dont-fail-on-debug

Fix #18515: Don't fail in DEBUG mode
bctiemann hace 1 año
padre
commit
9ac79ebbdf
Se han modificado 1 ficheros con 4 adiciones y 1 borrados
  1. 4 1
      netbox/core/apps.py

+ 4 - 1
netbox/core/apps.py

@@ -28,4 +28,7 @@ class CoreConfig(AppConfig):
 
         # Clear Redis cache on startup in development mode
         if settings.DEBUG:
-            cache.clear()
+            try:
+                cache.clear()
+            except Exception:
+                pass