From mboxrd@z Thu Jan 1 00:00:00 1970 From: pinmacs Subject: Re: bug logging the TODO tracking state with brackets in the header Date: Mon, 9 Dec 2019 17:07:09 +0100 Message-ID: <66b62808-1165-ef9a-73cb-fd4fc22858f4@cas.cat> References: <7ab3d704-15a1-54ca-aeaa-06a08b07414d@cas.cat> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:60048) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ieLf2-0005Lf-Di for emacs-orgmode@gnu.org; Mon, 09 Dec 2019 11:13:26 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ieLf0-00045T-Nj for emacs-orgmode@gnu.org; Mon, 09 Dec 2019 11:13:24 -0500 Received: from host.cas.cat ([51.68.173.168]:51076) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ieLf0-000453-8V for emacs-orgmode@gnu.org; Mon, 09 Dec 2019 11:13:22 -0500 Received: from [192.168.41.195] (p.ddns.jazztel.es [37.133.181.30]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by host.cas.cat (Postfix) with ESMTPSA id 8CA0E3EA12 for ; Mon, 9 Dec 2019 17:07:10 +0100 (CET) In-Reply-To: <7ab3d704-15a1-54ca-aeaa-06a08b07414d@cas.cat> Content-Language: en-US List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: emacs-orgmode@gnu.org Hi list, I discovered that this issue is not reproduceable (noticiable) from an emacs vanilla version (without custom configuration) after digging in my config file that endend up with a happy orgmode file with thanks to babel and tangle [1] I found the problem. These are the lines that produce the mentioned bug (I tested just that lines alone in the custom configuration and still is reproduceable): #+BEGIN_SRC emacs-lisp ;; If you would like a TODO entry to automatically change to DONE when ;; all children are done, you can use the following setup: ;; source : http://orgmode.org/manual/Breaking-down-tasks.html#Breaking-down-tasks (defun org-summary-todo (n-done n-not-done) =A0 "Switch entry to DONE when all subentries are done, to TODO otherwise= =2E" =A0 (let (org-log-done org-log-states)=A0=A0 ; turn off logging =A0=A0=A0 (org-todo (if (=3D n-not-done 0) "DONE" "TODO")))) (add-hook 'org-after-todo-statistics-hook 'org-summary-todo) #+END_SRC fetching the link from official orgmode documentation looks like my code is up to date. But this code does the mentioned bug-error. I'm happy to comment that lines, to loose that mini-feature and gain the two others (numbering TODOs and tracking the state changes) Any ideas why it fails with that lines? Cheers, pinmacs [1] inspired by: http://www.coli.uni-saarland.de/~slemaguer/emacs/main.html https://github.com/seblemaguer/dotfiles/blob/master/emacs.d/main.org https://raw.githubusercontent.com/seblemaguer/dotfiles/master/emacs.d/mai= n.org On 12/7/19 11:11 PM, pinmacs wrote: > Hi, > > I reached a strange bug, I hope you can reproduce it too > > I want to track changes on TODO and I have in the beginning of my buffe= r: > > #+TODO: TODO(t!) PLANNED(p!) DOING(d!) VERIFY(v) EXPLAIN(e) | DONE(d!) > > which means that TODO, PLANEED, DOING and DONE will have a report of > change in the same header [0] > > If I have the number of TODOs like [6/45] (6 DONE, 45 in TODO) is not > working (see [1] for my example) > > If I quit that expression, it works, that could be the case when I do a= > subheader from a header without that brackets [2] > > I hope this example is illustrative [1]. > > The header that says "this fails" if I change the state, it reports > tracking state in the parent header with wrong information "state TODO > from TODO". It fails because the parent has the bracket thing. If the > parent of the parent has bracket thing it reports to "the parent of the= > parent", so it is weird :/ > > The header that says "this works" changes from states correctly because= > parent does not have the brackets > > I hope you can reproduce the bug on your own > > I'm using orgmode version 9.3 > > let me if I can help with the bug reporting > > Cheers, > pinmacs > > [0] > https://www.gnu.org/software/emacs/manual/html_node/org/Tracking-TODO-s= tate-changes.html > > [1] > > *** TODO <2019-12-07 Sat>=A0 [6/45]=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0= =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 > :today: > - State "TODO"=A0=A0=A0=A0=A0=A0 from "TODO"=A0=A0=A0=A0=A0=A0 [2019-12= -07 Sat 22:58] > - State "TODO"=A0=A0=A0=A0=A0=A0 from "TODO"=A0=A0=A0=A0=A0=A0 [2019-12= -07 Sat 22:58] > - State "TODO"=A0=A0=A0=A0=A0=A0 from "TODO"=A0=A0=A0=A0=A0=A0 [2019-12= -07 Sat 22:57] > - State "TODO"=A0=A0=A0=A0=A0=A0 from "TODO"=A0=A0=A0=A0=A0=A0 [2019-12= -07 Sat 22:57] > - State "TODO"=A0=A0=A0=A0=A0=A0 from "TODO"=A0=A0=A0=A0=A0=A0 [2019-12= -07 Sat 22:57] > - State "TODO"=A0=A0=A0=A0=A0=A0 from "TODO"=A0=A0=A0=A0=A0=A0 [2019-12= -07 Sat 22:57] > **** DONE this fails > ***** DONE this works OK > - State "DONE"=A0=A0=A0=A0=A0=A0 from "EXPLAIN"=A0=A0=A0 [2019-12-07 Sa= t 22:58] > - State "DOING"=A0=A0=A0=A0=A0 from "PLANNED"=A0=A0=A0 [2019-12-07 Sat = 22:58] > - State "PLANNED"=A0=A0=A0 from "TODO"=A0=A0=A0=A0=A0=A0 [2019-12-07 Sa= t 22:58] > - State "TODO"=A0=A0=A0=A0=A0=A0 from=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0= =A0 [2019-12-07 Sat 22:58] > > [2] > > as you can see in the following 2 links: > > - https://orgmode.org/manual/Breaking-down-tasks.html#Breaking-down-tas= ks > - https://orgmode.org/manual/Checkboxes.html#Checkboxes > >