[offlineimap] MemoryError on RaspberryPi (#203)

Chris Coleman notifications at github.com
Thu May 21 17:18:50 BST 2015


@onlygecko @nicolas33
The following is my opinion!
Offlineimap algorithm implementation should be enhanced to run on far less memory, the 512MB in a R-Pi should be more than adequate.
See criticisms here: http://blog.ezyang.com/2012/08/offlineimap-sucks/
"Poor space complexity
The memory usage of OfflineIMAP is linear with the number of messages in your inbox. For large mailboxes, this effectively means loading hundreds of thousands of elements into a set and doing expensive operations on it (OfflineIMAP consistently pegs my CPU when I run it). OfflineIMAP should be able to run in constant space, but zero algorithmic thought has been put into this problem space."

For one, the messages should be downloaded with python directly to disk, not memory. Reason, exactly as in this case, you can legitimately have a 95MB email message containing base64 mime encoded attachments, but disk space is more plentiful than ram.  Also, most/all of the processing is on the header, and possibly the filename for the local Maildir option, body is ignored except for possible hash fingerprinting, so send it directly to disk.

Indeed, OLI is due for some implementation optimizations, it should run perfectly on a 512mb R-Pi, and consume a relatively constant amount of resources.  Possibly 40-50MB of ram?


---
Reply to this email directly or view it on GitHub:
https://github.com/OfflineIMAP/offlineimap/issues/203#issuecomment-104341836
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/offlineimap-project/attachments/20150521/0480e255/attachment-0003.html>


More information about the OfflineIMAP-project mailing list