From fc57da42799f2e9cde69b46e01ce9df743e6c328 Mon Sep 17 00:00:00 2001 From: Austin Clements Date: Tue, 25 Jun 2013 18:43:41 +2000 Subject: [PATCH] Re: [PATCH 2/2] notmuch.el:notmuch-search-process-filter: Rewritten. Cope with incomplete lines. --- ff/018e119728390282a76bd1b4f061a1c4af4704 | 114 ++++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 ff/018e119728390282a76bd1b4f061a1c4af4704 diff --git a/ff/018e119728390282a76bd1b4f061a1c4af4704 b/ff/018e119728390282a76bd1b4f061a1c4af4704 new file mode 100644 index 000000000..6c3245b8e --- /dev/null +++ b/ff/018e119728390282a76bd1b4f061a1c4af4704 @@ -0,0 +1,114 @@ +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 CDA88431FBD + for ; Mon, 24 Jun 2013 15:43:53 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: -0.7 +X-Spam-Level: +X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5 + tests=[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 TdXhhqYUTCs4 for ; + Mon, 24 Jun 2013 15:43:48 -0700 (PDT) +Received: from dmz-mailsec-scanner-7.mit.edu (dmz-mailsec-scanner-7.mit.edu + [18.7.68.36]) + by olra.theworths.org (Postfix) with ESMTP id 985D7431FB6 + for ; Mon, 24 Jun 2013 15:43:48 -0700 (PDT) +X-AuditID: 12074424-b7f228e00000096b-2f-51c8cba22d0f +Received: from mailhub-auth-2.mit.edu ( [18.7.62.36]) + by dmz-mailsec-scanner-7.mit.edu (Symantec Messaging Gateway) with SMTP + id 85.31.02411.2ABC8C15; Mon, 24 Jun 2013 18:43:46 -0400 (EDT) +Received: from outgoing.mit.edu (outgoing-auth-1.mit.edu [18.9.28.11]) + by mailhub-auth-2.mit.edu (8.13.8/8.9.2) with ESMTP id r5OMhiEg018197; + Mon, 24 Jun 2013 18:43:45 -0400 +Received: from awakening.csail.mit.edu (awakening.csail.mit.edu [18.26.4.91]) + (authenticated bits=0) + (User authenticated as amdragon@ATHENA.MIT.EDU) + by outgoing.mit.edu (8.13.8/8.12.4) with ESMTP id r5OMhgBJ028802 + (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); + Mon, 24 Jun 2013 18:43:44 -0400 +Received: from amthrax by awakening.csail.mit.edu with local (Exim 4.80) + (envelope-from ) + id 1UrFU6-0005Ik-Em; Mon, 24 Jun 2013 18:43:42 -0400 +From: Austin Clements +To: Thomas Schwinge , Carl Worth , + notmuch@notmuchmail.org +Subject: Re: [PATCH 2/2] notmuch.el:notmuch-search-process-filter: Rewritten. + Cope with incomplete lines. +In-Reply-To: <87pqgtmxfi.fsf@kepler.schwinge.homeip.net> +References: <87zkqeiffj.fsf@kepler.schwinge.homeip.net> + <1296690999-16542-3-git-send-email-thomas@schwinge.name> + <87r5ae8lem.fsf@yoom.home.cworth.org> + <87pqgtmxfi.fsf@kepler.schwinge.homeip.net> +User-Agent: Notmuch/0.15.2+182~gd0bd88f (http://notmuchmail.org) Emacs/23.4.1 + (i486-pc-linux-gnu) +Date: Mon, 24 Jun 2013 18:43:41 -0400 +Message-ID: <87d2rbyvs2.fsf@awakening.csail.mit.edu> +MIME-Version: 1.0 +Content-Type: text/plain; charset=us-ascii +X-Brightmail-Tracker: + H4sIAAAAAAAAA+NgFnrNIsWRmVeSWpSXmKPExsUixG6norvo9IlAg7PrtSxu/pzDZnH95kxm + i8ZXnxkdmD12b37A4vFs1S1mj3d7p7MEMEdx2aSk5mSWpRbp2yVwZXTvlC54wF2xfNE+xgbG + dZxdjJwcEgImEvuf7WeHsMUkLtxbz9bFyMUhJLCPUeJy9xFGCGcjo8SsXc9YIJzTTBKTe/cx + QzhLGCWu7l3BCtLPJqAhsW3/ckYQW0QgR+Lat2VsILawQKbEua8LgWwODk4BC4lb55Mgeg8x + SuzYNRWsV1QgUWLSgk5mEJtFQFXi3I8DYDfxAt33fsECVghbUOLkzCcsIDazgJbEjX8vmSYw + CsxCkpqFJLWAkWkVo2xKbpVubmJmTnFqsm5xcmJeXmqRrrlebmaJXmpK6SZGcJi6qOxgbD6k + dIhRgINRiYd3RsyJQCHWxLLiytxDjJIcTEqivJNPAIX4kvJTKjMSizPii0pzUouBrudgVhLh + DRUByvGmJFZWpRblw6SkOViUxHnFbu0MFBJITyxJzU5NLUgtgsnKcHAoSfB2ngJqFCxKTU+t + SMvMKUFIM3FwggznARreB1LDW1yQmFucmQ6RP8WoKCXOOxEkIQCSyCjNg+uFpZFXjOJArwjz + FoBU8QBTEFz3K6DBTECDJ6ceBxlckoiQkmpg5GZ5L3xUbxrXhaZNetr++SlxQkpCWTGi+5Z9 + rd/pJ+me6nC+Yd2U2AyJtolf9CbZdnGnZxjHb/UxDm95r8P7M1ze/Du/bsHdHe5uE3O/f76V + s/DAIkbDd5krjf96RfCtPS4zc5r8AdG3ofP3WM1+ui/ys2191YkdxmvCvmquXPzLeUNV9Sd7 + JZbijERDLeai4kQAlAFwcf4CAAA= +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, 24 Jun 2013 22:43:53 -0000 + +On Tue, 15 Nov 2011, Thomas Schwinge wrote: +> Hi! +> +> On Thu, 10 Mar 2011 18:02:09 -0800, Carl Worth wrote: +>> On Thu, 3 Feb 2011 00:56:39 +0100, Thomas Schwinge wrote: +>> > This issue has been lying in ambush as of 2009-11-24's commit +>> > 93af7b574598637c2766dd1f8ef343962c9a8efb. +>> +>> Thanks very much for tracking down this bug, Thomas. What a nasty bug to +>> have in notmuch! +>> +>> Your fix seems to drop the last thread from the search results +>> view. I've now committed a slightly modified fix that avoids that +>> problem. I also made the test case provide slightly cleaner results. +>> +>> Let me know if you see any problems. +> +> That is much better, thanks! +> +> But we're not there yet... %-| That is, today I hit another issue that +> appears to hide in the same elisp code. See ``Error: Unexpected output +> From notmuch search''. (And, thanks to eBay for long subject lines...) +> +> Unfortunately I'm totally out of time at the moment (final month of +> writing and wrapping up my diploma thesis), so I'm just dumping my state +> here, for now. + +*snip* + +I happened to notice that this is still marked as a bug. I'm marking it +as fixed. This code was completely rewritten to use the streaming JSON +parser (and now the streaming S-expression parser) and there's now a +test that feeds the process filter the search data one character at a +time to catch these sorts of buffer boundary bugs. -- 2.26.2