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 033DA429E25 for ; Fri, 4 Nov 2011 13:45:31 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0.502 X-Spam-Level: X-Spam-Status: No, score=0.502 tagged_above=-999 required=5 tests=[DKIM_ADSP_CUSTOM_MED=0.001, FREEMAIL_FROM=0.001, NML_ADSP_CUSTOM_MED=1.2, RCVD_IN_DNSWL_LOW=-0.7] 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 CvucGfEcX+Zi for ; Fri, 4 Nov 2011 13:45:29 -0700 (PDT) X-Greylist: delayed 532 seconds by postgrey-1.32 at olra; Fri, 04 Nov 2011 13:45:29 PDT Received: from vs12.mail.saunalahti.fi (vs12.mail.saunalahti.fi [195.197.172.107]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id 25393431FB6 for ; Fri, 4 Nov 2011 13:45:29 -0700 (PDT) Received: from vams (localhost [127.0.0.1]) by vs12.mail.saunalahti.fi (Postfix) with SMTP id 6F10324007D; Fri, 4 Nov 2011 22:36:32 +0200 (EET) Received: from gw02.mail.saunalahti.fi (gw02.mail.saunalahti.fi [195.197.172.116]) by vs12.mail.saunalahti.fi (Postfix) with ESMTP id 4A31E24007D; Fri, 4 Nov 2011 22:36:32 +0200 (EET) Received: from cthulhu.djcbsoftware.djcbsoftware.nl (a88-112-255-94.elisa-laajakaista.fi [88.112.255.94]) (using SSLv3 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by gw02.mail.saunalahti.fi (Postfix) with ESMTP id D93DE139C69; Fri, 4 Nov 2011 22:36:28 +0200 (EET) From: Dirk-Jan C. Binnema To: Florian Friesdorf , Austin Clements Subject: Re: Re: thread ordering based on references and/or in-reply-to References: <87y5w0bvzn.fsf@eve.chaoflow.net>, User-agent: mu 0.98pre; emacs 24.0.91.1 In-reply-to: Date: Fri, 04 Nov 2011 22:36:15 +0200 Message-ID: <8762izbp6o.fsf@cthulhu.djcbsoftware> 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 Reply-To: djcb@djcbsoftware.nl List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 04 Nov 2011 20:45:31 -0000 On Wed 02 Nov 2011 04:37:05 PM EET, Austin Clements wrote: > On Mon, Oct 31, 2011 at 7:07 PM, Florian Friesdorf wrote: > > > > Hi, > > > > I'm looking into taking the References header into account for thread > > ordering. So far only In-Reply-To is used. My C/C++ is rusty at best, so > > I'd need some help to get this done. > I know this came up on IRC, but have you looked at jwz's threading > algorithm (http://www.jwz.org/doc/threading.html)? Carl mentioned > that notmuch already implements it (except for subject matching), but > notmuch only implements the subset of it necessary to group messages > into threads without structure. Much of the algorithm is devoted to > exactly this problem of piecing together the thread structure based on > all of the information in both In-Reply-To and References. The > algorithm as described combines the issues of grouping and structuring > since it's expecting a giant pile of mail as input, but there's no > reason these can't be teased apart. I've implemented it for mu[1], maybe some of it can be reusable for notmuch; see mu-threader.[ch] and mu-container.[ch] in http://gitorious.org/mu/mu/blobs/master/src/ (starting point is mu_threader_calculate). I didn't implement subject matching yet, but it does build the hierarchy as per JWZ and "References:". Best wishes, Dirk. -- Dirk-Jan C. Binnema Helsinki, Finland e:djcb@djcbsoftware.nl w:www.djcbsoftware.nl pgp: D09C E664 897D 7D39 5047 A178 E96A C7A1 017D DA3C