Author bpoaugust
Recipients barry, bpoaugust, r.david.murray
Date 2017-09-20.01:05:18
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1505869519.0.0.559564062212.issue31524@psf.upfronthosting.co.za>
In-reply-to
Content
It is not saving the unix from line.

#!/usr/bin/env python3

with open("test.mbox",'w') as f:
    f.write("From sender@invalid Thu Nov 17 00:49:30 2016\n")
    f.write("Subject: Test\n")
    f.write("\n")
    f.write("\n")

import mailbox
messages = mailbox.mbox("test.mbox")
for msg in messages:
    print(msg.get('subject'))
    print(msg.get_from())
    print(msg.get_unixfrom())
History
Date User Action Args
2017-09-20 01:05:19bpoaugustsetrecipients: + bpoaugust, barry, r.david.murray
2017-09-20 01:05:19bpoaugustsetmessageid: <1505869519.0.0.559564062212.issue31524@psf.upfronthosting.co.za>
2017-09-20 01:05:18bpoaugustlinkissue31524 messages
2017-09-20 01:05:18bpoaugustcreate