Well, nothing makes sense. Neither the good or bad log you attached show the \deleted flag being stored nor does it list any messaging having the \deleted flag set. So there is no evidence in the logs that tb is somehow setting (storing) the \deleted flag on the message that gets moved back to inbox. However, the "It broke like this:" scenario sure seems like tb is causing the problem. Can you record a log (probably using your main installation) that show tb setting the \deleted flag at some point? You may need to grep the log and look for regexp "senddata.*store.*delete" in the content somewhere. No reason to attach log unless you see a store of \deleted occur in the log. I'm not sure how roundcube talks to your server; I assume it is via imap between the webserver and the imap server. Maybe there is a log at the imap server you can record that would shows all the client imap activity: tb, roundcube, phone mail. Maybe you could use wireshark or even tcpdump to see the network activity of all clients. Other than this, I can't seem to duplicate the problem and don't know what else to suggest.
Bug 1580060 Comment 17 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
Well, nothing makes sense. Neither the good or bad log you attached show the \deleted flag being stored nor does it list any messages having the \deleted flag set. So there is no evidence in the logs that tb is somehow setting (storing) the \deleted flag on the message that gets moved back to inbox. However, the "It broke like this:" scenario in comment 16 sure seems like tb is causing the problem. Can you record a log (probably using your main installation) that show tb setting the \deleted flag at some point? You may need to grep the log and look for regexp "senddata.*store.*delete" in the content somewhere. No reason to attach the log unless you see a store of \deleted occur in the log. I'm not sure how roundcube talks to your server; I assume it is via imap between the webserver and the imap server. Maybe there is a log at the imap server you can record that would shows all the client imap activity: tb, roundcube, phone mail. Maybe you could use wireshark or even tcpdump to see the network activity of all clients. Other than this, I can't seem to duplicate the problem and don't know what else to suggest.