Last Comment Bug 543088 - Autocomplete - primary email address no longer appears before additional email address (now sorted alphabetically)
: Autocomplete - primary email address no longer appears before additional emai...
Status: RESOLVED FIXED
[gs]
: fixed-seamonkey2.0.4, regression
Product: MailNews Core
Classification: Components
Component: Address Book (show other bugs)
: Trunk
: All All
: -- normal with 6 votes (vote)
: Thunderbird 3.1b2
Assigned To: Mark Banner (:standard8)
:
Mentors:
http://gsfn.us/t/o7h3
: 532639 539650 548289 552431 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-01-29 13:18 PST by Mark Banner (:standard8)
Modified: 2010-03-18 06:40 PDT (History)
18 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
beta2+
beta2-fixed
.4+
.4-fixed


Attachments
The fix (8.30 KB, patch)
2010-03-16 14:22 PDT, Mark Banner (:standard8)
mozilla: review+
mozilla: superreview+
standard8: approval‑thunderbird3.0.4+
Details | Diff | Review

Description Mark Banner (:standard8) 2010-01-29 13:18:37 PST
This is a regression from Thunderbird 2.

In Thunderbird 2 for cards that contained both an email address ('primary') and an additional email address, the primary email address would always be listed first.

In Thunderbird 3, primary and additional are sorted alphabetically.


