Open Bug 457605 Opened 16 years ago Updated 9 years ago

all "mark as deleted" messages expunged when creating new IMAP account

Categories

(Thunderbird :: Account Manager, defect)

x86
Windows XP
defect
Not set
critical

Tracking

(Not tracked)

People

(Reporter: monster, Unassigned)

References

Details

(Keywords: dataloss)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/525.13 (KHTML, like Gecko) Chrome/0.2.149.30 Safari/525.13
Build Identifier: version 2.0.0.17 (20080914)

I installed Thunderbird on a new PC, and entered the information for my IMAP account.  Upon completion, and without confirmation, Thunderbird expunged thousands of messages that were marked as deleted.

Reproducible: Always

Steps to Reproduce:
1. Have available an inbox on an IMAP server, with one or more messages marked for deletion (e.g. delete them from PINE, but do not expunge)
2. Create Thunderbird email account using IMAP to point to this inbox
3. Log in to the new account
Actual Results:  
All existing messages marked for deletion are immediately expunged with no confirmation or warning.

Expected Results:  
Existing messages marked for deletion should be left alone.
Component: Account Manager → Networking: IMAP
Product: Thunderbird → Core
QA Contact: account-manager → networking.imap
you state you can reproduce always. can you reproduce on current that same PC by deleting elsewhere, then starting TB2 on this new PC?
Keywords: dataloss
Version: unspecified → 1.8 Branch
I tested this again today with Thunderbird 2.0.0.18 and the bug is still present.  Here's how I tested:

1. Created account "tbird" on my IMAP server "neil".
2. Logged in to neil as tbird and sent 4 messages to myself using PINE.
3. Also using PINE, I marked 2 messages as deleted but did not expunge.
4. I then created an account for tbird on another PC with Thunderbird 1.0.6 and as a precautionary measure, during account creation, set the option "When I delete a message:" under Server Settings from the default "Move it to the Trash folder" to "Mark it as deleted".
5. I opened tbird's Inbox using this account, observed that existing deleted messages were not expunged, and marked a third message as deleted (leaving one message still untouched).
6. I created an account for tbird on my PC running Thunderbird 2.0.0.18 and left all the options default.
7. I opened tbird's Inbox using the account I created and observed that all 3 messages that had previously been marked as deleted were gone, and not present in any Trash folder.
8. Using PINE, I then sent additional test messages to myself and marked them as deleted.
9. I deleted the tbird account from Thunderbird 2.0.0.18 and re-created it, making sure to change the "When I delete a message" option to "Mark it as deleted" this time.
10. I opened tbird's Inbox and the previously deleted messages had not been expunged.

From this I draw two conclusions:
I. This bug is likely present in all versions, 1.0.6 and 2.0.0.18 at the very least.
II. The bug is related to the "When I delete a message" option under Server Settings.  If it is left as the default of "Move it to the Trash folder" then previously deleted messages will be expunged (NOT moved to any Trash folder!).  If it is set to "Mark it as deleted" BEFORE logging in for the first time, previously deleted messages will be preserved.
Unless you pick the imap delete model, mark as deleted, Thunderbird will handle expunging for you, by design.

In 3.0, we will make it a little easier for you to change the delete model when setting up the account, by allowing you to go from the account wizards to account settings directly.
"Unless you pick the imap delete model, mark as deleted..."
Shouldn't that be the default for IMAP accounts?  Or should there not at least be a warning or confirmation that your messages will be permanently deleted?  Or if the "move to trash" option is selected, shouldn't the deleted messages be moved to trash?
No, we don't think most users want the imap delete model. The trash delete model is much more familiar. There are people who think we should stop supporting the imap delete model entirely, but I'd like to keep it as long as its not too much trouble to maintain.
Be that as it may, there still needs to be a warning/confirmation, or deleted messages should be moved to trash, rather than being expunged.  Let's not lose sight of the many thousands of messages permanently deleted by this bug.
Product: Core → MailNews Core
bwinton, any thoughts on this?  

And I wonder if this might be even more of an issue given the changes with autoconfig.
Status: UNCONFIRMED → NEW
Component: Networking: IMAP → Account Manager
Ever confirmed: true
Product: MailNews Core → Thunderbird
QA Contact: networking.imap → account-manager
Version: 1.8 Branch → unspecified
there's no difference between 2.0 and 3.0 in this respect - both create accounts with the delete to trash model by default, which we feel is the correct default for the vast majority of our users.
I don't think it's more of an issue, per se, but I agree that we should, perhaps, on account creation move the currently deleted messages into the trash before expunging them.

Or, if we detected that there were deleted messages when we first, maybe we should set the account to use the imap delete model, since they've probably come from a mail client that used it, so that's what they'll be familiar with.
Summary: all deleted messages expunged when creating new IMAP account → all "mark as deleted" messages expunged when creating new IMAP account
You need to log in before you can comment on or make changes to this bug.