notmuch ignoring alot of emails

Alvaro Herrera alvherre at
Fri Jun 28 13:11:21 PDT 2019

On 2019-Jun-28, Alvaro Herrera wrote:

> I think a real solution is to parse the message header, look for the
> Content-Length, and determine mbox-ness by looking for "From" only past
> that many bytes; that seems to match what other mail parsing tools do.

Sorry, I misspoke: there's no such thing as Content-Length.
It's Content-Type/boundary that needs to be watched for.  Only consider
that the file is an mbox if a "^From " line appears after the boundary
end marker (which seems to be defined as "the boundary string followed
by two dashes --").

Here's a sample message, BTW:
(username "archives", password "antispam").

Álvaro Herrera       Valdivia, Chile

More information about the notmuch mailing list