From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id IBPPL83gzGKKSwEAbAwnHQ (envelope-from ) for ; Tue, 12 Jul 2022 04:47:41 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id ELYAL83gzGKOgAEAG6o9tA (envelope-from ) for ; Tue, 12 Jul 2022 04:47:41 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 6E35425683 for ; Tue, 12 Jul 2022 04:47:41 +0200 (CEST) Received: from localhost ([::1]:60236 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oB5w4-00033w-Ae for larch@yhetil.org; Mon, 11 Jul 2022 22:47:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43654) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oB5uA-00032T-IT for emacs-orgmode@gnu.org; Mon, 11 Jul 2022 22:45:43 -0400 Received: from mail-pj1-x1032.google.com ([2607:f8b0:4864:20::1032]:40835) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oB5u8-0000Ju-Tu for emacs-orgmode@gnu.org; Mon, 11 Jul 2022 22:45:42 -0400 Received: by mail-pj1-x1032.google.com with SMTP id g16-20020a17090a7d1000b001ea9f820449so10094877pjl.5 for ; Mon, 11 Jul 2022 19:45:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=ZDapCcr5LSQssKxrFzjkAMG9FhwEGtNswiwKHWaaJqM=; b=d0Ze70EbWAyO6EcWAtz1PaYvjb2d5Yc+9K5PQKp/8oXTJljtbKsFA8HJ9mDNSX1pvY VIFMxi/MVyvcr4fXXdCB3Gh/g7lXU3Z2PPSe3SwS0CftuyUeYEn4WC9llRxCi8Fm58gm +BMkKO+42klwfGlznnaaoLjZmizoqxv3qKzdVKsqoj4WwxVeyCiIqRyq8p59zPg9rA6l L3c4PNa4osKqfzL2WpZNWdeCBgWKhNCUfIsUE71OTrBMYpFjKpY4icdWJbG5DI9ZoZYu I/I+e3lJWZJq0YFoophAf9uBfBMSfPY/ijETRXjgxxG0x44hOTYLjITZnhze9Le4dPmv JCKw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=ZDapCcr5LSQssKxrFzjkAMG9FhwEGtNswiwKHWaaJqM=; b=2JNi5fW7z0x2vnyzZy3PWVOqUbrhLbu9sAN4SrsvP1mR9nG6iXZ+BxvGNGd68LmVb8 PSFDIfnh+8dApKgVw+6iGImf1N9NTCxlcJCzx1xhwB/+WSvn95zwJVrjvS3bmUpUZKOP gePdduVB8Tihuks/uoYtuR8Mx2Sef4JCNEZjyUJBC71oyqq20PXHtbRUlyc4HEB89BmU 3qMMAj9Q0enjqcaYMyhdCnGz2LeWgUbCd7be7IhZUBJWcMsXknFA2wea+Qlz6ATUB6D7 4AAVeDk8YgY/qLozJzuUmG10k3W/3OnIYjAmTwkL7XxCto4CMXdDkIEKsIJyik1B2fNB e8fg== X-Gm-Message-State: AJIora9EZVgWEkb1dIq5JbAZWqjoSB+Rr9jqAYusuBCjzWTtGD4zGE42 x01XkGZfU9GiSlaAYuK0I+E= X-Google-Smtp-Source: AGRyM1vNSlrgdZI6rjk9jVP1OqtRn5Jd6k3w0a3Wv1F+F5smH+PCGpt6Gm+qr1GkK947neLK04tNZw== X-Received: by 2002:a17:902:ea10:b0:16c:1b1f:cca with SMTP id s16-20020a170902ea1000b0016c1b1f0ccamr21713031plg.34.1657593938394; Mon, 11 Jul 2022 19:45:38 -0700 (PDT) Received: from localhost ([157.52.221.140]) by smtp.gmail.com with ESMTPSA id t16-20020a170902b21000b0016c0080df84sm5405854plr.254.2022.07.11.19.45.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 11 Jul 2022 19:45:37 -0700 (PDT) From: Ihor Radchenko To: Gustavo Barros Cc: emacs-orgmode@gnu.org 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/)] In-Reply-To: <87tu7n68xs.fsf@gmail.com> References: <87ee84dllb.fsf@gmail.com> <87k0hwdk54.fsf@localhost> <87tu7n68xs.fsf@gmail.com> Date: Tue, 12 Jul 2022 10:46:42 +0800 Message-ID: <87a69f6oa5.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::1032; envelope-from=yantar92@gmail.com; helo=mail-pj1-x1032.google.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1657594061; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=ZDapCcr5LSQssKxrFzjkAMG9FhwEGtNswiwKHWaaJqM=; b=MrRsQsFjLqUTJyRBBTrdWwRkb5+Tf0OpuFL1+jc6ph+jdd/bqdmbKi7Bb7Xa5LPC+P6VXN eFRnSud0idszIS6PVr8lL/gVHvOi6ZoiujaSJVnzKATrM8lfmtGz3DF19wT2fTpeLZ4o/+ 1u3KBcjLAVij5CvpIVpWk4tq/i3U0dhvDT+jniXHjwOmUOikxxCuaG5pUMCETCRZO6p75J 3ZyS0pwYqnZa7411TQD544gM5gY0rOK5baGsTdh1dQt7xjfkbrkgU+ynZww49zGKMMWExh pbDY8eito+70v8BkAGBXrOx2fQp8Vyya5GyOrcFpRh2nK92P2oRO62nBSXFWPg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1657594061; a=rsa-sha256; cv=none; b=Nd9F8Q6MJ5iujkFolbO/4qMK/LqqH3+IvMgVQCEAiBP/IPb8DZrkhKdKqkfVb6ZfhCwg90 5XocrRnpud5iN3lHCt+2GOrWIX0isJ3VT34XU3RmQULRu+vx2UdhW8+dWaBxA1oWN1X+wL 8t7iW9H1Yw6BEGJAZEYjbdHvG7e3ml0cJ62H5BHuzCKcHL6FGre20OxwQpx6Lyyh4tpEWT fRuESN4hTWT/frY1zC90rOU+zdjOyql+AK7dcJ4dT5HJp7cGyMivrMD7PJGgVgG/LRxIlh BdhzLlrst9fsJjlVyiQ0YLU4Sc2j20fjYi8dxJAlyqgURxbB/o3vpqAjLCUVTw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=d0Ze70Eb; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -3.45 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=d0Ze70Eb; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 6E35425683 X-Spam-Score: -3.45 X-Migadu-Scanner: scn0.migadu.com X-TUID: fEHtUM9ndeWT Gustavo Barros writes: > But not to bump empty handed, I did some investigation on this, and I > think I know why the problem happens. Thanks for the detailed analysis! > 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. I dug through the old commits and found where this behaviour has been introduced: Commit 0bbf3a9bd message details the current behaviour and its caveats: >> When marking a repeated entry DONE in the daily or weekly agenda, that >> task would previously still be shown as TODO, because the repeater >> immediately restores the TODO state after moving the time stamp. This >> is bad feedback. >> >> This problem was hard to fix. Because the same line may be present in >> other lines in the same weekly agenda, we cannot simply update all >> lines related to this entry. >> >> What we do now is this: Before the repeater does its work in shifting >> the time stamp and resetting the TODO keyword, we take a snapshot of >> the headline as it looks then. And then, when we update the agenda >> view, we change only the line at the cursor instead of all lines >> related to this entry. We also make sure that this is only so if the >> cursor is in a daily/weekly agenda, on TODAY's date. >> >> There still remain possible inconsistencies. For example, if you have >> a daily repeating task in the weekly agenda, and you move the cursor a >> few days into the future and mark it DONE there, the entry will >> actually be marked DONE for today, but still show up in today's task >> list as TODO. refreshing the agenda will fix the display in such an >> unlikely case. >> >> Thanks to Jack ??? for noticing and reporting this issue. As you can see, the todayp condition is avoiding issues with weekly agenda when the same habit is displayed multiple times. The problem you observed is also noted and left unresolved. Ideas how to deal with the described are welcome! Best, Ihor