emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Bug: numeric org-clock-into-drawer is ignored [8.3beta (release_8.3beta-846-g38ab8b @ /Users/vvv/lib/emacs/org-mode/lisp/)]
@ 2015-02-27 21:20 Valery V. Vorotyntsev
  2015-02-27 21:30 ` Valery V. Vorotyntsev
  0 siblings, 1 reply; 3+ messages in thread
From: Valery V. Vorotyntsev @ 2015-02-27 21:20 UTC (permalink / raw)
  To: emacs-orgmode

Remember to cover the basics, that is, what you expected to happen and
what in fact did happen.  You don't know how to make a good report?  See

     http://orgmode.org/manual/Feedback.html#Feedback

Your bug report will be posted to the Org-mode mailing list.
------------------------------------------------------------------------

I have set `org-clock-into-drawer' to 2.
`(org-clock-into-drawer)' should return the same value (see the
documentation of this function), yet it returns "LOGBOOK".
So a CLOCK line is created in a drawer. This contradicts to the
documentation of `org-clock-into-drawer' variable:

| When an integer, the drawer is created only when the number of
| clocking entries in an item reaches or exceeds this value.

I believe this bug to be introduced by commit e990bed.

--
Cheers,
vvv


Emacs  : GNU Emacs 24.4.90.1 (x86_64-apple-darwin13.4.0, NS
apple-appkit-1265.21)
 of 2015-02-17 on builder10-9.porkrind.org
Package: Org-mode version 8.3beta (release_8.3beta-846-g38ab8b @
/Users/vvv/lib/emacs/org-mode/lisp/)

current state:
==============
(setq
 org-tab-first-hook '(org-hide-block-toggle-maybe
     org-babel-hide-result-toggle-maybe
     org-babel-header-arg-expand)
 org-speed-command-hook '(org-speed-command-default-hook
 org-babel-speed-command-hook)
 org-occur-hook '(org-first-headline-recenter)
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-clock-into-drawer 2
 org-confirm-shell-link-function 'yes-or-no-p
 org-clock-idle-time 10
 org-todo-keyword-faces '(("TODO" :foreground "red" :weight bold)
 ("NEXT" :foreground "blue" :weight bold)
 ("DONE" :foreground "forest green" :weight bold)
 ("WAITING" :foreground "orange" :weight bold)
 ("HOLD" :foreground "magenta" :weight bold)
 ("CANCELLED" :foreground "forest green" :weight bold)
 )
 org-startup-indented t
 org-after-todo-state-change-hook '(org-clock-out-if-current
   bh/mark-next-parent-tasks-todo)
 org-src-mode-hook '(org-src-babel-configure-edit-buffer
    org-src-mode-configure-edit-buffer)
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-babel-pre-tangle-hook '(save-buffer)
 org-mode-hook '((lambda nil
 (org-add-hook (quote change-major-mode-hook)
  (quote org-show-block-all) (quote append) (quote local))
 )
#[nil "\300\301\302\303\304$\207"
  [org-add-hook change-major-mode-hook
   org-babel-show-result-all append local]
  5]
org-babel-result-hide-spec org-babel-hide-all-hashes
(lambda nil (define-key org-mode-map (kbd "C-c SPC") nil)))
 org-todo-state-tags-triggers '(("CANCELLED" ("CANCELLED" . t))
("WAITING" ("WAITING" . t))
("HOLD" ("HOLD" . t) ("WAITING"))
("TODO" ("WAITING") ("HOLD") ("CANCELLED"))
("NEXT" ("WAITING") ("HOLD") ("CANCELLED"))
("DONE" ("WAITING") ("HOLD") ("CANCELLED"))
(done ("WAITING") ("HOLD")))
 org-archive-hook '(org-attach-archive-delete-maybe)
 org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point
 org-babel-execute-safely-maybe)
 org-directory "~/.org"
 org-enforce-todo-dependencies t
 org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers
 org-cycle-hide-inline-tasks org-cycle-show-empty-lines
 org-optimize-window-after-visibility-change)
 org-todo-keywords '((sequence "TODO(t)" "NEXT(n)" "|" "DONE(d)")
    (sequence "WAITING(w@/!)" "HOLD(h@/!)" "|"
     "CANCELLED(c@/!)")
    )
 org-modules nil
 org-confirm-elisp-link-function 'yes-or-no-p
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 org-treat-S-cursor-todo-selection-as-state-change nil
 org-blocker-hook '(org-block-todo-from-children-or-siblings-or-parent)
 org-babel-load-languages '((emacs-lisp . t) (shell . t))
 org-clock-in-hook '(bh/mark-next-parent-tasks-todo)
 org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
 org-clock-out-remove-zero-time-clocks t
 )

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Bug: numeric org-clock-into-drawer is ignored [8.3beta (release_8.3beta-846-g38ab8b @ /Users/vvv/lib/emacs/org-mode/lisp/)]
  2015-02-27 21:20 Bug: numeric org-clock-into-drawer is ignored [8.3beta (release_8.3beta-846-g38ab8b @ /Users/vvv/lib/emacs/org-mode/lisp/)] Valery V. Vorotyntsev
