X-Git-Url: https://git.mdrn.pl/edumed.git/blobdiff_plain/4b2479a67217baa238beb0b407a63ff1025b09f1..243f4c5eef6c3f1d6e6d2875080e5830cf5382a8:/wtem/management/commands/wtem_send_keys.py?ds=sidebyside diff --git a/wtem/management/commands/wtem_send_keys.py b/wtem/management/commands/wtem_send_keys.py index 213f992..4a1760c 100644 --- a/wtem/management/commands/wtem_send_keys.py +++ b/wtem/management/commands/wtem_send_keys.py @@ -36,7 +36,6 @@ class Command(BaseCommand): def send_keys(self, *args, **options): sent = 0 - skipped = 0 failed = 0 submissions = Submission.objects.all() @@ -52,7 +51,7 @@ class Command(BaseCommand): self.send_key(submission) except Exception as e: failed += 1 - self.stdout.write('failed sending to: ' + submission.email + ' - ' + str(e)) + self.stdout.write('failed sending to: ' + submission.email + ' - ' + repr(e)) else: submission.key_sent = True submission.save() @@ -64,6 +63,6 @@ class Command(BaseCommand): def send_key(self, submission): self.stdout.write('>>> sending to ' + submission.email) send_mail( - subject="WTEM - Twój link do zadań", + subject="Olimpiada Cyfrowa - Twój link do zadań I etapu", body=render_to_string('wtem/email_key.txt', dict(submission=submission)), to=[submission.email])