~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/services/mail/incoming.py

  • Committer: Curtis Hovey
  • Date: 2011-06-08 13:53:29 UTC
  • mfrom: (13176 devel)
  • mto: This revision was merged to the branch mainline in revision 13177.
  • Revision ID: curtis.hovey@canonical.com-20110608135329-5bd42r7afgzcl3lt
Merged devel.

Show diffs side-by-side

added added

removed removed

Lines of Context:
110
110
 
111
111
 
112
112
def _authenticateDkim(signed_message):
113
 
    """"Attempt DKIM authentication of email; return True if known authentic
 
113
    """Attempt DKIM authentication of email; return True if known authentic
114
114
 
115
115
    :param signed_message: ISignedMessage
116
116
    """
368
368
                log.exception(
369
369
                    "An exception was raised inside the handler:\n%s"
370
370
                    % (file_alias_url,))
 
371
                # Delete the troublesome email before attempting to send the
 
372
                # OOPS in case something goes wrong.  Retrying probably
 
373
                # wouldn't work and we'd get stuck on the bad message.
 
374
                mailbox.delete(mail_id)
371
375
                _send_email_oops(trans, log, mail,
372
376
                    "Unhandled exception", file_alias_url)
373
 
                mailbox.delete(mail_id)
374
377
    finally:
375
378
        log.info("Closing the mail box.")
376
379
        mailbox.close()
414
417
 
415
418
 
416
419
def handle_one_mail(log, mail, file_alias, file_alias_url,
417
 
    signature_timestamp_checker):
 
420
                    signature_timestamp_checker):
418
421
    """Process one message.
419
422
 
420
423
    Returns None when the message has either been successfully processed, or