I’ve downloaded an entire “All Mail” folder for a gmail account using IMAP to a locally running Thunderbird v136.0.1 desktop client. Global search works, but it fails to find some messages that are easily found in a folder-specific search. This All Mail folder has 165,881 messages, but the activity manager shows “Indexed 73955 messages…” after a full rebuild, I think meaning that indexing finished and it only indexed some of those 165,881 messages. Why doesn’t it index all of them? I’m not getting any errors, although I haven’t enabled any special logging and I don’t have anything open except the main email window view and the activity manager. Is there some limit on how big global-messages-db.sqlite can be (mine is 468MiB), how many messages can be processed, or something like that?

Possibly related: https://bugzilla.mozilla.org/show_bug.cgi?id=1813306