emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] Strange Problem with "org-agenda-redo"


From: Charles Philip Chan
Subject: Re: [O] Strange Problem with "org-agenda-redo"
Date: Wed, 29 Aug 2012 14:10:17 -0400
User-agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.2.50 (gnu/linux)

Bastien <address@hidden> writes:

Hi Bastien:

> org-agenda.el is a maze, full of sound and fury.
>
> The various variables/situations were so entangled that the best 
> was to wipe the place out a bit.  I did so.
>
> Let me know if you still have this.  Thanks!

I can't even go into the Agenda view now. Here is the backtrace:

,----
| Debugger entered--Lisp error: (void-variable org-agenda-overriding-cmd)
|   (eq org-agenda-overriding-cmd org-cmd)
|   (if (eq org-agenda-overriding-cmd org-cmd) (or 
org-agenda-overriding-arguments org-agenda-overriding-cmd-arguments))
|   (let ((org-agenda-overriding-arguments (if (eq org-agenda-overriding-cmd 
org-cmd) (or org-agenda-overriding-arguments 
org-agenda-overriding-cmd-arguments)))) (cond ((eq type (quote agenda)) 
(org-let2 gprops lprops (quote (call-interactively (quote org-agenda-list))))) 
((eq type (quote alltodo)) (org-let2 gprops lprops (quote (call-interactively 
(quote org-todo-list))))) ((eq type (quote search)) (org-let2 gprops lprops 
(quote (org-search-view current-prefix-arg match nil)))) ((eq type (quote 
stuck)) (org-let2 gprops lprops (quote (call-interactively (quote 
org-agenda-list-stuck-projects))))) ((eq type (quote tags)) (org-let2 gprops 
lprops (quote (org-tags-view current-prefix-arg match)))) ((eq type (quote 
tags-todo)) (org-let2 gprops lprops (quote (org-tags-view (quote (4)) match)))) 
((eq type (quote todo)) (org-let2 gprops lprops (quote (org-todo-list match)))) 
((fboundp type) (org-let2 gprops lprops (quote (funcall type match)))) (t 
(error "Invalid type in command series"))))
|   (while (setq org-cmd (pop cmds)) (setq type (car org-cmd) match (eval (nth 
1 org-cmd)) lprops (nth 2 org-cmd)) (let ((org-agenda-overriding-arguments (if 
(eq org-agenda-overriding-cmd org-cmd) (or org-agenda-overriding-arguments 
org-agenda-overriding-cmd-arguments)))) (cond ((eq type (quote agenda)) 
(org-let2 gprops lprops (quote (call-interactively (quote org-agenda-list))))) 
((eq type (quote alltodo)) (org-let2 gprops lprops (quote (call-interactively 
(quote org-todo-list))))) ((eq type (quote search)) (org-let2 gprops lprops 
(quote (org-search-view current-prefix-arg match nil)))) ((eq type (quote 
stuck)) (org-let2 gprops lprops (quote (call-interactively (quote 
org-agenda-list-stuck-projects))))) ((eq type (quote tags)) (org-let2 gprops 
lprops (quote (org-tags-view current-prefix-arg match)))) ((eq type (quote 
tags-todo)) (org-let2 gprops lprops (quote (org-tags-view (quote ...) match)))) 
((eq type (quote todo)) (org-let2 gprops lprops (quote (org-todo-list match)))) 
((fboundp type) (org-let2 gprops lprops (quote (funcall type match)))) (t 
(error "Invalid type in command series")))))
|   (let* ((org-agenda-multi t) (redo (list (quote org-agenda-run-series) name 
(list (quote quote) series))) (cmds (car series)) (gprops (nth 1 series)) match 
org-cmd type lprops) (while (setq org-cmd (pop cmds)) (setq type (car org-cmd) 
match (eval (nth 1 org-cmd)) lprops (nth 2 org-cmd)) (let 
((org-agenda-overriding-arguments (if (eq org-agenda-overriding-cmd org-cmd) 
(or org-agenda-overriding-arguments org-agenda-overriding-cmd-arguments)))) 
(cond ((eq type (quote agenda)) (org-let2 gprops lprops (quote 
(call-interactively ...)))) ((eq type (quote alltodo)) (org-let2 gprops lprops 
(quote (call-interactively ...)))) ((eq type (quote search)) (org-let2 gprops 
lprops (quote (org-search-view current-prefix-arg match nil)))) ((eq type 
(quote stuck)) (org-let2 gprops lprops (quote (call-interactively ...)))) ((eq 
type (quote tags)) (org-let2 gprops lprops (quote (org-tags-view 
current-prefix-arg match)))) ((eq type (quote tags-todo)) (org-let2 gprops 
lprops (quote (org-tags-view ... match)))) ((eq type (quote todo)) (org-let2 
gprops lprops (quote (org-todo-list match)))) ((fboundp type) (org-let2 gprops 
lprops (quote (funcall type match)))) (t (error "Invalid type in command 
series"))))) (widen) (let ((inhibit-read-only t)) (add-text-properties 
(point-min) (point-max) (\` (org-serie t org-serie-redo-cmd (\, redo))))) (setq 
org-agenda-redo-command redo) (goto-char (point-min)))
|   org-agenda-run-series("GTD: Today's Items" (((tags "UNFILED" 
((org-agenda-overriding-header "Aggregated Inbox") (org-agenda-skip-entry\ 
\'regexp\ \"Inbox\" nil))) (tags "@WAITING" ((org-agenda-overriding-header 
"Wait For") (org-agenda-tags-todo-honor-ignore-options\ t nil) 
(org-agenda-todo-ignore-scheduled\ t nil) (org-agenda-todo-ignore-deadlines\ t 
nil))) (tags "STICKY|HOT" ((org-agenda-overriding-header "Sticky Notes, Tel 
Messages & Hot Items"))) (tags "WORK" ((org-agenda-overriding-header "Current 
Working Files & Notes"))) (agenda "" ((org-agenda-span (quote day)) 
(org-agenda-overriding-header "Today: Agenda, Scheduled Actions & Info"))) 
(agenda "" ((org-agenda-overriding-header "Upcoming Events (8 Days)") 
(org-agenda-span 8) (org-agenda-start-day "+1d"))) (todo "STARTED" 
((org-agenda-overriding-header "Started Actions") 
(org-agenda-tags-todo-honor-ignore-options\ t nil) 
(org-agenda-todo-ignore-scheduled\ nil nil))) (todo "NEXT" 
((org-agenda-overriding-header "Next Actions"))) (todo "PROJECT" 
((org-agenda-overriding-header "Projects List"))) (stuck "" 
((org-agenda-overriding-header "Stuck Projects"))) (todo "PROJDONE|DONE" 
((org-agenda-overriding-header "Candidates to be Archived")))) nil 
("~/Desktop/Projects/plans/Views/1_day.html")))
|   (if (or (symbolp (nth 2 entry)) (functionp (nth 2 entry))) (progn (setq 
type (nth 2 entry) org-match (eval (nth 3 entry)) lprops (nth 4 entry)) (if 
org-agenda-sticky (setq org-agenda-buffer-name (or (and (stringp org-match) 
(format "*Org Agenda(%s:%s)*" org-keys org-match)) (format "*Org Agenda(%s)*" 
org-keys)))) (put (quote org-agenda-redo-command) (quote org-lprops) lprops) 
(cond ((eq type (quote agenda)) (org-let lprops (quote (org-agenda-list 
current-prefix-arg)))) ((eq type (quote alltodo)) (org-let lprops (quote 
(org-todo-list current-prefix-arg)))) ((eq type (quote search)) (org-let lprops 
(quote (org-search-view current-prefix-arg org-match nil)))) ((eq type (quote 
stuck)) (org-let lprops (quote (org-agenda-list-stuck-projects 
current-prefix-arg)))) ((eq type (quote tags)) (org-let lprops (quote 
(org-tags-view current-prefix-arg org-match)))) ((eq type (quote tags-todo)) 
(org-let lprops (quote (org-tags-view (quote ...) org-match)))) ((eq type 
(quote todo)) (org-let lprops (quote (org-todo-list org-match)))) ((eq type 
(quote tags-tree)) (org-check-for-org-mode) (org-let lprops (quote 
(org-match-sparse-tree current-prefix-arg org-match)))) ((eq type (quote 
todo-tree)) (org-check-for-org-mode) (org-let lprops (quote (org-occur (concat 
"^" org-outline-regexp "[      ]*" ... "\\>"))))) ((eq type (quote occur-tree)) 
(org-check-for-org-mode) (org-let lprops (quote (org-occur org-match)))) 
((functionp type) (org-let lprops (quote (funcall type org-match)))) ((fboundp 
type) (org-let lprops (quote (funcall type org-match)))) (t (error "Invalid 
custom agenda command type %s" type)))) (org-agenda-run-series (nth 1 entry) 
(cddr entry)))
|   (cond ((setq entry (assoc org-keys org-agenda-custom-commands)) (if (or 
(symbolp (nth 2 entry)) (functionp (nth 2 entry))) (progn (setq type (nth 2 
entry) org-match (eval (nth 3 entry)) lprops (nth 4 entry)) (if 
org-agenda-sticky (setq org-agenda-buffer-name (or (and ... ...) (format "*Org 
Agenda(%s)*" org-keys)))) (put (quote org-agenda-redo-command) (quote 
org-lprops) lprops) (cond ((eq type (quote agenda)) (org-let lprops (quote 
...))) ((eq type (quote alltodo)) (org-let lprops (quote ...))) ((eq type 
(quote search)) (org-let lprops (quote ...))) ((eq type (quote stuck)) (org-let 
lprops (quote ...))) ((eq type (quote tags)) (org-let lprops (quote ...))) ((eq 
type (quote tags-todo)) (org-let lprops (quote ...))) ((eq type (quote todo)) 
(org-let lprops (quote ...))) ((eq type (quote tags-tree)) 
(org-check-for-org-mode) (org-let lprops (quote ...))) ((eq type (quote 
todo-tree)) (org-check-for-org-mode) (org-let lprops (quote ...))) ((eq type 
(quote occur-tree)) (org-check-for-org-mode) (org-let lprops (quote ...))) 
((functionp type) (org-let lprops (quote ...))) ((fboundp type) (org-let lprops 
(quote ...))) (t (error "Invalid custom agenda command type %s" type)))) 
(org-agenda-run-series (nth 1 entry) (cddr entry)))) ((equal org-keys "C") 
(setq org-agenda-custom-commands org-agenda-custom-commands-orig) 
(customize-variable (quote org-agenda-custom-commands))) ((equal org-keys "a") 
(call-interactively (quote org-agenda-list))) ((equal org-keys "s") 
(call-interactively (quote org-search-view))) ((equal org-keys "S") 
(org-call-with-arg (quote org-search-view) (or arg (quote (4))))) ((equal 
org-keys "t") (call-interactively (quote org-todo-list))) ((equal org-keys "T") 
(org-call-with-arg (quote org-todo-list) (or arg (quote (4))))) ((equal 
org-keys "m") (call-interactively (quote org-tags-view))) ((equal org-keys "M") 
(org-call-with-arg (quote org-tags-view) (or arg (quote (4))))) ((equal 
org-keys "e") (call-interactively (quote org-store-agenda-views))) ((equal 
org-keys "?") (org-tags-view nil "+FLAGGED") (org-add-hook (quote 
post-command-hook) (lambda nil (unless (current-message) (let* ((m ...) (note 
...)) (when note (message ...))))) t t)) ((equal org-keys "L") (unless 
(derived-mode-p (quote org-mode)) (error "This is not an Org-mode file")) 
(unless restriction (put (quote org-agenda-files) (quote org-restrict) (list 
bfn)) (org-call-with-arg (quote org-timeline) arg))) ((equal org-keys "#") 
(call-interactively (quote org-agenda-list-stuck-projects))) ((equal org-keys 
"/") (call-interactively (quote org-occur-in-agenda-files))) ((equal org-keys 
"!") (customize-variable (quote org-stuck-projects))) (t (error "Invalid agenda 
key")))
|   (let* ((prefix-descriptions nil) (org-agenda-buffer-name 
org-agenda-buffer-name) (org-agenda-window-setup (if (equal (buffer-name) 
org-agenda-buffer-name) (quote current-window) org-agenda-window-setup)) 
(org-agenda-custom-commands-orig org-agenda-custom-commands) 
(org-agenda-custom-commands (delq nil (mapcar (lambda (x) (cond (... ... nil) 
(... x) (... ...) (t ...))) org-agenda-custom-commands))) 
(org-agenda-custom-commands (org-contextualize-keys org-agenda-custom-commands 
org-agenda-custom-commands-contexts)) (buf (current-buffer)) (bfn 
(buffer-file-name (buffer-base-buffer))) entry key type org-match lprops ans) 
(unless org-agenda-overriding-restriction (unless (org-bound-and-true-p 
org-agenda-keep-restricted-file-list) (put (quote org-agenda-files) (quote 
org-restrict) nil)) (setq org-agenda-restrict nil) (move-marker 
org-agenda-restrict-begin nil) (move-marker org-agenda-restrict-end nil)) (put 
(quote org-agenda-redo-command) (quote org-lprops) nil) (put (quote 
org-agenda-redo-command) (quote last-args) nil) (setq 
org-agenda-last-dispatch-buffer (current-buffer)) (unless org-keys (setq ans 
(org-agenda-get-restriction-and-command prefix-descriptions) org-keys (car ans) 
restriction (cdr ans))) (if org-agenda-sticky (setq org-agenda-buffer-name 
(format "*Org Agenda(%s)*" org-keys))) (when (and (not 
org-agenda-overriding-restriction) restriction) (put (quote org-agenda-files) 
(quote org-restrict) (list bfn)) (cond ((eq restriction (quote region)) (setq 
org-agenda-restrict t) (move-marker org-agenda-restrict-begin 
(region-beginning)) (move-marker org-agenda-restrict-end (region-end))) ((eq 
restriction (quote subtree)) (save-excursion (setq org-agenda-restrict t) 
(org-back-to-heading t) (move-marker org-agenda-restrict-begin (point)) 
(move-marker org-agenda-restrict-end (progn (org-end-of-subtree t))))))) (cond 
((setq entry (assoc org-keys org-agenda-custom-commands)) (if (or (symbolp (nth 
2 entry)) (functionp (nth 2 entry))) (progn (setq type (nth 2 entry) org-match 
(eval (nth 3 entry)) lprops (nth 4 entry)) (if org-agenda-sticky (setq 
org-agenda-buffer-name (or ... ...))) (put (quote org-agenda-redo-command) 
(quote org-lprops) lprops) (cond ((eq type ...) (org-let lprops ...)) ((eq type 
...) (org-let lprops ...)) ((eq type ...) (org-let lprops ...)) ((eq type ...) 
(org-let lprops ...)) ((eq type ...) (org-let lprops ...)) ((eq type ...) 
(org-let lprops ...)) ((eq type ...) (org-let lprops ...)) ((eq type ...) 
(org-check-for-org-mode) (org-let lprops ...)) ((eq type ...) 
(org-check-for-org-mode) (org-let lprops ...)) ((eq type ...) 
(org-check-for-org-mode) (org-let lprops ...)) ((functionp type) (org-let 
lprops ...)) ((fboundp type) (org-let lprops ...)) (t (error "Invalid custom 
agenda command type %s" type)))) (org-agenda-run-series (nth 1 entry) (cddr 
entry)))) ((equal org-keys "C") (setq org-agenda-custom-commands 
org-agenda-custom-commands-orig) (customize-variable (quote 
org-agenda-custom-commands))) ((equal org-keys "a") (call-interactively (quote 
org-agenda-list))) ((equal org-keys "s") (call-interactively (quote 
org-search-view))) ((equal org-keys "S") (org-call-with-arg (quote 
org-search-view) (or arg (quote (4))))) ((equal org-keys "t") 
(call-interactively (quote org-todo-list))) ((equal org-keys "T") 
(org-call-with-arg (quote org-todo-list) (or arg (quote (4))))) ((equal 
org-keys "m") (call-interactively (quote org-tags-view))) ((equal org-keys "M") 
(org-call-with-arg (quote org-tags-view) (or arg (quote (4))))) ((equal 
org-keys "e") (call-interactively (quote org-store-agenda-views))) ((equal 
org-keys "?") (org-tags-view nil "+FLAGGED") (org-add-hook (quote 
post-command-hook) (lambda nil (unless (current-message) (let* (... ...) (when 
note ...)))) t t)) ((equal org-keys "L") (unless (derived-mode-p (quote 
org-mode)) (error "This is not an Org-mode file")) (unless restriction (put 
(quote org-agenda-files) (quote org-restrict) (list bfn)) (org-call-with-arg 
(quote org-timeline) arg))) ((equal org-keys "#") (call-interactively (quote 
org-agenda-list-stuck-projects))) ((equal org-keys "/") (call-interactively 
(quote org-occur-in-agenda-files))) ((equal org-keys "!") (customize-variable 
(quote org-stuck-projects))) (t (error "Invalid agenda key"))))
|   (catch (quote exit) (let* ((prefix-descriptions nil) 
(org-agenda-buffer-name org-agenda-buffer-name) (org-agenda-window-setup (if 
(equal (buffer-name) org-agenda-buffer-name) (quote current-window) 
org-agenda-window-setup)) (org-agenda-custom-commands-orig 
org-agenda-custom-commands) (org-agenda-custom-commands (delq nil (mapcar 
(lambda (x) (cond ... ... ... ...)) org-agenda-custom-commands))) 
(org-agenda-custom-commands (org-contextualize-keys org-agenda-custom-commands 
org-agenda-custom-commands-contexts)) (buf (current-buffer)) (bfn 
(buffer-file-name (buffer-base-buffer))) entry key type org-match lprops ans) 
(unless org-agenda-overriding-restriction (unless (org-bound-and-true-p 
org-agenda-keep-restricted-file-list) (put (quote org-agenda-files) (quote 
org-restrict) nil)) (setq org-agenda-restrict nil) (move-marker 
org-agenda-restrict-begin nil) (move-marker org-agenda-restrict-end nil)) (put 
(quote org-agenda-redo-command) (quote org-lprops) nil) (put (quote 
org-agenda-redo-command) (quote last-args) nil) (setq 
org-agenda-last-dispatch-buffer (current-buffer)) (unless org-keys (setq ans 
(org-agenda-get-restriction-and-command prefix-descriptions) org-keys (car ans) 
restriction (cdr ans))) (if org-agenda-sticky (setq org-agenda-buffer-name 
(format "*Org Agenda(%s)*" org-keys))) (when (and (not 
org-agenda-overriding-restriction) restriction) (put (quote org-agenda-files) 
(quote org-restrict) (list bfn)) (cond ((eq restriction (quote region)) (setq 
org-agenda-restrict t) (move-marker org-agenda-restrict-begin 
(region-beginning)) (move-marker org-agenda-restrict-end (region-end))) ((eq 
restriction (quote subtree)) (save-excursion (setq org-agenda-restrict t) 
(org-back-to-heading t) (move-marker org-agenda-restrict-begin (point)) 
(move-marker org-agenda-restrict-end (progn ...)))))) (cond ((setq entry (assoc 
org-keys org-agenda-custom-commands)) (if (or (symbolp (nth 2 entry)) 
(functionp (nth 2 entry))) (progn (setq type (nth 2 entry) org-match (eval ...) 
lprops (nth 4 entry)) (if org-agenda-sticky (setq org-agenda-buffer-name ...)) 
(put (quote org-agenda-redo-command) (quote org-lprops) lprops) (cond (... ...) 
(... ...) (... ...) (... ...) (... ...) (... ...) (... ...) (... ... ...) (... 
... ...) (... ... ...) (... ...) (... ...) (t ...))) (org-agenda-run-series 
(nth 1 entry) (cddr entry)))) ((equal org-keys "C") (setq 
org-agenda-custom-commands org-agenda-custom-commands-orig) (customize-variable 
(quote org-agenda-custom-commands))) ((equal org-keys "a") (call-interactively 
(quote org-agenda-list))) ((equal org-keys "s") (call-interactively (quote 
org-search-view))) ((equal org-keys "S") (org-call-with-arg (quote 
org-search-view) (or arg (quote (4))))) ((equal org-keys "t") 
(call-interactively (quote org-todo-list))) ((equal org-keys "T") 
(org-call-with-arg (quote org-todo-list) (or arg (quote (4))))) ((equal 
org-keys "m") (call-interactively (quote org-tags-view))) ((equal org-keys "M") 
(org-call-with-arg (quote org-tags-view) (or arg (quote (4))))) ((equal 
org-keys "e") (call-interactively (quote org-store-agenda-views))) ((equal 
org-keys "?") (org-tags-view nil "+FLAGGED") (org-add-hook (quote 
post-command-hook) (lambda nil (unless (current-message) (let* ... ...))) t t)) 
((equal org-keys "L") (unless (derived-mode-p (quote org-mode)) (error "This is 
not an Org-mode file")) (unless restriction (put (quote org-agenda-files) 
(quote org-restrict) (list bfn)) (org-call-with-arg (quote org-timeline) arg))) 
((equal org-keys "#") (call-interactively (quote 
org-agenda-list-stuck-projects))) ((equal org-keys "/") (call-interactively 
(quote org-occur-in-agenda-files))) ((equal org-keys "!") (customize-variable 
(quote org-stuck-projects))) (t (error "Invalid agenda key")))))
|   org-agenda(nil)
|   call-interactively(org-agenda nil nil)
`----

The strange thing is I clearly can see this variable when I grep
org-agenda.el.

Thanks.
Charles

-- 
Why use Windows, since there is a door?
(By address@hidden, Andre Fachat)

Attachment: pgpxoviHb_eOU.pgp
Description: PGP signature


reply via email to

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