User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:220.127.116.11) Gecko/20070309 Firefox/18.104.22.168
Build Identifier: version 22.214.171.124 (20070326)
Thunderbird normally stores tags as message attributes in the remote folder if the IMAP server supports it. Otherwise it uses the .msf file. Mbox files store the tag using a X-Mozilla-Keys header, which can be used in message filters and searches if you add a custom header for it. However, if you move/copy a message from a remote folder to a local folder it always stores any tags in the .msf file, which means you can not find that tag in filters or searches.
A common quick and dirty fix for mildly corrupted folders is to delete the .msf file. That rebuilds the .msf file from the data in the mbox file. If you do this you will lose the tag for that message since it is not stored in the mbox file.
There is no obvious reason why the tag for a message in a mbox file should be stored differently depending upon where the message originated.
Steps to Reproduce:
1.Create a tag for a message in a remote folder on a IMAP server that stores it as a message attribute. You could use a free account at www.fastmail.fm to do this.
2. Copy or move the tagged message to the local folders directory, or a POP account.
3. Use View -> Message Source and look for the X-Mozilla-Keys: header in the message.
The message doesn't have a X-Mozilla-Keys: header. If you search the folders .msf file with a text editor you can find the tag. If you exit Thunderbird, delete the .msf file, and then restart Thunderbird the tag disappears. Any tags for messages created in POP accounts don't disappear.
The reason is probably because the imap message doesn't get an x-mozilla-keys header added when the message is copied to the local folder. If you compact the local folder afterwards, we'll add an x-mozilla-keys header for the messages w/o the header.
But yes, we should add the x-mozilla-keys header when the imap message is added to the local folder...
David, Would this fix all cases where local folder reindex might lose tags?
This would partly solve bug 392704. What about mail servers that don't support tag attributes - are they rare?
*** Bug 394098 has been marked as a duplicate of this bug. ***
*** Bug 440367 has been marked as a duplicate of this bug. ***
I've been frequently loosing tags. This is getting very frustrating. I'm sure others, like myself, cannot easily reproduce the tagging. In my case, I tag messages for follow-up. When I loose tags, I loose all information about what needs follow-up. This is extremely problematic.
I use IMAP and configure the affected folders to also store mail locally. I access the IMAP folders from different machines and also from my phone using iphone Mail. Generally this all works but every once in a while I loose tags. I think the problem happens when folders get in a bad state and need to be rebuilt.
I hope the fix to this bug will improve the reliability of tags. As I noted above, loosing tagging information is a significant inconvenience.
If there is a patch or interim fix to this, I'd be quite happy to take and test it. I don't have a clean repro (other than to delete an MSF file. I've not tested but maybe corrupting an MSF file is also a good repro.
bug 691770 has a fix for this.
*** This bug has been marked as a duplicate of bug 691770 ***