{"action":"created","issue":{"url":"https://api.github.com/repos/OfflineIMAP/offlineimap/issues/216","labels_url":"https://api.github.com/repos/OfflineIMAP/offlineimap/issues/216/labels{/name}","comments_url":"https://api.github.com/repos/OfflineIMAP/offlineimap/issues/216/comments","events_url":"https://api.github.com/repos/OfflineIMAP/offlineimap/issues/216/events","html_url":"https://github.com/OfflineIMAP/offlineimap/issues/216","id":95242233,"number":216,"title":"Can't save a zero byte message","user":{"login":"emmanuelgeoffray","id":808090,"avatar_url":"https://avatars.githubusercontent.com/u/808090?v=3","gravatar_id":"","url":"https://api.github.com/users/emmanuelgeoffray","html_url":"https://github.com/emmanuelgeoffray","followers_url":"https://api.github.com/users/emmanuelgeoffray/followers","following_url":"https://api.github.com/users/emmanuelgeoffray/following{/other_user}","gists_url":"https://api.github.com/users/emmanuelgeoffray/gists{/gist_id}","starred_url":"https://api.github.com/users/emmanuelgeoffray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emmanuelgeoffray/subscriptions","organizations_url":"https://api.github.com/users/emmanuelgeoffray/orgs","repos_url":"https://api.github.com/users/emmanuelgeoffray/repos","events_url":"https://api.github.com/users/emmanuelgeoffray/events{/privacy}","received_events_url":"https://api.github.com/users/emmanuelgeoffray/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/OfflineIMAP/offlineimap/labels/question","name":"question","color":"cc317c"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-07-15T16:59:40Z","updated_at":"2015-09-08T13:33:59Z","closed_at":"2015-09-03T22:41:02Z","body":"Hey there,\r\nI have an issue with offlineimap crashing with the server replying \"Can't save a zero byte message\"\r\nAny idea why would offlineimap try to sync a zero byte message?\r\nMy hard drive was ful lately, do you think the issue started from there?\r\n\r\nHere is the log \r\n```\r\nINFO:OfflineImap:Syncing Sent: IMAP -> Maildir\r\nCopy message -1 (1 of 2) MyLocal:Sent -> MyGandi\r\nINFO:OfflineImap:Copy message -1 (1 of 2) MyLocal:Sent -> MyGandi\r\nSyncing Sent Messages: IMAP -> Maildir\r\nINFO:OfflineImap:Syncing Sent Messages: IMAP -> Maildir\r\nThread 'Folder Sent [acc: MyAccount]' terminated with exception:\r\nTraceback (most recent call last):\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/threadutil.py\", line 158, in run\r\n    Thread.run(self)\r\n  File \"/usr/lib/python2.7/threading.py\", line 763, in run\r\n    self.__target(*self.__args, **self.__kwargs)\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/accounts.py\", line 458, in syncfolder\r\n    localfolder.syncmessagesto(remotefolder, statusfolder)\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/folder/Base.py\", line 549, in syncmessagesto\r\n    action(dstfolder, statusfolder)\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/folder/Base.py\", line 432, in syncmessagesto_copy\r\n    register = 0)\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/folder/Base.py\", line 358, in copymessageto\r\n    new_uid = dstfolder.savemessage(uid, message, flags, rtime)\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/folder/IMAP.py\", line 554, in savemessage\r\n    raise OfflineImapError(msg, OfflineImapError.ERROR.REPO)\r\nOfflineImapError: Saving msg in folder 'Sent', repository 'MyGandi' failed (abort). Server responded: NO [\"Can't save a zero byte message.\"]\r\n\r\n\r\n\r\nLast 15 debug messages logged for Folder Sent [acc: MyAccount] prior to exception:\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6096'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6097'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6098'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6099'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6100'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6101'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6102'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6103'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6104'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6105'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6106'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6107'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6108'}\r\nimap: Write mail 'Sent:-1' with flags set(['S'])\r\nimap: savemessage: date: \"09-Jul-2015 15:11:17 +0100\", content: ''\r\nWARNING:OfflineImap:Thread 'Folder Sent [acc: MyAccount]' terminated with exception:\r\nTraceback (most recent call last):\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/threadutil.py\", line 158, in run\r\n    Thread.run(self)\r\n  File \"/usr/lib/python2.7/threading.py\", line 763, in run\r\n    self.__target(*self.__args, **self.__kwargs)\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/accounts.py\", line 458, in syncfolder\r\n    localfolder.syncmessagesto(remotefolder, statusfolder)\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/folder/Base.py\", line 549, in syncmessagesto\r\n    action(dstfolder, statusfolder)\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/folder/Base.py\", line 432, in syncmessagesto_copy\r\n    register = 0)\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/folder/Base.py\", line 358, in copymessageto\r\n    new_uid = dstfolder.savemessage(uid, message, flags, rtime)\r\n  File \"/usr/lib/python2.7/dist-packages/offlineimap/folder/IMAP.py\", line 554, in savemessage\r\n    raise OfflineImapError(msg, OfflineImapError.ERROR.REPO)\r\nOfflineImapError: Saving msg in folder 'Sent', repository 'MyGandi' failed (abort). Server responded: NO [\"Can't save a zero byte message.\"]\r\n\r\n\r\n\r\nLast 15 debug messages logged for Folder Sent [acc: MyAccount] prior to exception:\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6096'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6097'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6098'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6099'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6100'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6101'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6102'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6103'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6104'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6105'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6106'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6107'}\r\nimap: options2hash returning: {'FLAGS': '(\\\\Seen)', 'UID': '6108'}\r\nimap: Write mail 'Sent:-1' with flags set(['S'])\r\nimap: savemessage: date: \"09-Jul-2015 15:11:17 +0100\", content: ''\r\n```"},"comment":{"url":"https://api.github.com/repos/OfflineIMAP/offlineimap/issues/comments/138560035","html_url":"https://github.com/OfflineIMAP/offlineimap/issues/216#issuecomment-138560035","issue_url":"https://api.github.com/repos/OfflineIMAP/offlineimap/issues/216","id":138560035,"user":{"login":"emmanuelgeoffray","id":808090,"avatar_url":"https://avatars.githubusercontent.com/u/808090?v=3","gravatar_id":"","url":"https://api.github.com/users/emmanuelgeoffray","html_url":"https://github.com/emmanuelgeoffray","followers_url":"https://api.github.com/users/emmanuelgeoffray/followers","following_url":"https://api.github.com/users/emmanuelgeoffray/following{/other_user}","gists_url":"https://api.github.com/users/emmanuelgeoffray/gists{/gist_id}","starred_url":"https://api.github.com/users/emmanuelgeoffray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emmanuelgeoffray/subscriptions","organizations_url":"https://api.github.com/users/emmanuelgeoffray/orgs","repos_url":"https://api.github.com/users/emmanuelgeoffray/repos","events_url":"https://api.github.com/users/emmanuelgeoffray/events{/privacy}","received_events_url":"https://api.github.com/users/emmanuelgeoffray/received_events","type":"User","site_admin":false},"created_at":"2015-09-08T13:33:59Z","updated_at":"2015-09-08T13:33:59Z","body":"Sorry I didn't read your replay @johnmastro \r\nThank you very much, that worked!\r\n"}}