This bug will fix this one clear regression. Please do not suggest other sort orders/options/bugs here, but file them in separate bugs.
Comment 1 Mark Banner (:standard8) 2010-01-29 13:21:51 PST
*** Bug 539650 has been marked as a duplicate of this bug. ***
Comment 2 Mark Banner (:standard8) 2010-02-16 07:17:22 PST
*** Bug 532639 has been marked as a duplicate of this bug. ***
Comment 3 Grzegorz Dubicki 2010-02-16 10:34:41 PST
Am I seeing correctly that this is planned for TB 3.0.3+ and not 3.0.2?
Comment 4 Mark Banner (:standard8) 2010-02-16 10:48:43 PST
(In reply to comment #3)
> Am I seeing correctly that this is planned for TB 3.0.3+ and not 3.0.2?

Yes.
Comment 5 Peter Lairo 2010-02-17 10:53:35 PST
Requesting "blocking1.9.0.18" because the "wanted" items are grayed out.
Comment 6 Mark Banner (:standard8) 2010-02-17 11:15:36 PST
(In reply to comment #5)
> Requesting "blocking1.9.0.18" because the "wanted" items are grayed out.

The fact that it is blocking-thunderbird3.0 is enough of a flag, you don't need wanted as well.
Comment 7 Peter Lairo 2010-02-17 11:59:08 PST
(In reply to comment #6)
> The fact that it is blocking-thunderbird3.0 is enough of a flag

I thought that flag was outdated because "3.0" is already out the door. Perhaps it should say "3.0.x". Apologies for not reading the "runes" correctly. ;-)

BTW: What does ".3+" mean (after blocking-thunderbird3.0)? Zero point three plus? Partially (a third) blocking? I only knew ?, +, and - as entries.
Comment 8 Mark Banner (:standard8) 2010-02-17 13:00:41 PST
(In reply to comment #7)
> BTW: What does ".3+" mean (after blocking-thunderbird3.0)? Zero point three
> plus? Partially (a third) blocking? I only knew ?, +, and - as entries.

See https://wiki.mozilla.org/Thunderbird/Release_Driving/Flags and if you have any more questions please ask on mdat.
Comment 9 Mark Banner (:standard8) 2010-02-24 09:51:44 PST
*** Bug 548289 has been marked as a duplicate of this bug. ***
Comment 10 Russell East 2010-02-27 18:13:53 PST
Actually, I would be perfectly happy if the Secondary address got listed first, if and only if *it is the address that I send mail to most frequently*.   In other words, I don't think it makes sense to *always* put the primary address first.   By the same token, it doesn't make sense to sort them alphabetically as appears to be the case now.  Frequency of usage is much more important regardless of Primary or Secondary status.
Comment 11 Matt Krause 2010-02-28 08:05:59 PST
I still support that the Primary address should be presented first.
I made a decision that this is the default order I wanted, as I added my email addresses to the address book.

I also see that this change will not appear until TB 3.0.3+. :-(

I got fooled into TB 3.0.1 and have returned (with effort)to 2.0.0.23
I'll be cautious before I make that move again!
Comment 12 Robert Goldman 2010-02-28 08:24:10 PST
(In reply to comment #11)
> I still support that the Primary address should be presented first.
> I made a decision that this is the default order I wanted, as I added my email
> addresses to the address book.

Seconded.  The meaning of "primary" is, well... primary.  It shouldn't be sorted below additional unless you have good evidence for doing this.

I'd be OK with having evidence overwhelm the express preference for the primary address, but the assignment of one address as primary /is/ an expressed preference, and I don't think we should run roughshod over it.
Comment 13 Peter Lairo 2010-02-28 09:20:15 PST
(In reply to comment #12)
> I don't think we should run roughshod over it.

Respecting the *frequency* with which the users *actually* use the address is hardly "running roughshod" over their choice (that they made once long ago).

Also, since Thunderbird's address book is so <polite>limited</polite>, perhaps most user's "primary" entry is simply the *first* e-mail they entered for that person.
Comment 14 Robert Goldman 2010-03-01 04:03:30 PST
(In reply to comment #13)
> (In reply to comment #12)
> > I don't think we should run roughshod over it.
> 
> Respecting the *frequency* with which the users *actually* use the address is
> hardly "running roughshod" over their choice (that they made once long ago).
> 
> Also, since Thunderbird's address book is so <polite>limited</polite>, perhaps
> most user's "primary" entry is simply the *first* e-mail they entered for that
> person.

With all due respect, you are misreading me.  After upgrade to TB 3, as far as I can tell, TB is doing nothing with EITHER my expressed preference by means of primary and additional email addresses OR any experience.

All I am getting now is alphabetized completion.  This is, for me, almost always exactly the wrong thing.  Here is what goes wrong:  

1.  I want to send one of my colleagues mail.
2.  My colleague has both a gmail address and an address at my company, whose name begins with "S"
3.  TB gives me the gmail address first (I have it because of google talk), although it is carefully NOT the primary address.
4.  Unless I am careful, information leaks out of my company and into Google, where I don't want it to go.  Also, my colleagues typically use Google just for IM, so they don't see these messages.

I DID think carefully about what address should be primary, and I DO regard ignoring this in favor of alphabetical order as running roughshod over my express preference.

I'm not asking for this to be enshrined forever --- if TB wants to learn from actual behavior, that's fine with me.  It will learn that I obey the primary/additional email distinction and you don't, and we both win.

But if TB is going on no information, I would very much prefer the main email address to be sorted first, instead of having alphabetical order.
Comment 15 Marcus Rademacher 2010-03-08 07:03:10 PST
I have to agree with Robert Goldman.

I see that this moved from 3.0.3 to 3.0.4. Any reason why it was de-prioritized?
Comment 16 Jim Porter (:squib) 2010-03-08 14:27:42 PST
(In reply to comment #15)
> I see that this moved from 3.0.3 to 3.0.4. Any reason why it was
> de-prioritized?

3.0.3 was already released and had a single (important) bugfix.
Comment 17 [:Aureliano Buendía] 2010-03-15 09:12:30 PDT
*** Bug 552431 has been marked as a duplicate of this bug. ***
Comment 18 maarten.bodewes 2010-03-15 14:33:21 PDT
Uh, sorry for the dupe, I did try and find if there was another bug out there. I might have depended on Google for that a tad too much.

I too have to agree with Robert Goldman. Voted in favor of solving this bug.

If you need me for testing or development please let me know (although my prime interest is in Java/security/cryptography).
Comment 19 Mark Banner (:standard8) 2010-03-16 14:22:56 PDT
Created attachment 432916 [details] [diff] [review]
The fix

This should fix the issue. It adapts the sorting algorithm so that it knows about primary and secondary email addresses and takes appropraite action.

Patch includes unit tests for some of the cases I thought of.
Comment 20 David :Bienvenu 2010-03-16 17:44:28 PDT
Comment on attachment 432916 [details] [diff] [review]
The fix

this works - I had some confusion because my test primary address turned out to be in 3 separate address books, but once I cleared that up, the patch worked fine.
Comment 21 Mark Banner (:standard8) 2010-03-17 01:06:58 PDT
Comment on attachment 432916 [details] [diff] [review]
The fix

a=Standard8 for low-medium risk change to code which is well tested with existing unit tests.

Note You need to log in before you can comment on or make changes to this bug.