I must say that, at times, I think the aggravation of using an IMAP mailbox outweighs the benefits. The latest issue I faced was attempting to send two different messages&emdash;each using a different IMAP account. After telling me the message was sent, Thunderbird popped up a dialog for each message that said, "There was an error copying the message to the Sent folder - Retry?" Several retries later, I was no closer to having a copy of my outgoing messages saved.
I had the message windows still open, and the dialogs, each ending in two buttons, Retry and Cancel. I wasn't about to click Cancel, because if I did, I'd have no copy of the message.
The solution, in this case, was to compress the Saved folder, which is done by right-clicking on the folder and selecting Compress, after which the Retry worked with one message.
The other mailbox was a bit more stubborn. I had to right-click on the folder, again, and select Properties..., which brings up a new dialog, and click the Rebuild Index button.
Why do these things always happen when patience is at its lowest?