Betterbird / thunderbird-patches

Betterbird is a fork of Mozilla Thunderbird. Here are the patches that provide all the goodness.
Other
424 stars 18 forks source link

Global search results incorrectly set recipient name (give that of 1st account) for incoming mails (but correct when results as a list) #295

Closed mmtsuchi closed 2 months ago

mmtsuchi commented 2 months ago

In Betterbird Version 115.10.0-bb27 (Identifiant de compilation 20240417184732), global search gives incorrect recipient name for incoming messages in search results.

Whereas when you clink on the link to show results as a list, recipient names are correct.

To be exact, it provides the recipient name of the 1st account set up in betterbird.

This bug seems to affect only incoming mails results.

Betterbird commented 2 months ago

We're not aware of changes in this area. How does TB behave? Can you post a screenshot?

mmtsuchi commented 2 months ago

Suppl. information : linux_archive fr version Agent utilisateur Mozilla/5.0 (X11; Linux x86_64; rv:115.0) Gecko/20100101 Thunderbird/115.10.0 Système d’exploitation Linux 5.15.0-105-generic #115-Ubuntu SMP Mon Apr 15 09:52:04 UTC 2024

Here screen captures : I altered screen captures for privacy

global search results betterbird-115_bug295_search_results

global search results as a list betterbird-115_bug295_search_results_as_a_list

This doesn't exist in Thunderbird: thunderbird-115_search_results

Notice that search results and "search results as a list" are slightly in different order when sorted by date because of same received date and different between Betterbird and thunderbird.

mmtsuchi commented 2 months ago

same bug in linux betterbird-115 FR and US

Betterbird commented 2 months ago

Are you running TB and BB on the same profile?

Other than that, I can't reproduce the problem, I get the correct recipient displayed:

image

or

image

If you're running TB and BB on different profiles, run them on the same profile and compare the results. You can try to rebuild the index by deleting global-messages-db.sqlite.

No current TB or BB developer understands the global search and indexer, so there is little chance to fix this, especially since it's not easily reproducible.

mmtsuchi commented 2 months ago

Just deleted global-messages-db.sqlite on profile in use. Wainting for index to be rebuild. ==> Same results.

Notice also that it affects receiver and sender names in results (see my 1st screen capture).

My TB and BB use different profiles... BUT : when in TB, I want to use the BB profile (thunderbird -P) I get : console.error: (new UnknownError("IndexedDB: thunderbird/url-classifier-skip-urls getLastModified() IndexedDB: The operation failed for reasons unrelated to the database itself and not covered by any other error code.", "resource://services-settings/IDBHelpers.jsm", 18))

Betterbird commented 2 months ago

Sorry, but this is becoming more and more of a support case. The error you mentioned is this: https://searchfox.org/mozilla-central/rev/b41bb321fe4bd7d03926083698ac498ebec0accf/dom/base/domerr.msg#50 and it's totally unrelated to TB/BB.

Please get in touch with our support.

Since you've rebuilt the index on the "broken" profile, someone will need to investigate why the recipient is picked up as yandex@something when in fact it should be someone@gmail.com.

mmtsuchi commented 2 months ago

Maybe I find something weird in global-messages-db.sqlite Looking at this file in sqlitebrowser, I see: In identities table, it uses the same "contactID" for the first 9 "IDs", with different "values" (=email address) BB-115_bug295 global-messages-db identities

Betterbird commented 2 months ago

And ID means "identifier" 🤣.

Looking for that string: https://searchfox.org/comm-central/search?q=contactID&path=&case=false&regexp=false

If it weren't your own identities, I would have said that it's possible that something has gone wrong in an address book.

I looked in the identity table in one of my production profiles and the contactIDs appear to be unique.

mmtsuchi commented 2 months ago

I see 2 "ID" with same "contactID" (=1) in global-messages-db.sqlite of an other profile handled by ThunderBird-115. But I didn't catch it when I use global search = we don't very look at sender and receiver when we are viewing results.

Betterbird commented 2 months ago

There seems to be a bug in TB's Gloda (Glo-bal Da-tabase) which leads to this. Likely triggered by some unforeseen data. Just one of the 15.000+ TB bugs.