emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Buglet with scheduled in TODO lists
@ 2007-02-21 20:04 Jason F. McBrayer
  2007-02-22  7:19 ` Carsten Dominik
  0 siblings, 1 reply; 3+ messages in thread
From: Jason F. McBrayer @ 2007-02-21 20:04 UTC (permalink / raw)
  To: emacs-orgmode

I have org-agenda-todo-ignore-scheduled set to t.  One behaviour I have
noticed is that scheduled TODO items will still show up in TODO-type
agenda buffers if there is something in between the headline and the
SCHEDULED line.  This can happen very easily if one is using time
tracking.

Example:

**** NEXTACTION Weekly Review REPEAT(+1w)
     CLOCK: [2007-02-20 Tue 08:30]--[2007-02-20 Tue 08:50] =>  0:20
     CLOCK: [2007-02-13 Tue 08:30]--[2007-02-13 Tue 09:03] =>  0:33
     CLOCK: [2007-02-05 Mon 13:30]--[2007-02-05 Mon 14:29] =>  0:59
     SCHEDULED: <2007-02-26 Mon 08:30> 

Weekly review appears in my list of Next Actions, and I expect that it
shouldn't.  If I move the SCHEDULED line to right below the headline, it
doesn't appear in my list, which I believe is the correct behaviour.

-- 
+-----------------------------------------------------------+
| Jason F. McBrayer                    jmcbray@carcosa.net  |
| If someone conquers a thousand times a thousand others in |
| battle, and someone else conquers himself, the latter one |
| is the greatest of all conquerors.  --- The Dhammapada    |

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Buglet with scheduled in TODO lists
  2007-02-21 20:04 Buglet with scheduled in TODO lists Jason F. McBrayer
@ 2007-02-22  7:19 ` Carsten Dominik
  2007-02-22 14:04   ` Jason F. McBrayer
  0 siblings, 1 reply; 3+ messages in thread
From: Carsten Dominik @ 2007-02-22  7:19 UTC (permalink / raw)
  To: Jason F. McBrayer; +Cc: emacs-orgmode


On Feb 21, 2007, at 21:04, Jason F. McBrayer wrote:

> I have org-agenda-todo-ignore-scheduled set to t.  One behaviour I have
> noticed is that scheduled TODO items will still show up in TODO-type
> agenda buffers if there is something in between the headline and the
> SCHEDULED line.

There are really two bugs here.  The first is that the clocking info
get between the headline and the scheduling line - this should not
happen.  Here is the patch - if you apply it,
also go through the file and push the SCHEDULED/DEADLINE stuff back
to right after the headline.

--- org.el.orig	Thu Feb 22 08:15:21 2007
+++ org.el	Thu Feb 22 08:15:32 2007
@@ -12459,7 +12459,9 @@
        (beginning-of-line 2)
        (when (and (looking-at (concat "[ \t]*" org-keyword-time-regexp))
  		 (not (equal (match-string 1) org-clock-string)))
-	(beginning-of-line 1))
+	;; First line hast scheduling info, move one further
+	(beginning-of-line 2)
+	(or (bolp) (newline)))
        (insert "\n") (backward-char 1)
        (indent-relative)
        (insert org-clock-string " ")



The second bug is that yes, indeed, the scheduling line could/should 
also
be found further down.  I can fix that too, but there are also other
places where the code assumes (I believe) that this info is always in
the second line.  I am not yet sure if I will change this.

- Carsten



>   This can happen very easily if one is using time
> tracking.
>
> Example:
>
> **** NEXTACTION Weekly Review REPEAT(+1w)
>      CLOCK: [2007-02-20 Tue 08:30]--[2007-02-20 Tue 08:50] =>  0:20
>      CLOCK: [2007-02-13 Tue 08:30]--[2007-02-13 Tue 09:03] =>  0:33
>      CLOCK: [2007-02-05 Mon 13:30]--[2007-02-05 Mon 14:29] =>  0:59
>      SCHEDULED: <2007-02-26 Mon 08:30>
>
> Weekly review appears in my list of Next Actions, and I expect that it
> shouldn't.  If I move the SCHEDULED line to right below the headline, 
> it
> doesn't appear in my list, which I believe is the correct behaviour.
>
> -- 
> +-----------------------------------------------------------+
> | Jason F. McBrayer                    jmcbray@carcosa.net  |
> | If someone conquers a thousand times a thousand others in |
> | battle, and someone else conquers himself, the latter one |
> | is the greatest of all conquerors.  --- The Dhammapada    |
>
>
> _______________________________________________
> Emacs-orgmode mailing list
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
>
>

--
Carsten Dominik
Sterrenkundig Instituut "Anton Pannekoek"
Universiteit van Amsterdam
Kruislaan 403
NL-1098SJ Amsterdam
phone: +31 20 525 7477

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Buglet with scheduled in TODO lists
  2007-02-22  7:19 ` Carsten Dominik
@ 2007-02-22 14:04   ` Jason F. McBrayer
  0 siblings, 0 replies; 3+ messages in thread
From: Jason F. McBrayer @ 2007-02-22 14:04 UTC (permalink / raw)
  To: emacs-orgmode

On Thu, 2007-02-22 at 08:19 +0100, Carsten Dominik wrote:

> The second bug is that yes, indeed, the scheduling line could/should 
> also
> be found further down.  I can fix that too, but there are also other
> places where the code assumes (I believe) that this info is always in
> the second line.  I am not yet sure if I will change this.

For my purposes, the patch you already provided should be fine.  There's
no reason I would _intentionally_ put the scheduling line anywhere but
below the headline.  Really, it _should_ find the scheduling line
anywhere before the next headline, but with the first bug fixed, I'm
unlikely to notice whether it does or not.

-- 
+-----------------------------------------------------------+
| Jason F. McBrayer                    jmcbray@carcosa.net  |
| If someone conquers a thousand times a thousand others in |
| battle, and someone else conquers himself, the latter one |
| is the greatest of all conquerors.  --- The Dhammapada    |

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-02-22 14:04 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-02-21 20:04 Buglet with scheduled in TODO lists Jason F. McBrayer
2007-02-22  7:19 ` Carsten Dominik
2007-02-22 14:04   ` Jason F. McBrayer

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).