@ 2015-02-27 21:30 ` Valery V. Vorotyntsev
  2015-02-28 18:28   ` Nicolas Goaziou
  0 siblings, 1 reply; 3+ messages in thread
From: Valery V. Vorotyntsev @ 2015-02-27 21:30 UTC (permalink / raw)
  To: emacs-orgmode

On 27 February 2015 at 23:20, Valery V. Vorotyntsev <valery.vv@gmail.com> wrote:

> I have set `org-clock-into-drawer' to 2.
> `(org-clock-into-drawer)' should return the same value (see the
> documentation of this function), yet it returns "LOGBOOK".

Proposed patch:

----------[ begin ]----------
diff --git a/lisp/org-clock.el b/lisp/org-clock.el
index 07f02b0..0edc1b9 100644
--- a/lisp/org-clock.el
+++ b/lisp/org-clock.el
@@ -88,6 +88,7 @@ Return value is either a string, an integer, or nil."
    (if (org-string-match-p "\\`[0-9]+\\'" p) (string-to-number p) p))
   ((org-string-nw-p org-clock-into-drawer))
   ((not org-clock-into-drawer) nil)
+  ((wholenump org-clock-into-drawer) org-clock-into-drawer)
   ((org-log-into-drawer))
   (t "LOGBOOK"))))
----------[ end ]----------

-- 
vvv

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: Bug: numeric org-clock-into-drawer is ignored [8.3beta (release_8.3beta-846-g38ab8b @ /Users/vvv/lib/emacs/org-mode/lisp/)]
  2015-02-27 21:30 ` Valery V. Vorotyntsev
@ 2015-02-28 18:28   ` Nicolas Goaziou
  0 siblings, 0 replies; 3+ messages in thread
From: Nicolas Goaziou @ 2015-02-28 18:28 UTC (permalink / raw)
  To: Valery V. Vorotyntsev; +Cc: emacs-orgmode

Hello,

"Valery V. Vorotyntsev" <valery.vv@gmail.com> writes:

> On 27 February 2015 at 23:20, Valery V. Vorotyntsev <valery.vv@gmail.com> wrote:
>
>> I have set `org-clock-into-drawer' to 2.
>> `(org-clock-into-drawer)' should return the same value (see the
>> documentation of this function), yet it returns "LOGBOOK".
>
> Proposed patch:
>
> ----------[ begin ]----------
> diff --git a/lisp/org-clock.el b/lisp/org-clock.el
> index 07f02b0..0edc1b9 100644
> --- a/lisp/org-clock.el
> +++ b/lisp/org-clock.el
> @@ -88,6 +88,7 @@ Return value is either a string, an integer, or nil."
>     (if (org-string-match-p "\\`[0-9]+\\'" p) (string-to-number p) p))
>    ((org-string-nw-p org-clock-into-drawer))
>    ((not org-clock-into-drawer) nil)
> +  ((wholenump org-clock-into-drawer) org-clock-into-drawer)
>    ((org-log-into-drawer))
>    (t "LOGBOOK"))))
> ----------[ end ]----------

This was fixed recently. You need to update Org. Thank you for the patch
anyway.


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-02-28 18:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-27 21:20 Bug: numeric org-clock-into-drawer is ignored [8.3beta (release_8.3beta-846-g38ab8b @ /Users/vvv/lib/emacs/org-mode/lisp/)] Valery V. Vorotyntsev
2015-02-27 21:30 ` Valery V. Vorotyntsev
2015-02-28 18:28   ` Nicolas Goaziou

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).