Unread deleted mail can not be restored from the trash folder with mail.server.default.dup.action = 2 (move duplicated mails to trash)
Categories
(MailNews Core :: Networking: IMAP, defect)
Tracking
(Not tracked)
People
(Reporter: patrick.abiven, Unassigned)
References
Details
Reporter | ||
Comment 1•14 years ago
|
||
Reporter | ||
Comment 2•14 years ago
|
||
Comment 3•14 years ago
|
||
Comment 4•14 years ago
|
||
Reporter | ||
Comment 5•14 years ago
|
||
Comment 6•14 years ago
|
||
Comment 7•14 years ago
|
||
Comment 8•14 years ago
|
||
Comment 9•14 years ago
|
||
Comment 10•14 years ago
|
||
Comment 11•9 years ago
|
||
Comment 12•5 years ago
|
||
Description of duplicate detection and bug where it was added: bug 9413 comment 37
Comment 13•5 years ago
|
||
I can duplicate this bug but with a somewhat different STR than is described in comment 0 and comment 1:
- Delete to trash a never before deleted message in Inbox
- Go to trash and move it back to Inbox.
- Go to Inbox and see that the message is back.
- Delete the same message again.
- Go to trash and again move it back to Inbox
- The message disappears from trash but shortly comes right back.
- Go to Inbox and notice that the message is not there.
So this only seems to be a problem when the same message is deleted to trash two or more times. Only in that case will the hash table detect a duplicate and move the message back to trash when dup_action is 2. Note also that if dup_action is set to 1, only after the 2nd delete to trash and move back to inbox will the message be marked \deleted as was observer in bug 1580060, so that bug is actually a duplicate of this bug.
Comment 15•5 years ago
|
||
(In reply to David :Bienvenu from comment #7)
that hashtable would be nsIMsgIncomingServer::m_downloadedHdrs, and you're
right that moving a message out of a folder doesn't get reflected in that
hash table. But, it might be simpler just to add a check that there's still
a duplicate header (e.g., with the same message id) in the folder.
Not sure what this is suggesting. Get rid of hash table and scan all the messages in folder looking for a matching message-id (and subject?) and if found, do dup_action on the highest "duplicate" UID?
Comment 16•5 years ago
|
||
Ok, I've looked at the code and can't find an easy fix for this, so I will just suggest a workaround and mark this as WONTFIX.
If dup_action is set to 1 (mark dup as deleted) or 2 (move dup to Trash) and when you try to move a message that was previously deleted or moved from Inbox in the same session back to Inbox, if set to 1, it disappears in Inbox or, if set to 2, it moves right back to Trash.
If dup_action is set to 1, you will need to temporarily set the delete method to "just mark it as deleted" and re-select Inbox to see the deleted messages with red X and crossed out, then un-delete the messages. (Don't compact Inbox or the messages marked deleted will be permanently deleted!)
If dup_action is set to 2, you need to restart Thunderbird and then you can move the messages from Trash back to Inbox. Restarting TB will reset the hash table so the messages are not immediately detected as duplicates and can be moved back to Inbox and stay there.
If dup_action is set to 3 (mark dup as read) there is probably no issue here since the message should still be visible when moved back to Inbox.
Since dup_action is a hidden pref that "voids your warranty" when set to something other than 0 (allow duplicates), I think WONTFIX is OK unless at some future time the dup_action setting is incorporated into the formal UI other than config editor.
Note: The mozillazine documentation for mail.server.default.dup_action describes it as a boolean and contains no useful information:
http://kb.mozillazine.org/Mail_and_news_settings
Description
•