Re: [O] Bug: error sorting outline items [9.0.10 (9.0.10-elpa @ c:/users/ian/.emacs.d/elpa/org-20170827/)]

2017-08-29 Thread Nicolas Goaziou
Hello,

Ian Garmaise  writes:

> Often (but not always) when I attempt to sort some headlines, the sort
> fails, and the following error message occurs (usually same after
> reloading org uncompiled)
>
> Sorting entries...
> eq: Symbol’s function definition is void: org-clocking-buffer
>
> Here is the backtrace:
>
> Debugger entered--Lisp error: (void-function org-clocking-buffer)

Fixed. Thank you.

Regards,

-- 
Nicolas Goaziou



[O] Bug: error sorting outline items [9.0.10 (9.0.10-elpa @ c:/users/ian/.emacs.d/elpa/org-20170827/)]

2017-08-29 Thread Ian Garmaise
Often (but not always) when I attempt to sort some headlines, the sort
fails, and the following error message occurs (usually same after
reloading org uncompiled)

Sorting entries...
eq: Symbol’s function definition is void: org-clocking-buffer

Here is the backtrace:

Debugger entered--Lisp error: (void-function org-clocking-buffer)
  (org-clocking-buffer)
  (eq (org-clocking-buffer) (current-buffer))
  (and (eq (org-clocking-buffer) (current-buffer)) (<= start
(marker-position org-clock-marker)) (>= end (marker-position
org-clock-marker)))
  (if (and (eq (org-clocking-buffer) (current-buffer)) (<= start
(marker-position org-clock-marker)) (>= end (marker-position
org-clock-marker))) (progn (let* ((modified (buffer-modified-p))
(buffer-undo-list t) (inhibit-read-only t) (inhibit-modification-hooks t))
(unwind-protect (progn (put-text-property (1- org-clock-marker)
org-clock-marker :org-clock-marker-backup t)) (if modified nil
(restore-buffer-modified-p nil t))
  (let ((restore-clock\? (if (and (eq (org-clocking-buffer)
(current-buffer)) (<= start (marker-position org-clock-marker)) (>= end
(marker-position org-clock-marker))) (progn (let* ((modified ...)
(buffer-undo-list t) (inhibit-read-only t) (inhibit-modification-hooks t))
(unwind-protect (progn ...) (if modified nil ...))) t))) (dcst (downcase
sorting-type)) (case-fold-search nil) (now (current-time))) (sort-subr (/=
dcst sorting-type) (function (lambda nil (if (re-search-forward re nil t)
(goto-char (match-beginning 0)) (goto-char (point-max) (function
(lambda nil (let ((save-match-data-internal (match-data))) (unwind-protect
(progn (condition-case nil ... ...)) (set-match-data
save-match-data-internal (quote evaporate)) (function (lambda nil (cond
((= dcst 110) (if (looking-at org-complex-heading-regexp) (string-to-number
...) nil)) ((= dcst 97) (if (looking-at org-complex-heading-regexp)
(funcall case-func ...) nil)) ((= dcst 107) (or (get-text-property ...
:org-clock-minutes) 0)) ((= dcst 116) (let (...) (if ... ... ...))) ((=
dcst 99) (let (...) (if ... ... ...))) ((= dcst 115) (let (...) (if ... ...
...))) ((= dcst 100) (let (...) (if ... ... ...))) ((= dcst 112) (if
(re-search-forward org-priority-regexp ... t) (string-to-char ...)
org-default-priority)) ((= dcst 114) (or (org-entry-get nil property) ""))
((= dcst 111) (if (looking-at org-complex-heading-regexp) (progn ...))) ((=
dcst 102) (if getkey-func (progn ... ... tmp) (error "Invalid key function
`%s'" getkey-func))) (t (error "Invalid sorting type `%c'"
sorting-type) nil (cond ((= dcst 97) (quote string<)) ((= dcst 102) (or
compare-func (and interactive\? (org-read-function (concat "Function for
comparing keys " "(empty for default `sort-subr' predicate): ") (quote
allow-empty) ((member dcst (quote (112 116 115 100 99 107))) (quote
< (if restore-clock\? (progn (move-marker org-clock-marker (1+
(next-single-property-change start :org-clock-marker-backup)))
(remove-text-properties (1- org-clock-marker) org-clock-marker (quote
(:org-clock-marker-backup t))
  (save-restriction (narrow-to-region start end) (let ((restore-clock\? (if
(and (eq (org-clocking-buffer) (current-buffer)) (<= start (marker-position
org-clock-marker)) (>= end (marker-position org-clock-marker))) (progn
(let* (... ... ... ...) (unwind-protect ... ...)) t))) (dcst (downcase
sorting-type)) (case-fold-search nil) (now (current-time))) (sort-subr (/=
dcst sorting-type) (function (lambda nil (if (re-search-forward re nil t)
(goto-char (match-beginning 0)) (goto-char (point-max) (function
(lambda nil (let ((save-match-data-internal ...)) (unwind-protect (progn
...) (set-match-data save-match-data-internal ...) (function (lambda
nil (cond ((= dcst 110) (if ... ... nil)) ((= dcst 97) (if ... ... nil))
((= dcst 107) (or ... 0)) ((= dcst 116) (let ... ...)) ((= dcst 99) (let
... ...)) ((= dcst 115) (let ... ...)) ((= dcst 100) (let ... ...)) ((=
dcst 112) (if ... ... org-default-priority)) ((= dcst 114) (or ... "")) ((=
dcst 111) (if ... ...)) ((= dcst 102) (if getkey-func ... ...)) (t (error
"Invalid sorting type `%c'" sorting-type) nil (cond ((= dcst 97) (quote
string<)) ((= dcst 102) (or compare-func (and interactive\?
(org-read-function ... ... ((member dcst (quote (112 116 115 100 99
107))) (quote < (if restore-clock\? (progn (move-marker
org-clock-marker (1+ (next-single-property-change start
:org-clock-marker-backup))) (remove-text-properties (1- org-clock-marker)
org-clock-marker (quote (:org-clock-marker-backup t)))
  (let ((case-func (if with-case (quote identity) (quote downcase))) start
beg end stars re re2 txt what tmp) (cond ((org-region-active-p) (setq end
(region-end) what "region") (goto-char (region-beginning)) (if
(org-at-heading-p) nil (outline-next-heading)) (setq start (point))) ((or
(org-at-heading-p) (condition-case nil (progn (progn (org-back-to-heading)
t)) (error nil))) (org-back-to-heading) (setq start (point) end (progn
(org-end-of-subtree t t)