mirror of
https://github.com/django-q2/django-q2.git
synced 2026-09-25 02:38:11 +08:00
exception raised if guard_cycle configured not in range (0, 60)
This commit is contained in:
@@ -73,6 +73,8 @@ class Conf(object):
|
||||
|
||||
# Guard loop sleep in seconds
|
||||
GUARD_CYCLE = conf.get('guard_cycle', 0.5)
|
||||
if GUARD_CYCLE <= 0 or GUARD_CYCLE >= 60:
|
||||
raise ValueError('`guard_cycle` must be greater than 0 and less than 60 sec')
|
||||
|
||||
# Disable the scheduler
|
||||
SCHEDULER = conf.get('scheduler', True)
|
||||
|
||||
+1
-1
@@ -81,7 +81,7 @@ Limits the amount of successful tasks saved to Django.
|
||||
guard_cycle
|
||||
~~~~~~~~~~~
|
||||
|
||||
Guard loop sleep in seconds
|
||||
Guard loop sleep in seconds, must be greater than 0 and less than 60.
|
||||
|
||||
.. _sync:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user