mirror of https://github.com/zulip/zulip.git
send_email: Increase loglevel of stuck ScheduledEmail messages to error.
Since these stay in the queue indefinitely, they deserve to be raised at a higher error than just warning.
This commit is contained in:
parent
e080a05b05
commit
b9948994d7
|
@ -434,7 +434,7 @@ def deliver_scheduled_emails(email: ScheduledEmail) -> None:
|
|||
# This state doesn't make sense, so something must be mutating,
|
||||
# or in the process of deleting, the object. We assume it will bring
|
||||
# things to a correct state, and we just do nothing except logging this event.
|
||||
logger.warning("ScheduledEmail id %s has empty users and address attributes.", email.id)
|
||||
logger.error("ScheduledEmail id %s has empty users and address attributes.", email.id)
|
||||
return
|
||||
|
||||
if user_ids:
|
||||
|
|
|
@ -1468,7 +1468,7 @@ class ActivateTest(ZulipTestCase):
|
|||
self.assertEqual(
|
||||
info_log.output,
|
||||
[
|
||||
f"WARNING:zulip.send_email:ScheduledEmail id {email.id} has empty users and address attributes."
|
||||
f"ERROR:zulip.send_email:ScheduledEmail id {email.id} has empty users and address attributes."
|
||||
],
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in New Issue