* Bug? SCHEDULED lines treated differently when text precedes them
@ 2019-09-05 12:51 Christoph Groth
2019-09-05 13:00 ` Nicolas Goaziou
0 siblings, 1 reply; 8+ messages in thread
From: Christoph Groth @ 2019-09-05 12:51 UTC (permalink / raw)
To: emacs-orgmode
Dear org mode experts,
I have noticed the following behavior that (after reading the relevant
documentation) I find at least surprising and error-prone.
With Org 9.2.3, the following two TODO items behave differently:
** TODO Something
blabla
SCHEDULED: <2019-09-01 Sun>
[2019-09-05 Thu 14:39]
** TODO Something else
SCHEDULED: <2019-09-01 Sun>
foobar
[2019-09-05 Thu 14:40]
The first one behaves as expected, i.e. it appears in today's
(2019-09-05) agenda, since it's not done yet.
The second one does appear in today's agenda, but it is visible for the
day 2019-09-01.
Is this behavior by design? If yes, could someone please explain the
rationale or point me to relevant documentation or discussions?
Thanks!
Christoph
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Bug? SCHEDULED lines treated differently when text precedes them
2019-09-05 12:51 Bug? SCHEDULED lines treated differently when text precedes them Christoph Groth
@ 2019-09-05 13:00 ` Nicolas Goaziou
2019-09-05 13:38 ` Christoph Groth
0 siblings, 1 reply; 8+ messages in thread
From: Nicolas Goaziou @ 2019-09-05 13:00 UTC (permalink / raw)
To: Christoph Groth; +Cc: emacs-orgmode
Hello,
Christoph Groth <christoph@grothesque.org> writes:
> With Org 9.2.3, the following two TODO items behave differently:
>
> ** TODO Something
> blabla
> SCHEDULED: <2019-09-01 Sun>
> [2019-09-05 Thu 14:39]
> ** TODO Something else
> SCHEDULED: <2019-09-01 Sun>
> foobar
> [2019-09-05 Thu 14:40]
>
> The first one behaves as expected, i.e. it appears in today's
> (2019-09-05) agenda, since it's not done yet.
>
> The second one does appear in today's agenda, but it is visible for the
> day 2019-09-01.
>
> Is this behavior by design? If yes, could someone please explain the
> rationale or point me to relevant documentation or discussions?
Planning information (SCHEDULED, DEADLINE and CLOSED keywords) must
appear right after the headline, per Org syntax. This is specified at
the first paragraph in (info "(org) Deadlines and Scheduling").
Elswhere, only the timestamp is meaningful to Org.
Regards,
--
Nicolas Goaziou
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Bug? SCHEDULED lines treated differently when text precedes them
2019-09-05 13:00 ` Nicolas Goaziou
@ 2019-09-05 13:38 ` Christoph Groth
2019-09-05 13:40 ` Nicolas Goaziou
` (2 more replies)
0 siblings, 3 replies; 8+ messages in thread
From: Christoph Groth @ 2019-09-05 13:38 UTC (permalink / raw)
To: emacs-orgmode; +Cc: Nicolas Goaziou
Nicolas Goaziou wrote:
> Planning information (SCHEDULED, DEADLINE and CLOSED keywords) must
> appear right after the headline, per Org syntax. This is specified at
> the first paragraph in (info "(org) Deadlines and Scheduling").
>
> Elswhere, only the timestamp is meaningful to Org.
Thanks for the quick clarification! I didn't see the relevant line in
the documentation since my Emacs from Debian shows only the info
documentation for the (outdated) Org that is bundled with Emacs [1].
I understand now that Org does what it should. However, I find this
behavior quite dangerous. It caught me after more than 10 years of
using Org. If there's a list of long-term issues with Org somewhere,
this problem may deserve being added to it.
Cheers
Christoph
[1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=725408
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Bug? SCHEDULED lines treated differently when text precedes them
2019-09-05 13:38 ` Christoph Groth
@ 2019-09-05 13:40 ` Nicolas Goaziou
2019-09-05 13:58 ` Christoph Groth
2019-09-05 14:02 ` Carsten Dominik
2019-09-06 0:52 ` Tim Cross
2 siblings, 1 reply; 8+ messages in thread
From: Nicolas Goaziou @ 2019-09-05 13:40 UTC (permalink / raw)
To: Christoph Groth; +Cc: emacs-orgmode
Christoph Groth <christoph@grothesque.org> writes:
> I understand now that Org does what it should. However, I find this
> behavior quite dangerous. It caught me after more than 10 years of
> using Org. If there's a list of long-term issues with Org somewhere,
> this problem may deserve being added to it.
I don't think there is much to fix here. In any case, the command
`org-lint' warns you about this kind of error.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Bug? SCHEDULED lines treated differently when text precedes them
2019-09-05 13:40 ` Nicolas Goaziou
@ 2019-09-05 13:58 ` Christoph Groth
2019-09-06 1:08 ` Tim Cross
0 siblings, 1 reply; 8+ messages in thread
From: Christoph Groth @ 2019-09-05 13:58 UTC (permalink / raw)
To: emacs-orgmode; +Cc: Nicolas Goaziou
Nicolas Goaziou wrote:
> Christoph Groth <christoph@grothesque.org> writes:
>
> > I understand now that Org does what it should. However, I find this
> > behavior quite dangerous. It caught me after more than 10 years of
> > using Org. If there's a list of long-term issues with Org
> > somewhere, this problem may deserve being added to it.
>
> I don't think there is much to fix here. In any case, the command
> `org-lint' warns you about this kind of error.
Thanks for mentioning 'org-lint'. I just ran it on my agenda files, and
it found multiple errors in most of my (very long) files. So at least
for me (and likely for other Org users as well), the risk of missing
TODO items is real - that's a rather serious problem for a task manager!
My agenda files are populated using 'org-capture'. Do you have
suggestions how to best integrate org-lint transparently into everyday
org usage? For example, files could be linted automatically before they
are saved, or before a new item is captured.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Bug? SCHEDULED lines treated differently when text precedes them
2019-09-05 13:38 ` Christoph Groth
2019-09-05 13:40 ` Nicolas Goaziou
@ 2019-09-05 14:02 ` Carsten Dominik
2019-09-06 0:52 ` Tim Cross
2 siblings, 0 replies; 8+ messages in thread
From: Carsten Dominik @ 2019-09-05 14:02 UTC (permalink / raw)
To: Christoph Groth; +Cc: org-mode list, Nicolas Goaziou
[-- Attachment #1: Type: text/plain, Size: 1464 bytes --]
On Thu, Sep 5, 2019 at 3:38 PM Christoph Groth <christoph@grothesque.org>
wrote:
> Nicolas Goaziou wrote:
>
> > Planning information (SCHEDULED, DEADLINE and CLOSED keywords) must
> > appear right after the headline, per Org syntax. This is specified at
> > the first paragraph in (info "(org) Deadlines and Scheduling").
> >
> > Elswhere, only the timestamp is meaningful to Org.
>
> Thanks for the quick clarification! I didn't see the relevant line in
> the documentation since my Emacs from Debian shows only the info
> documentation for the (outdated) Org that is bundled with Emacs [1].
>
This is, in fact, one of the very few things that did change with the
introduction of org-elements.el and the fore formal parsing of Org files.
Originally, SCHEDULED and DEADLINE could be anywhere in the entry. But
with the development of the parser, and (I think) in order to define
everything well in particular also for the export backends, the planning
information was confined to the first line.
I don't think you need to be worried about more surprises, this was the
most significant one IIRC.
Carsten
>
> I understand now that Org does what it should. However, I find this
> behavior quite dangerous. It caught me after more than 10 years of
> using Org. If there's a list of long-term issues with Org somewhere,
> this problem may deserve being added to it.
>
> Cheers
> Christoph
>
> [1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=725408
>
>
[-- Attachment #2: Type: text/html, Size: 2208 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Bug? SCHEDULED lines treated differently when text precedes them
2019-09-05 13:38 ` Christoph Groth
2019-09-05 13:40 ` Nicolas Goaziou
2019-09-05 14:02 ` Carsten Dominik
@ 2019-09-06 0:52 ` Tim Cross
2 siblings, 0 replies; 8+ messages in thread
From: Tim Cross @ 2019-09-06 0:52 UTC (permalink / raw)
To: emacs-orgmode; +Cc: Nicolas Goaziou
You may also find the command M-x org-lint useful. I regularly run it on
my larger org files after an org release to spot problems in my org
files (either due to my error or changes in orgmode)
Tim
Christoph Groth <christoph@grothesque.org> writes:
> Nicolas Goaziou wrote:
>
>> Planning information (SCHEDULED, DEADLINE and CLOSED keywords) must
>> appear right after the headline, per Org syntax. This is specified at
>> the first paragraph in (info "(org) Deadlines and Scheduling").
>>
>> Elswhere, only the timestamp is meaningful to Org.
>
> Thanks for the quick clarification! I didn't see the relevant line in
> the documentation since my Emacs from Debian shows only the info
> documentation for the (outdated) Org that is bundled with Emacs [1].
>
> I understand now that Org does what it should. However, I find this
> behavior quite dangerous. It caught me after more than 10 years of
> using Org. If there's a list of long-term issues with Org somewhere,
> this problem may deserve being added to it.
>
> Cheers
> Christoph
>
> [1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=725408
--
Tim Cross
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Bug? SCHEDULED lines treated differently when text precedes them
2019-09-05 13:58 ` Christoph Groth
@ 2019-09-06 1:08 ` Tim Cross
0 siblings, 0 replies; 8+ messages in thread
From: Tim Cross @ 2019-09-06 1:08 UTC (permalink / raw)
To: emacs-orgmode; +Cc: Nicolas Goaziou
maybe add org-lint to the after-save-hook - maybe something like
(untested)
(add-hook 'after-save-hook (lamda ()
(when (eq buffer-mode 'org-mode)
(org-lint))))
Christoph Groth <christoph@grothesque.org> writes:
> Nicolas Goaziou wrote:
>> Christoph Groth <christoph@grothesque.org> writes:
>>
>> > I understand now that Org does what it should. However, I find this
>> > behavior quite dangerous. It caught me after more than 10 years of
>> > using Org. If there's a list of long-term issues with Org
>> > somewhere, this problem may deserve being added to it.
>>
>> I don't think there is much to fix here. In any case, the command
>> `org-lint' warns you about this kind of error.
>
> Thanks for mentioning 'org-lint'. I just ran it on my agenda files, and
> it found multiple errors in most of my (very long) files. So at least
> for me (and likely for other Org users as well), the risk of missing
> TODO items is real - that's a rather serious problem for a task manager!
>
> My agenda files are populated using 'org-capture'. Do you have
> suggestions how to best integrate org-lint transparently into everyday
> org usage? For example, files could be linted automatically before they
> are saved, or before a new item is captured.
--
Tim Cross
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2019-09-06 1:08 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-09-05 12:51 Bug? SCHEDULED lines treated differently when text precedes them Christoph Groth
2019-09-05 13:00 ` Nicolas Goaziou
2019-09-05 13:38 ` Christoph Groth
2019-09-05 13:40 ` Nicolas Goaziou
2019-09-05 13:58 ` Christoph Groth
2019-09-06 1:08 ` Tim Cross
2019-09-05 14:02 ` Carsten Dominik
2019-09-06 0:52 ` Tim Cross
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).