This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author petri.lehtinen
Recipients akuchling, chrisisbd, petri.lehtinen
Date 2012-06-18.08:01:08
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
This is actually not true. When calling add(), mbox (and MMDF and Babyl) append the message to the file without rewriting it.

It's the following flush() call that rewrites the whole mailbox contents. I think this could be changed to work correctly by not setting self._pending = True in _singlefileMailbox.add. This way, the file wouldn't be rewritten by flush() if messages are only appended.

OTOH, flush() should still fsync the mailbox file (if we want to ensure that the changes are really written to disk). This would probably require a new flag in addition to self._pending, to indicate that there are unsynced changes.
Date User Action Args
2012-06-18 08:01:10petri.lehtinensetrecipients: + petri.lehtinen, akuchling, chrisisbd
2012-06-18 08:01:09petri.lehtinensetmessageid: <>
2012-06-18 08:01:09petri.lehtinenlinkissue9559 messages
2012-06-18 08:01:08petri.lehtinencreate