You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The correct solution to disabling the cache is actually setting CACHEOPS_ENABLED = False. This was overlooked during our fork and refactor process. The value inside of django-cacheops core defaults to True.
…94)
* Fix#83 - Implement a system check for `CACHEOPS_DEFAULT['timeout']`
This implements `nautobot.core.checks` and registers the first check error of `nautobot.E001` to assert that the value of `CACHEOPS_DEFAULTS['timeout']` can never be `0`.
When attempting to start the server if this value is `0`, startup is blocked and the following error will be displayed:
```
django.core.management.base.SystemCheckError: SystemCheckError: System check identified some issues:
ERRORS:
?: (nautobot.E001) CACHEOPS_DEFAULTS['timeout'] value cannot be 0. To disable caching set CACHEOPS_ENABLED=False.
System check identified 1 issue (0 silenced).
```
- `CACHEOPS_ENABLED = True` added back explicitly to `nautobot.core.settings`
- `CACHEOPS_ENABLED = True` added to the template config at `nautobot.core.templates.nautobot_config.py.j2`
- `CACHEOPS_ENABLED` added to optional settings documentation
- A unit test for the check has been implemented
* Add `nautobot-server check` to deploy guide.
* Move "Check your Configuration" below "Test the Application"
Environment
Steps to Reproduce
CACHEOPS_DEFAULTS = {"timeout": 0}
in yournautobot_config.py
Expected Behavior
Cache should be disabled.
Observed Behavior
500 error:
The text was updated successfully, but these errors were encountered: