This particular bug is apparently caused by the malformed (according to RFC5822 section 3.6.4) In-reply-to field of id:5422.1299798...@alphaville.usa.hp.com. --- test/T265-thread-fusing.sh | 21 ++++ .../cur/1397885606.000217.mbox:2,S | 67 +++++++++++ .../cur/1397885606.000218.mbox:2, | 67 +++++++++++ .../cur/1397885606.000232.mbox:2,S | 105 ++++++++++++++++++ 4 files changed, 260 insertions(+) create mode 100755 test/T265-thread-fusing.sh create mode 100644 test/corpora/threading/thread-fusing/cur/1397885606.000217.mbox:2,S create mode 100644 test/corpora/threading/thread-fusing/cur/1397885606.000218.mbox:2, create mode 100644 test/corpora/threading/thread-fusing/cur/1397885606.000232.mbox:2,S
diff --git a/test/T265-thread-fusing.sh b/test/T265-thread-fusing.sh new file mode 100755 index 00000000..057f961a --- /dev/null +++ b/test/T265-thread-fusing.sh @@ -0,0 +1,21 @@ +#!/usr/bin/env bash +test_description="thread fusing" +. $(dirname "$0")/test-lib.sh || exit 1 + +add_email_corpus threading + +test_begin_subtest "all messages are indexed" +notmuch search --output=messages folder:thread-fusing | sort > OUTPUT +cat <<EOF > EXPECTED +id:5422.1299798...@alphaville.usa.hp.com +id:8162.1298993...@alphaville.dokosmarshall.org +id:87wrkidfrh....@pinto.chemeng.ucl.ac.uk +EOF +test_expect_equal_file EXPECTED OUTPUT + +test_begin_subtest "Two threads are detected" +test_subtest_known_broken +output=$(notmuch search to:org-mode | wc -l) +test_expect_equal "${output}" 2 + +test_done diff --git a/test/corpora/threading/thread-fusing/cur/1397885606.000217.mbox:2,S b/test/corpora/threading/thread-fusing/cur/1397885606.000217.mbox:2,S new file mode 100644 index 00000000..02356e0a --- /dev/null +++ b/test/corpora/threading/thread-fusing/cur/1397885606.000217.mbox:2,S @@ -0,0 +1,67 @@ +X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on shi.workgroup +Delivery-date: Tue, 01 Mar 2011 16:45:42 +0100 +Delivered-To: GMX delivery to telegr...@gmx.net +From: Eric S Fraga <e.fr...@ucl.ac.uk> +To: Emacs Org mode mailing list <emacs-orgm...@gnu.org> +User-Agent: Gnus/5.110014 (No Gnus v0.14) Emacs/24.0.50 (gnu/linux) +X-Face: av6A"vZ{AypDB`d^.T35oG%$E*Qh]4F)K=*$-NHz5{7WZfAFQFB]F@gf}l9`XLs9(iD?D/! nafKE,S#G!4W/flj=9(U{]t'lP,,5~:s*~;kKR +Date: Tue, 01 Mar 2011 15:25:38 +0000 +Message-ID: <87wrkidfrh....@pinto.chemeng.ucl.ac.uk> +MIME-Version: 1.0 +Content-Type: text/plain +X-UCL-MailScanner-Information: Please contact the UCL Helpdesk, helpd...@ucl.ac.uk for more information +X-UCL-MailScanner: Found to be clean +X-UCL-MailScanner-From: e.fr...@ucl.ac.uk +X-detected-operating-system: by eggs.gnu.org: Solaris 10 (beta) +X-Received-From: 144.82.108.33 +Subject: [O] [bug] infinite loop exporting to latex with lists +X-BeenThere: emacs-orgm...@gnu.org +X-Mailman-Version: 2.1.5 +Precedence: list +List-Id: "General discussions about Org-mode." <emacs-orgmode.gnu.org> +List-Unsubscribe: <http://lists.gnu.org/mailman/listinfo/emacs-orgmode>, <mailto:emacs-orgmode-requ...@gnu.org?subject=unsubscribe> +List-Archive: <http://lists.gnu.org/archive/html/emacs-orgmode> +List-Post: <mailto:emacs-orgm...@gnu.org> +List-Help: <mailto:emacs-orgmode-requ...@gnu.org?subject=help> +List-Subscribe: <http://lists.gnu.org/mailman/listinfo/emacs-orgmode>, <mailto:emacs-orgmode-requ...@gnu.org?subject=subscribe> +Errors-To: emacs-orgmode-bounces+telegraph=gmx....@gnu.org +X-GMX-Antivirus: 0 (no virus found) +X-GMX-Antispam: 0 (Mail was not recognized as spam); Detail=5D7Q89H36p4WX0t+AtsdW7Rkpq2CocXbjmEjLnML/Jh/D5PE3azF+tWbav9NfRPdBjN7A hu2kMqFTMtXwLrawGj72VauG7H+vnQAR+OuQR9OR0XCVwaIInzy4fEfJqoaNwHPgkYGDpJSbT4Wu eSUcQ==V1; +Status: O +Content-Length: 858 +Lines: 33 + +Content-Length: 837 + +Hello, + +with the following simple file, + +--8<---------------cut here---------------start------------->8--- +* A question + +For this project: + +1. Draw a graph. + + +--8<---------------cut here---------------end--------------->8--- + +I get an infinite loop (i.e. emacs hangs until C-g) when I try to export +this to latex. Using debug on quit, I find it always hangs in +=org-list-context=. Help! + +I cannot think of anything I have changed etc. It only happens where +there is a list and this list can be any length >= 1. + +-- +: Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1 +: using Org-mode version 7.4 (release_7.4.562.gc895) + +_______________________________________________ +Emacs-orgmode mailing list +Please use `Reply All' to send replies to the list. +emacs-orgm...@gnu.org +http://lists.gnu.org/mailman/listinfo/emacs-orgmode + + diff --git a/test/corpora/threading/thread-fusing/cur/1397885606.000218.mbox:2, b/test/corpora/threading/thread-fusing/cur/1397885606.000218.mbox:2, new file mode 100644 index 00000000..afb77619 --- /dev/null +++ b/test/corpora/threading/thread-fusing/cur/1397885606.000218.mbox:2, @@ -0,0 +1,67 @@ +X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on shi.workgroup +Delivery-date: Tue, 01 Mar 2011 16:45:41 +0100 +Delivered-To: GMX delivery to telegr...@gmx.net +To: Eric S Fraga <e.fr...@ucl.ac.uk> +From: Nick Dokos <nicholas.do...@hp.com> +Subject: Re: [O] [bug] infinite loop exporting to latex with lists +In-reply-to: Message from Eric S Fraga <e.fr...@ucl.ac.uk> of "Tue, 01 Mar 2011 15:25:38 GMT." <87wrkidfrh....@pinto.chemeng.ucl.ac.uk> +References: <87wrkidfrh....@pinto.chemeng.ucl.ac.uk> +X-Mailer: MH-E 8.2; nmh 1.3; GNU Emacs 24.0.50 +Date: Tue, 01 Mar 2011 10:37:55 -0500 +Message-id: <8162.1298993...@alphaville.dokosmarshall.org> +X-detected-operating-system: by eggs.gnu.org: Solaris 10 (1203?) +X-Received-From: 206.46.173.1 +Cc: nicholas.do...@hp.com, Emacs Org mode mailing list <emacs-orgm...@gnu.org> +X-BeenThere: emacs-orgm...@gnu.org +X-Mailman-Version: 2.1.5 +Precedence: list +Reply-To: nicholas.do...@hp.com +List-Id: "General discussions about Org-mode." <emacs-orgmode.gnu.org> +List-Unsubscribe: <http://lists.gnu.org/mailman/listinfo/emacs-orgmode>, <mailto:emacs-orgmode-requ...@gnu.org?subject=unsubscribe> +List-Archive: <http://lists.gnu.org/archive/html/emacs-orgmode> +List-Post: <mailto:emacs-orgm...@gnu.org> +List-Help: <mailto:emacs-orgmode-requ...@gnu.org?subject=help> +List-Subscribe: <http://lists.gnu.org/mailman/listinfo/emacs-orgmode>, <mailto:emacs-orgmode-requ...@gnu.org?subject=subscribe> +Errors-To: emacs-orgmode-bounces+telegraph=gmx....@gnu.org +X-GMX-Antivirus: 0 (no virus found) +X-GMX-Antispam: 0 (Mail was not recognized as spam); Detail=5D7Q89H36p4WX0t+AtsdW2ORvUlAfcdSIdQlIL3FTSFQDxQiodii41fjuqHQd8jenp0+N dNY0CcAB8WAv7r3OtvsaDOOiC4T8TWFW3c0h9kbMpE0/ou/MWvK8X//VR9J5RqCotAZER8h4O06e mC19Q==V1; +Status: O +Content-Length: 783 +Lines: 35 + +Content-Length: 762 + +Eric S Fraga <e.fr...@ucl.ac.uk> wrote: + +> Hello, +> +> with the following simple file, +> +> * A question +> +> For this project: +> +> 1. Draw a graph. +> +> +> +> I get an infinite loop (i.e. emacs hangs until C-g) when I try to export +> this to latex. Using debug on quit, I find it always hangs in +> =org-list-context=. Help! +> +> I cannot think of anything I have changed etc. It only happens where +> there is a list and this list can be any length >= 1. +> + +Suvayu reported a hang earlier today and Nicolas pushed a fix - maybe +try pulling latest? + +Nick + +_______________________________________________ +Emacs-orgmode mailing list +Please use `Reply All' to send replies to the list. +emacs-orgm...@gnu.org +http://lists.gnu.org/mailman/listinfo/emacs-orgmode + + diff --git a/test/corpora/threading/thread-fusing/cur/1397885606.000232.mbox:2,S b/test/corpora/threading/thread-fusing/cur/1397885606.000232.mbox:2,S new file mode 100644 index 00000000..b03c0265 --- /dev/null +++ b/test/corpora/threading/thread-fusing/cur/1397885606.000232.mbox:2,S @@ -0,0 +1,105 @@ +X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on shi.workgroup +Delivery-date: Fri, 11 Mar 2011 00:08:47 +0100 +Delivered-To: GMX delivery to telegr...@gmx.net +To: Eric S Fraga <e.fr...@ucl.ac.uk> +From: Nick Dokos <nicholas.do...@hp.com> +Subject: Re: [O] dates before 1970 +In-Reply-To: Message from Eric S Fraga <e.fr...@ucl.ac.uk> of "Thu, 10 Mar 2011 21:00:16 GMT." <87ei6en127....@ucl.ac.uk> +References: <87ei6en127....@ucl.ac.uk> +X-Mailer: MH-E 8.2; nmh 1.3; GNU Emacs 24.0.50 +Date: Thu, 10 Mar 2011 18:06:33 -0500 +Message-ID: <5422.1299798...@alphaville.usa.hp.com> +X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) +X-Received-From: 15.201.24.20 +Cc: nicholas.do...@hp.com, Emacs Org mode mailing list <emacs-orgm...@gnu.org> +X-BeenThere: emacs-orgm...@gnu.org +X-Mailman-Version: 2.1.5 +Precedence: list +Reply-To: nicholas.do...@hp.com +List-Id: "General discussions about Org-mode." <emacs-orgmode.gnu.org> +List-Unsubscribe: <http://lists.gnu.org/mailman/listinfo/emacs-orgmode>, <mailto:emacs-orgmode-requ...@gnu.org?subject=unsubscribe> +List-Archive: <http://lists.gnu.org/archive/html/emacs-orgmode> +List-Post: <mailto:emacs-orgm...@gnu.org> +List-Help: <mailto:emacs-orgmode-requ...@gnu.org?subject=help> +List-Subscribe: <http://lists.gnu.org/mailman/listinfo/emacs-orgmode>, <mailto:emacs-orgmode-requ...@gnu.org?subject=subscribe> +Errors-To: emacs-orgmode-bounces+telegraph=gmx....@gnu.org +X-GMX-Antivirus: 0 (no virus found) +X-GMX-Antispam: 0 (Mail was not recognized as spam); Detail=5D7Q89H36p4U4jfdfC5HDevlx1X2sAZgAaLl3DbFfW0PXxL7WgvovMFXXSEPrACW/b9IW Qp+GhEViZlUW4mdBntgP1X8KwB5tjHCA/yxSZMYzm4ZTjPJ5/Fr7D0QgNt/3lmuFSuOJGxtBQaM0 OMz0Q==V1; +Status: O +Content-Length: 2565 +Lines: 73 + +Content-Length: 2543 + +Eric S Fraga <e.fr...@ucl.ac.uk> wrote: + +> This is a sort of bug report but possibly more a curiosity... +> +> I imagine this has something to do with time 0 in Unix but I cannot seem +> to be able to enter any date earlier than 1 Jan 1970 using C-c! (say). +> However, once I have entered a date (later than that), I can use +> S-<down> on the year to get to the date I want. This seems rather +> inconsistent? +> +> To be precise, I get the wrong date recorded if I try: +> +> C-c ! 1968-12-10 RET +> +> (where C-c ! is =org-time-stamp-inactive=). +> The result is =[2011-12-10 Sat]= +> +> The bug is not so much that I cannot input dates I want but that the +> inactive timestamp generated is *incorrect* and yet there is no error +> message. +> + +Good one! The culprit is org-read-date-analyze which near the end contains +this snippet of code: + +,---- +| ... +| (if (< year 100) (setq year (+ 2000 year))) +| (if (< year 1970) (setq year (nth 5 defdecode))) ; not representable +| (setq org-read-date-analyze-futurep futurep) +| (list second minute hour day month year))) +`---- + +The trouble is that the caller (org-read-date) takes the result and +does a round-trip through the emacs time encode/decode functions to make +sure the result is sane. Dates before 1970 would break that (I get (0 9 +10 26 11 2033 6 nil -18000)) so it seems it wraps around to 2033 or so). + +In addition, most callers of org-read-date call it with a non-nil +to-time argument: that makes it return an emacs-encoded time (which is +then manipulated as such and which I believe has to satisfy the >=1970 +requirement). + +So I'd guess raising an exception might be the simplest way to deal with +this. Here's a patch to try out: + +--8<---------------cut here---------------start------------->8--- +diff --git a/lisp/org.el b/lisp/org.el +index 92f2406..b9acf11 100644 +--- a/lisp/org.el ++++ b/lisp/org.el +@@ -14718,7 +14718,8 @@ user." + (nth 2 tl)) + (setq org-time-was-given t)) + (if (< year 100) (setq year (+ 2000 year))) +- (if (< year 1970) (setq year (nth 5 defdecode))) ; not representable ++; (if (< year 1970) (setq year (nth 5 defdecode))) ; not representable ++ (if (< year 1970) (error "Year must be >= 1970")) + (setq org-read-date-analyze-futurep futurep) + (list second minute hour day month year))) +--8<---------------cut here---------------end--------------->8--- + +I think it does not break anything but I'm not sure I like it much. + +Patchwork note: this should not be applied without a lot more thought +and experimentation. + +Nick + + + + -- 2.34.1 _______________________________________________ notmuch mailing list -- notmuch@notmuchmail.org To unsubscribe send an email to notmuch-le...@notmuchmail.org