emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [BUG] Future repeated tasks marked done in Org Agenda don't show as


From: Gustavo Barros
Subject: Re: [BUG] Future repeated tasks marked done in Org Agenda don't show as done [9.5 (9.5-g0a86ad @ /home/gustavo/.emacs.d/elpa/org-9.5/)]
Date: Mon, 11 Jul 2022 10:51:55 -0300
User-agent: mu4e 1.8.5; emacs 28.1

Hi All,

On Fri, 29 Oct 2021 at 21:40, Ihor Radchenko <yantar92@gmail.com> wrote:

Gustavo Barros <gusbrs.2016@gmail.com> writes:

The glitch is that some repeated tasks, when marked done in the Agenda, show no visual feedback that the action has taken place, as usual, and if you refresh the Agenda, they just vanish, which demonstrates the action had indeed taken place in the agenda file, just not shown in the Agenda buffer itself. And, as far as I can tell, this happens to repeated tasks, scheduled in future. For tasks scheduled for today or in the past, they appear to be done as expected.

Confirmed

Best,
Ihor

This is a respectful bump on this one.

But not to bump empty handed, I did some investigation on this, and I think I know why the problem happens.

At `org-agenda-todo' when a task is a repeating one, the value of `org-agenda-headline-snapshot-before-repeat' stored at `org-todo' may or may not replace `newhead' depending on some conditions, which are:

#+begin_src emacs-lisp
(when (and org-agenda-headline-snapshot-before-repeat
           (not (equal org-agenda-headline-snapshot-before-repeat
                       newhead))
           todayp)
 (setq newhead org-agenda-headline-snapshot-before-repeat
        just-one t))
#+end_src

So that `newhead' is set to `org-agenda-headline-snapshot-before-repeat' only if `todayp' is non-nil. And, indeed, this seems to be the condition which results in the missing visual feedback reported here. I've tried without it, and it works. (I'm currently using built-in 9.5.2, but I think there's no change in the function to current release 9.5.4 and also, light testing with the latter suggests no change in the reported issue).

What I'm not sure is why this condition is there in the first place. That's the only place where the let-bound `todayp' is used in the function, so I may be missing why it exists and the purpose of this condition. But one side-effect of it is that, if you happen to do a repeating task ahead of schedule, you won't see the change of todo state in the agenda.

Best regards,
Gustavo.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]