I've spent about an hour this afternoon looking over this issue and don't really have much to tell you.
From the session log you sent me, it seems that the Android IMAP implementation is moving messages into a folder then attempting to find their UIDs by searching for a known characteristic of the message - in this case, the message-id. Leaving aside that this is pretty load-intensive for the server (note that the search takes nearly a minute), there's nothing technically wrong with it, and based on the logs, it looks as though it should work. For some reason, though, MercuryI isn't able to match the message-id, and returns a blank search response, which presumably is what leads the Android IMAP code to upload another copy of the message.
Unfortunately, I can't duplicate this here: part of the problem is simply the density of the IMAP protocol - I can't just duplicate the commands you've sent in the log, because they require a lot of contextual knowledge. The best I've been able to do is to manually move a message into a folder then immediately initiate a search for its message-id, and that seems to work every time. Another part of the problem is that the session logs you've sent aren't complete - they don't give me a full overview of the timing of the Android app's commands. It's possible, for example, that it's searching for the message-id *before* the message is actually moved into the folder, although this doesn't seem likely.
I'll keep looking into this, but I just wanted to send an update to let you know I was working on it.
Cheers!
-- David --
I've spent about an hour this afternoon looking over this issue and don't really have much to tell you.
From the session log you sent me, it seems that the Android IMAP implementation is moving messages into a folder then attempting to find their UIDs by searching for a known characteristic of the message - in this case, the message-id. Leaving aside that this is pretty load-intensive for the server (note that the search takes nearly a minute), there's nothing technically wrong with it, and based on the logs, it looks as though it should work. For some reason, though, MercuryI isn't able to match the message-id, and returns a blank search response, which presumably is what leads the Android IMAP code to upload another copy of the message.
Unfortunately, I can't duplicate this here: part of the problem is simply the density of the IMAP protocol - I can't just duplicate the commands you've sent in the log, because they require a lot of contextual knowledge. The best I've been able to do is to manually move a message into a folder then immediately initiate a search for its message-id, and that seems to work every time. Another part of the problem is that the session logs you've sent aren't complete - they don't give me a full overview of the timing of the Android app's commands. It's possible, for example, that it's searching for the message-id *before* the message is actually moved into the folder, although this doesn't seem likely.
I'll keep looking into this, but I just wanted to send an update to let you know I was working on it.
Cheers!
-- David --