emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] Org Clock Error


From: Nick Dokos
Subject: Re: [O] Org Clock Error
Date: Wed, 13 Jan 2016 20:30:17 -0500
User-agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/25.1.50 (gnu/linux)

Mike McLean <address@hidden> writes:

> Hello
>
> In the last few days I started getting an error when moving tasks to the DONE 
> state.
>
> I have ~(setq org-clock-out-when-done t)~ in my Emacs configuration. 
>
> I get the following back trace when I mark a task as done:
>
> Debugger entered--Lisp error: (void-variable org-state)
>   (member org-state org-done-keywords)
>   ...
>   org-clock-out-if-current()
>   run-hooks(org-after-todo-state-change-hook)
>   ...
>   org-todo(nil)

This is probably a lexical binding problem: org-state is supposed to be
dynamically bound by org-todo and then used by org-clock-out-if-current,
but it seems that the communication is lost.

I'm not sure what the solution is (I haven't really followed the
upstream discussion), but I wonder if adding

(defvar org-state)

in org.el, just before the

(defun org-todo ...

line is enough to resolve the problem (basically letting org-todo know
that org-state is dynamically bound).

Untested and possibly wrong.

-- 
Nick




reply via email to

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