• Quanah Gibson-Mount's avatar
    Significant update to jb2bz.py. (#58) · 7fd3bfed
    Quanah Gibson-Mount authored
    Fixes https://bugzilla.mozilla.org/show_bug.cgi?id=1427626
    Fixes https://bugzilla.mozilla.org/show_bug.cgi?id=1427638
    Fixes https://bugzilla.mozilla.org/show_bug.cgi?id=1427664
    
    Convert jb2bz to use "email" module rather than rfc822, multifile,
    mimetools, and StringIO for easier manipulation of the mailbox objects.
    
    This fixed (among other things) 1427626 as the Subject of the email is
    now obtained correctly.
    
    Fix the date formatting throughout to always use UTC, which is what
    Bugzilla expects for the dates.  This fixed 1427638.
    
    Fix attachment processing, which was using multifile rather than walking
    the parts of the email object.  This fixed part of 1427664
    
    Fix the fact that the process_reply_file function never checked for
    attachments in any followups.  This fixed part of 1427664
    
    Fix attachment processor to ignore various signatures and message/rfc822
    multipart messages.  For the latter, it sets "filename=" values to files
    that don't actually exist, which caused attachment processing to bomb.
    7fd3bfed
jb2bz.py 11.1 KB