compact folder changes/corrupts order received value of local mail folder (column name of "Order Received" is misleading. Column name "Mail Offset" is better?)

RESOLVED WONTFIX

Status

--
minor
RESOLVED WONTFIX
10 years ago
3 years ago

People

(Reporter: cdmoz, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

10 years ago
User-Agent:       Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-GB; rv:1.9.0.7) Gecko/2009021906 Firefox/3.0.7 FirePHP/0.2.4
Build Identifier: version 2.0.0.21 (20090302)

20,000 emails 
order received range from 300000 to 80000000
compact folder and 
order received range changes to 1000 to 80000000


Reproducible: Always

Steps to Reproduce:
1. get 20000 emails
2. delete first 1000 and last 1000 emails
3. make a note of first and last order received
4. compact folder 
Actual Results:  
first and last order received values have changed !

Expected Results:  
first and last order received values should not change
Local mail folder?(POP3 or "Local Folders")? IMAP folder?

Value in "Order Received" column is: 
  Local mail folder : Offset of mail data in mail folder file(Unix Mbox)
                      (UIDL of the mail is saved in X-UIDL: header)
  IMAP older        : UID of mail
  Newsgroup         : ARTICLE number of news article

"Compact of local mail folder" is removal of mail data with MSG_FLAG_EXPUNGED 
bit=ON in X-Mozilla-Status: header(==mail data of deleted mail).
( See http://www.eyrich-net.org/mozilla/X-Mozilla-Status.html?en )
So offset in mail folder file becomes different by "compact folder" operation.
"Order Received" is surely misleading column name when local mail folder.

If IMAP or Newsgroup, it's server error or result of server side configuration change(restructuring of mail/news data base), because it means that UID or ARTICLE number is changed at server.
(Reporter)

Comment 2

10 years ago
its a local folder getting emails from googlemail via POP

maybe just renaming column to "mail offset" would fix it !
Summary: compact folder corrupts order received → compact folder corrupts order received value of local mail folder (column name of "Order Received" is misleading. "Mail Offset" is better?)

Comment 3

6 years ago
Please don't change this behavior!
Yes, maybe the column naming is misleading, but the info about offset is valuable when manually inspecting or repairing Mbox files.

Possible solution:
Have 2 columns, "Order Received" + "Mail Offset"

Comment 4

5 years ago
Thoughts on column name of "Order Received" is misleading, column name "Mail Offset" is better?  Might upset those who are accustomed to seeing Order Received.
Severity: normal → minor
Flags: needinfo?(kent)
Flags: needinfo?(bwinton)
OS: Mac OS X → All
Summary: compact folder corrupts order received value of local mail folder (column name of "Order Received" is misleading. "Mail Offset" is better?) → compact folder changes/corrupts order received value of local mail folder (column name of "Order Received" is misleading. Column name "Mail Offset" is better?)
"Mail Offset" confuses even me, and seems like an implementation detail that people shouldn't depend on or care about.  (For that matter, what does it even mean for Maildir?)
Flags: needinfo?(bwinton)

Comment 6

5 years ago
It *is* an implementaton detail, so why not name it as that. From my side you could also name it:
MBOX offset
MBOX-file offset
internal start address
... or any similar combinations
Having 2 columns would help for all needs, also for inspecting IMAP offline-store mbox files.
A numbering like IMAP UID for local folders could be established by calculating the ordinal on the fly while opening the folder.

Comment 7

5 years ago
But the column also means Order received. That it changes value at compact time is an implementation detail, but even after compact it still shows the relative order of the messages as received. Why do you need the absolute values of the column to be permanent?

Also, the value actually is not Message offset in all circumstances. In some cases it is computed differently (see e.g. bug 793865). So the column renaming would not be correct again.

I think Order received is a universal name that holds true after all changes of the implementation we currently have in queue.

Comment 8

5 years ago
(In reply to :aceman from comment #7)
> But the column also means Order received. That it changes value at compact
> time is an implementation detail, but even after compact it still shows the
> relative order of the messages as received. Why do you need the absolute
> values of the column to be permanent?
>
 
I agree. When you say "Order received" you also need to add "compared to what?" We're just comparing here to a moving target, but the net result is still "order received" compared to something.

I would WONTFIX this.
Flags: needinfo?(kent)

Comment 9

4 years ago
per comment 8
Status: UNCONFIRMED → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → WONTFIX

Comment 10

3 years ago
(In reply to :aceman from comment #7)
> But the column also means Order received. That it changes value at compact
> time is an implementation detail, but even after compact it still shows the
> relative order of the messages as received. Why do you need the absolute
> values of the column to be permanent?

The problem is the column is permanent. After a compact new messages are added with "order re3ceived" values which interleave with older messages.

But WONTFIX is appropriate as Order Received is fixed in bug 1183490.

Comment 11

3 years ago
(In reply to B.J. Herbison from comment #10)
> The problem is the column is permanent. After a compact new messages are
> added with "order re3ceived" values which interleave with older messages.
> 
> But WONTFIX is appropriate as Order Received is fixed in bug 1183490.

Yes, that was incorrect behaviour and should be fixed now.
You need to log in before you can comment on or make changes to this bug.