Re: Bug?: notmuch-search-show-thread shows several threads; only one containing match...
authorGregor Zattler <telegraph@gmx.net>
Sun, 29 Jan 2012 23:36:33 +0000 (00:36 +0100)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:43:32 +0000 (09:43 -0800)
cd/d9b07526ba55d27d2dd4325fad025c6a012653 [new file with mode: 0644]

diff --git a/cd/d9b07526ba55d27d2dd4325fad025c6a012653 b/cd/d9b07526ba55d27d2dd4325fad025c6a012653
new file mode 100644 (file)
index 0000000..8a32f22
--- /dev/null
@@ -0,0 +1,163 @@
+Return-Path: <error4me@gmx.de>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 010B7429E5A\r
+       for <notmuch@notmuchmail.org>; Sun, 29 Jan 2012 15:37:11 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0.001\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0.001 tagged_above=-999 required=5\r
+       tests=[FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001]\r
+       autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id K++R30ODmEJB for <notmuch@notmuchmail.org>;\r
+       Sun, 29 Jan 2012 15:37:10 -0800 (PST)\r
+Received: from mailout-de.gmx.net (mailout-de.gmx.net [213.165.64.23])\r
+       by olra.theworths.org (Postfix) with SMTP id DF245429E59\r
+       for <notmuch@notmuchmail.org>; Sun, 29 Jan 2012 15:37:09 -0800 (PST)\r
+Received: (qmail invoked by alias); 29 Jan 2012 23:37:08 -0000\r
+Received: from p54BE4D91.dip.t-dialin.net (EHLO shi.workgroup) [84.190.77.145]\r
+       by mail.gmx.net (mp071) with SMTP; 30 Jan 2012 00:37:08 +0100\r
+X-Authenticated: #19296480\r
+X-Provags-ID: V01U2FsdGVkX18UvQQtU2kU8SSivHgppYytjBUD56WUOQ0/VQRARP\r
+       n/l78HWm61R21w\r
+Received: from grfz by shi.workgroup with local (Exim 4.77)\r
+       (envelope-from <error4me@gmx.de>)\r
+       id 1RreIn-0008Fm-Qi; Mon, 30 Jan 2012 00:36:53 +0100\r
+Date: Mon, 30 Jan 2012 00:36:33 +0100\r
+From: Gregor Zattler <telegraph@gmx.net>\r
+To: notmuch <notmuch@notmuchmail.org>\r
+Subject: Re: Bug?: notmuch-search-show-thread shows several threads; only one\r
+       containing matching messages\r
+Message-ID: <20120129233633.GA11460@shi.workgroup>\r
+Mail-Followup-To: notmuch <notmuch@notmuchmail.org>\r
+References: <20120126004024.GA13704@shi.workgroup>\r
+       <20120126011903.GA1176@mit.edu>\r
+       <8762fzry7k.fsf@servo.finestructure.net>\r
+       <20120126124450.GB30209@shi.workgroup> <87mx9aioxm.fsf@nikula.org>\r
+MIME-Version: 1.0\r
+Content-Type: text/plain; charset=us-ascii\r
+Content-Disposition: inline\r
+In-Reply-To: <87mx9aioxm.fsf@nikula.org>\r
+User-Agent: Mutt/1.5.21 (2010-09-15)\r
+X-Y-GMX-Trusted: 0\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Sun, 29 Jan 2012 23:37:11 -0000\r
+\r
+Hi Jani, notmuch developers,\r
+\r
+executive summary: notmuch almangamates several e-mail threads\r
+into one notmuch-thread, I consider this a bug:\r
+\r
+* Jani Nikula <jani@nikula.org> [26. Jan. 2012]:\r
+> On Thu, 26 Jan 2012 13:44:50 +0100, Gregor Zattler <telegraph@gmx.net> wrote:\r
+>> * Jameson Graef Rollins <jrollins@finestructure.net> [25. Jan. 2012]:\r
+>>> On Wed, 25 Jan 2012 20:19:03 -0500, Austin Clements <amdragon@MIT.EDU> wrote:\r
+>>>> One very common cause of this is someone using "reply" to get an\r
+>>>> initial set of recipients, but then replacing the entire message and\r
+>>>> subject (presumably without realizing that the mail is still tracking\r
+>>>> what it was a reply to).  This can also happen if someone\r
+>>>> intentionally replies to multiple messages (though few mail clients\r
+>>>> support this), or if there was a message ID collision.\r
+>>> \r
+>>> This is a very common occurrence for me as well.  I would put money down\r
+>>> that this is what you're seeing.\r
+>> \r
+>> I thought about this too and this is why I checked for any\r
+>> occurrence of Message-IDs in the other emails: \r
+>> \r
+>>    |> I isolated the thread I was interested in,\r
+>>    |> extracted the message ids of its messages and greped the rest of\r
+>>    |> the messages for this message ids: no matches.[2] Therefore no of\r
+>>    |> the rests messages are part of the thread I was interested in\r
+>> \r
+>> perhaps there was a logic error in how I did this:\r
+>> \r
+>>    |> [2] grep -I "^Message-Id:" /tmp/thread-I-m-interested-in.mbox |sed -e "s/Message-Id: <//I" -e "s/>$//" >really.mid\r
+>>    |>     grep -I -F really.mid rest.mbox\r
+>>    |>     --> no match\r
+>> /tmp/thread-I-m-interested-in.mbox  is a mbox with messages\r
+>> I'minterested in, the "real" ones.  really.mid is a list of\r
+>> Message-IDs of these "real" emails.  rest.mbox is a mbox with the\r
+>> other emails, Emacs showed in his notmuch show buffer but are\r
+>> other threads.\r
+>> \r
+>> Since there is no match I concluded, the threads are not linked.\r
+>> Perhaps I made a mistake.  I'l retest it and report again.  But\r
+>> right now I don't have the time to do this.\r
+\r
+I re-did it.  This time I used the Emacs interface, searched for\r
+folder:orgmode date 64 bit 32 \r
+and in the notmuch-search -buffer I used notmuch-search-stash-thread-id to\r
+get the internal thread-number.  I then did a\r
+\r
+notmuch show --format=mbox thread:00000000000108e0 >thread.mbox\r
+\r
+opened this mbox with mutt, saved the one thread about dates\r
+before 1970 in one maildir\r
+`date64bit32-I-am-interested-in.mailbox' and the rest in a\r
+maildir `other-e-mails.mailbox'.\r
+\r
+I produced a list of all Message-Ids of the interesting thread by\r
+doing\r
+\r
+rgrep -E -i "^Message-Id:[[:space:]]" date64bit32-I-am-interested-in.mailbox|egrep -o "[^<]+@[^>]+" >date64bit32-I-am-interested-in.mid\r
+\r
+and searched for this strings in the other e-mails:\r
+\r
+rgrep -F date64bit32-I-am-interested-in.mid other-e-mails.mailbox\r
+\r
+No hits.\r
+\r
+I also did it the other way around:\r
+\r
+rgrep -E -i "^Message-Id:[[:space:]]" other-e-mails.mailbox|egrep -o "[^<]+@[^>]+" >other-e-mails.mid\r
+\r
+rgrep -F other-e-mails.mid date64bit32-I-am-interested-in.mailbox\r
+\r
+No hits.\r
+\r
+(I spared me the hassle to search for the Message-Ids in correct\r
+headers only, there are simply no hits anywhere in this other e-mails.\r
+\r
+Thus I conclude that notmuch amalgamates different e-mail-threads\r
+into one as represented by one thread-id.\r
+\r
+I consider this a bug.\r
+\r
+If anybody is interested I can email her/him the mbox file with\r
+the relevant thread (minus privacy relevant headers / 300 KiB gzipped).\r
+\r
+> Do you have an mbox file in the maildir indexed by notmuch? That seems\r
+> like the issue.\r
+\r
+I don't think so:  I rgreped for files with more than 1 line\r
+beginning with "Message-Id".  I got 38 hits.  I looked at all of\r
+them, they are no mbox files (at least no valid ones) but e-mails\r
+with other e-mails attached, or cited or in one case a\r
+multipart/mixed message with plain text part and html part.\r
+\r
+Nonetheless I isolated all Message-Ids from these 38 files,\r
+eliminated some html artefacts and greped for this in\r
+date64bit32-I-am-interested-in.mailbox and other-e-mails.mailbox:\r
+No hits with either file.  I also did it the other way around:\r
+Searching for the Message-ids of the two sets in the 38 potential\r
+mbox files: No hit.\r
+\r
+Ciao, Gregor\r
+-- \r
+ -... --- .-. . -.. ..--.. ...-.-\r