From a9953eaa92667a99497af7db6f8523db45817efc Mon Sep 17 00:00:00 2001 From: Tomi Ollila Date: Mon, 1 Sep 2014 10:48:30 +0300 Subject: [PATCH] Re: How to debug 'ignoring non-mail file' issues --- 44/5784ba8b49b8be7184817d021173312b1113b2 | 96 +++++++++++++++++++++++ 1 file changed, 96 insertions(+) create mode 100644 44/5784ba8b49b8be7184817d021173312b1113b2 diff --git a/44/5784ba8b49b8be7184817d021173312b1113b2 b/44/5784ba8b49b8be7184817d021173312b1113b2 new file mode 100644 index 000000000..1284f03f7 --- /dev/null +++ b/44/5784ba8b49b8be7184817d021173312b1113b2 @@ -0,0 +1,96 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by olra.theworths.org (Postfix) with ESMTP id 56853431FC4 + for ; Mon, 1 Sep 2014 00:48:58 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: 0 +X-Spam-Level: +X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] + autolearn=disabled +Received: from olra.theworths.org ([127.0.0.1]) + by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id DdGkjz27equJ for ; + Mon, 1 Sep 2014 00:48:47 -0700 (PDT) +Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34]) + by olra.theworths.org (Postfix) with ESMTP id 9E89E431FAE + for ; Mon, 1 Sep 2014 00:48:47 -0700 (PDT) +Received: from guru.guru-group.fi (localhost [IPv6:::1]) + by guru.guru-group.fi (Postfix) with ESMTP id 0BE14100090; + Mon, 1 Sep 2014 10:48:31 +0300 (EEST) +From: Tomi Ollila +To: Perttu Luukko , David Bremner +Subject: Re: How to debug 'ignoring non-mail file' issues +In-Reply-To: <20140901065220.GB3901@lakka.kapsi.fi> +References: <20140831074059.GA13399@rakuuna.dhcp.inet.fi> + <87tx4ssoux.fsf@maritornes.cs.unb.ca> + <20140901065220.GB3901@lakka.kapsi.fi> +User-Agent: Notmuch/0.18.1+76~g581776d (http://notmuchmail.org) Emacs/24.3.1 + (x86_64-unknown-linux-gnu) +X-Face: HhBM'cA~ +MIME-Version: 1.0 +Content-Type: text/plain +Cc: notmuch@notmuchmail.org +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.13 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Mon, 01 Sep 2014 07:48:58 -0000 + +On Mon, Sep 01 2014, Perttu Luukko wrote: + +> On 2014-08-31 07:41:42, David Bremner wrote: +>> Perttu Luukko writes: +>> > The vast majority of these ignored mails are not ignored after I +>> > transfer them with offlineimap to another computer. I can non-ignore +>> > these files probably by copying the renamed file back to the mail +>> > server, so this is fixable. Offlineimap shouldn't mess with the file's +>> > contents, so is there something that can cause notmuch to ignore a file +>> > based on its name? +>> +>> The most likely cause is that the files are mboxes, whether intentional +>> or not. In particular if they start with a "From " (note the lack of :) +>> and contain a second "From " at the beginning of a line later in the +>> file. In this case something like sed can replace the initial +>> "From " with "X-Envelope-From: ". +>> +>> I agree that the error message could be more informative in this case. +> +> No, the mails do contain "From: " with the appropriate colon. If I +> understood correctly notmuch returns the same "not mail" return code + +The question here is whether the very first line of the mail file begins +with 'From ', not whether *any* of the actual header line starts with 'From: ' +IIRC the mails get accepted even the 'From:' header were missing... + +> both when the essential headers are missing (so the file probably really +> isn't mail) and when GMime fails to parse the message. I think it would +> be a good idea to give a different warning in the latter case. + +Sure... :D + +> +> If the files really are ignored because of GMime it also explains why so +> much more files are ignored on my mail provider's server than on my +> laptop. The server probably has an older version of GMime. I'll upgrade +> and see if that makes a difference. +> +> -- +> Perttu + + +Tomi -- 2.26.2