mirror of
https://github.com/inventree/InvenTree.git
synced 2025-04-28 03:26:45 +00:00
(cherry picked from commit 8928bc127a4d9ed67baa1c68bb4eba9eccf9e8f9) Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
This commit is contained in:
parent
178e3313f9
commit
69676f308b
@ -5,7 +5,6 @@ import logging
|
||||
from datetime import timedelta
|
||||
|
||||
from django.utils import timezone
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
|
||||
from django_q.models import Success
|
||||
from django_q.status import Stat
|
||||
@ -63,13 +62,13 @@ def check_system_health(**kwargs):
|
||||
|
||||
if not is_worker_running(**kwargs): # pragma: no cover
|
||||
result = False
|
||||
logger.warning(_('Background worker check failed'))
|
||||
logger.warning('Background worker check failed')
|
||||
|
||||
if not InvenTree.email.is_email_configured(): # pragma: no cover
|
||||
result = False
|
||||
logger.warning(_('Email backend not configured'))
|
||||
logger.warning('Email backend not configured')
|
||||
|
||||
if not result: # pragma: no cover
|
||||
logger.warning(_('InvenTree system health checks failed'))
|
||||
logger.warning('InvenTree system health checks failed')
|
||||
|
||||
return result
|
||||
|
Loading…
x
Reference in New Issue
Block a user