From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Mark S" Subject: Re: Bug: Recurring items NEVER show up in timeline unaccompanied Date: Wed, 23 Mar 2011 10:02:41 -0800 Message-ID: Reply-To: throaway@yahoo.com Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Return-path: Received: from [140.186.70.92] (port=33357 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q2RTT-0008Hd-CM for emacs-orgmode@gnu.org; Wed, 23 Mar 2011 13:04:00 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q2RTS-0003Gs-BD for emacs-orgmode@gnu.org; Wed, 23 Mar 2011 13:03:59 -0400 Received: from fed1rmfepo203.cox.net ([68.230.241.148]:54507) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q2RTS-0003Gk-2D for emacs-orgmode@gnu.org; Wed, 23 Mar 2011 13:03:58 -0400 Received: from fed1rmimpo02.cox.net ([70.169.32.72]) by fed1rmfepo203.cox.net (InterMail vM.8.01.04.00 201-2260-137-20101110) with ESMTP id <20110323170356.KNDH22406.fed1rmfepo203.cox.net@fed1rmimpo02.cox.net> for ; Wed, 23 Mar 2011 13:03:56 -0400 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Hi Nick, Lisp tends to bring out my inner dyslexic, but is it possible to use a "while" or other construct instead of "mapcar" and then make the "if" construction inside of the lambda check for the :omitted symbol and return it as nil? And it would need to break out of the loop as soon as it encountered a date equal or greater to the present. Philosophically, the way I think the calendar should work for recurring events is that they only occur until the last event in the calendar UNLESS an argument has been given to specify how far out the calendar is to be drawn OR there is a global end-date / end-range variable. Mark --- On Tue, 3/22/11, Nick Dokos wrote: > From: Nick Dokos > Subject: Re: [O] Bug: Recurring items NEVER show up in timeline > unaccompanied > To: throaway@yahoo.com > Cc: nicholas.dokos@hp.com, emacs-orgmode@gnu.org > Date: Tuesday, March 22, 2011, 1:10 PM > Some more comments and another bug in > org-timeline: >o a repeater always gets reported on its initial date - it > only gets reported > on subsequent instances iff it coincides with some > other entry that will be > reported on that date. >o the initial comment of org-timeline says "Only entries > with a time > stamp of today or later will be listed." However, in > the let*, we have > (let* ((dopast t) > ... > so by default we get past dates as well. >o [the additional bug] if dopast is set to nil in the let*, > then we run the > following code to get rid of past dates: > (if (not dopast) > ;; Remove past dates from the list of > dates. > (setq day-numbers (delq nil (mapcar > (lambda(x) > (if (>= x today) x nil)) > day-numbers)))) > But day-numbers isn't just numbers: it's a list of > day numbers > interspersed with gap information: > (733451 (:omitted . 28) 733479 (:omitted > . 5) 733484 (:omitted . 21) 733505 (:omitted . 15) 733520 > ...) > and the mapcar function chokes when it has to deal > with a gap argument. >Since there is no way to set dopast from the outside, > perhaps the thing > to do is to remove both it and the above code (as well as > one additional > instance of the variable) and declare that org-timeline > will always do > both past and future. Or, given some global option > variable, it can be > set to that value, in which case the code above needs to be > fixed to > deal with the gaps. >Also, some stopping point will need to be provided. Right > now, that is > the last explicit date in the file, but in the presence of > repeaters > (and assuming that org-timeline gets modified to deal with > them), that > natural stopping point gets pushed all the way to infinity, > so some > other way will need to be provided to stop the > enumeration. >Comments? >Nick >