Sort welcome emails by user_id
This allows the test test_invalid_email_address_skips_invalid to have a deterministic logger sequence.
This commit is contained in:
Родитель
e17127e72d
Коммит
e6a68ec15f
|
@ -26,7 +26,7 @@ class Command(BaseCommand):
|
|||
logger.info("Starting send_welcome_emails")
|
||||
profiles_without_welcome_email = Profile.objects.filter(
|
||||
sent_welcome_email=False
|
||||
)
|
||||
).order_by("user_id")
|
||||
emails_to_send = len(profiles_without_welcome_email)
|
||||
logger.info(f"Emails to send: {emails_to_send}")
|
||||
for profile in profiles_without_welcome_email:
|
||||
|
|
Загрузка…
Ссылка в новой задаче