set default log level to warn, fix clean_nonces not working
This commit is contained in:
parent
9b8f390e31
commit
b369eb28f1
|
@ -15,8 +15,8 @@ data:
|
||||||
port: ''
|
port: ''
|
||||||
log:
|
log:
|
||||||
level:
|
level:
|
||||||
console: DEBUG
|
console: WARNING
|
||||||
file: DEBUG
|
file: WARNING
|
||||||
file: /dev/null
|
file: /dev/null
|
||||||
syslog:
|
syslog:
|
||||||
host: 127.0.0.1
|
host: 127.0.0.1
|
||||||
|
|
|
@ -24,5 +24,5 @@ def send_email(to_address, subject, template, context):
|
||||||
@CELERY_APP.task()
|
@CELERY_APP.task()
|
||||||
def clean_nonces():
|
def clean_nonces():
|
||||||
"""Remove expired nonces"""
|
"""Remove expired nonces"""
|
||||||
amount = Nonce.objects.filter(expires__lt=datetime.now(), expiring=True).delete()
|
amount, _ = Nonce.objects.filter(expires__lt=datetime.now(), expiring=True).delete()
|
||||||
LOGGER.debug("Deleted expired %d nonces", amount)
|
LOGGER.debug("Deleted expired %d nonces", amount)
|
||||||
|
|
Reference in a new issue