From mboxrd@z Thu Jan 1 00:00:00 1970 From: Charles Philip Chan Subject: Re: Strange Problem with "org-agenda-redo" Date: Wed, 29 Aug 2012 14:10:17 -0400 Message-ID: References: <87r4qsgvep.fsf@altern.org> <20120829095544.GA31657@debian> <877gsh4mzl.fsf@altern.org> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([208.118.235.92]:38571) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T6miL-0005rb-D3 for emacs-orgmode@gnu.org; Wed, 29 Aug 2012 14:10:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1T6miH-0000qw-G6 for emacs-orgmode@gnu.org; Wed, 29 Aug 2012 14:10:05 -0400 Received: from blu0-omc1-s9.blu0.hotmail.com ([65.55.116.20]:29160) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T6miH-0000ql-An for emacs-orgmode@gnu.org; Wed, 29 Aug 2012 14:10:01 -0400 In-Reply-To: <877gsh4mzl.fsf@altern.org> (Bastien's message of "Wed, 29 Aug 2012 19:38:38 +0200") 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-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Org-mode --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Bastien writes: Hi Bastien: > org-agenda.el is a maze, full of sound and fury. > > The various variables/situations were so entangled that the best=20 > 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-ar= guments org-agenda-overriding-cmd-arguments)) | (let ((org-agenda-overriding-arguments (if (eq org-agenda-overriding-cm= d org-cmd) (or org-agenda-overriding-arguments org-agenda-overriding-cmd-ar= guments)))) (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 cu= rrent-prefix-arg match)))) ((eq type (quote tags-todo)) (org-let2 gprops lp= rops (quote (org-tags-view (quote (4)) match)))) ((eq type (quote todo)) (o= rg-let2 gprops lprops (quote (org-todo-list match)))) ((fboundp type) (org-= let2 gprops lprops (quote (funcall type match)))) (t (error "Invalid type i= n 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-argume= nts (if (eq org-agenda-overriding-cmd org-cmd) (or org-agenda-overriding-ar= guments org-agenda-overriding-cmd-arguments)))) (cond ((eq type (quote agen= da)) (org-let2 gprops lprops (quote (call-interactively (quote org-agenda-l= ist))))) ((eq type (quote alltodo)) (org-let2 gprops lprops (quote (call-in= teractively (quote org-todo-list))))) ((eq type (quote search)) (org-let2 g= props lprops (quote (org-search-view current-prefix-arg match nil)))) ((eq = type (quote stuck)) (org-let2 gprops lprops (quote (call-interactively (quo= te org-agenda-list-stuck-projects))))) ((eq type (quote tags)) (org-let2 gp= rops lprops (quote (org-tags-view current-prefix-arg match)))) ((eq type (q= uote 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) n= ame (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 ((or= g-agenda-overriding-arguments (if (eq org-agenda-overriding-cmd org-cmd) (o= r org-agenda-overriding-arguments org-agenda-overriding-cmd-arguments)))) (= cond ((eq type (quote agenda)) (org-let2 gprops lprops (quote (call-interac= tively ...)))) ((eq type (quote alltodo)) (org-let2 gprops lprops (quote (c= all-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 typ= e (quote tags)) (org-let2 gprops lprops (quote (org-tags-view current-prefi= x-arg match)))) ((eq type (quote tags-todo)) (org-let2 gprops lprops (quote= (org-tags-view ... match)))) ((eq type (quote todo)) (org-let2 gprops lpro= ps (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-agen= da-redo-command redo) (goto-char (point-min))) | org-agenda-run-series("GTD: Today's Items" (((tags "UNFILED" ((org-agen= da-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-ignor= e-scheduled\ t nil) (org-agenda-todo-ignore-deadlines\ t nil))) (tags "STIC= KY|HOT" ((org-agenda-overriding-header "Sticky Notes, Tel Messages & Hot It= ems"))) (tags "WORK" ((org-agenda-overriding-header "Current Working Files = & Notes"))) (agenda "" ((org-agenda-span (quote day)) (org-agenda-overridin= g-header "Today: Agenda, Scheduled Actions & Info"))) (agenda "" ((org-agen= da-overriding-header "Upcoming Events (8 Days)") (org-agenda-span 8) (org-a= genda-start-day "+1d"))) (todo "STARTED" ((org-agenda-overriding-header "St= arted Actions") (org-agenda-tags-todo-honor-ignore-options\ t nil) (org-age= nda-todo-ignore-scheduled\ nil nil))) (todo "NEXT" ((org-agenda-overriding-= header "Next Actions"))) (todo "PROJECT" ((org-agenda-overriding-header "Pr= ojects List"))) (stuck "" ((org-agenda-overriding-header "Stuck Projects"))= ) (todo "PROJDONE|DONE" ((org-agenda-overriding-header "Candidates to be Ar= chived")))) 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)) (i= f org-agenda-sticky (setq org-agenda-buffer-name (or (and (stringp org-matc= h) (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 (quo= te (org-todo-list current-prefix-arg)))) ((eq type (quote search)) (org-let= lprops (quote (org-search-view current-prefix-arg org-match nil)))) ((eq t= ype (quote stuck)) (org-let lprops (quote (org-agenda-list-stuck-projects c= urrent-prefix-arg)))) ((eq type (quote tags)) (org-let lprops (quote (org-t= ags-view current-prefix-arg org-match)))) ((eq type (quote tags-todo)) (org= -let lprops (quote (org-tags-view (quote ...) org-match)))) ((eq type (quot= e todo)) (org-let lprops (quote (org-todo-list org-match)))) ((eq type (quo= te tags-tree)) (org-check-for-org-mode) (org-let lprops (quote (org-match-s= parse-tree current-prefix-arg org-match)))) ((eq type (quote todo-tree)) (o= rg-check-for-org-mode) (org-let lprops (quote (org-occur (concat "^" org-ou= tline-regexp "[ ]*" ... "\\>"))))) ((eq type (quote occur-tree)) (org-chec= k-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) (cdd= r 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-agend= a-sticky (setq org-agenda-buffer-name (or (and ... ...) (format "*Org Agend= a(%s)*" org-keys)))) (put (quote org-agenda-redo-command) (quote org-lprops= ) lprops) (cond ((eq type (quote agenda)) (org-let lprops (quote ...))) ((e= q type (quote alltodo)) (org-let lprops (quote ...))) ((eq type (quote sear= ch)) (org-let lprops (quote ...))) ((eq type (quote stuck)) (org-let lprops= (quote ...))) ((eq type (quote tags)) (org-let lprops (quote ...))) ((eq t= ype (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-tr= ee)) (org-check-for-org-mode) (org-let lprops (quote ...))) ((functionp typ= e) (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-ag= enda-custom-commands org-agenda-custom-commands-orig) (customize-variable (= quote org-agenda-custom-commands))) ((equal org-keys "a") (call-interactive= ly (quote org-agenda-list))) ((equal org-keys "s") (call-interactively (quo= te org-search-view))) ((equal org-keys "S") (org-call-with-arg (quote org-s= earch-view) (or arg (quote (4))))) ((equal org-keys "t") (call-interactivel= y (quote org-todo-list))) ((equal org-keys "T") (org-call-with-arg (quote o= rg-todo-list) (or arg (quote (4))))) ((equal org-keys "m") (call-interactiv= ely (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-interact= ively (quote org-store-agenda-views))) ((equal org-keys "?") (org-tags-view= nil "+FLAGGED") (org-add-hook (quote post-command-hook) (lambda nil (unles= s (current-message) (let* ((m ...) (note ...)) (when note (message ...)))))= t t)) ((equal org-keys "L") (unless (derived-mode-p (quote org-mode)) (err= or "This is not an Org-mode file")) (unless restriction (put (quote org-age= nda-files) (quote org-restrict) (list bfn)) (org-call-with-arg (quote org-t= imeline) arg))) ((equal org-keys "#") (call-interactively (quote org-agenda= -list-stuck-projects))) ((equal org-keys "/") (call-interactively (quote or= g-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-buf= fer-name) (org-agenda-window-setup (if (equal (buffer-name) org-agenda-buff= er-name) (quote current-window) org-agenda-window-setup)) (org-agenda-custo= m-commands-orig org-agenda-custom-commands) (org-agenda-custom-commands (de= lq nil (mapcar (lambda (x) (cond (... ... nil) (... x) (... ...) (t ...))) = org-agenda-custom-commands))) (org-agenda-custom-commands (org-contextualiz= e-keys org-agenda-custom-commands org-agenda-custom-commands-contexts)) (bu= f (current-buffer)) (bfn (buffer-file-name (buffer-base-buffer))) entry key= type org-match lprops ans) (unless org-agenda-overriding-restriction (unle= ss (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-restri= ct-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-age= nda-get-restriction-and-command prefix-descriptions) org-keys (car ans) res= triction (cdr ans))) (if org-agenda-sticky (setq org-agenda-buffer-name (fo= rmat "*Org Agenda(%s)*" org-keys))) (when (and (not org-agenda-overriding-r= estriction) restriction) (put (quote org-agenda-files) (quote org-restrict)= (list bfn)) (cond ((eq restriction (quote region)) (setq org-agenda-restri= ct t) (move-marker org-agenda-restrict-begin (region-beginning)) (move-mark= er 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 (n= th 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) lpro= ps) (cond ((eq type ...) (org-let lprops ...)) ((eq type ...) (org-let lpro= ps ...)) ((eq type ...) (org-let lprops ...)) ((eq type ...) (org-let lprop= s ...)) ((eq type ...) (org-let lprops ...)) ((eq type ...) (org-let lprops= ...)) ((eq type ...) (org-let lprops ...)) ((eq type ...) (org-check-for-o= rg-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 lprop= s ...)) (t (error "Invalid custom agenda command type %s" type)))) (org-age= nda-run-series (nth 1 entry) (cddr entry)))) ((equal org-keys "C") (setq or= g-agenda-custom-commands org-agenda-custom-commands-orig) (customize-variab= le (quote org-agenda-custom-commands))) ((equal org-keys "a") (call-interac= tively (quote org-agenda-list))) ((equal org-keys "s") (call-interactively = (quote org-search-view))) ((equal org-keys "S") (org-call-with-arg (quote o= rg-search-view) (or arg (quote (4))))) ((equal org-keys "t") (call-interact= ively (quote org-todo-list))) ((equal org-keys "T") (org-call-with-arg (quo= te org-todo-list) (or arg (quote (4))))) ((equal org-keys "m") (call-intera= ctively (quote org-tags-view))) ((equal org-keys "M") (org-call-with-arg (q= uote org-tags-view) (or arg (quote (4))))) ((equal org-keys "e") (call-inte= ractively (quote org-store-agenda-views))) ((equal org-keys "?") (org-tags-= view nil "+FLAGGED") (org-add-hook (quote post-command-hook) (lambda nil (u= nless (current-message) (let* (... ...) (when note ...)))) t t)) ((equal or= g-keys "L") (unless (derived-mode-p (quote org-mode)) (error "This is not a= n 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-proje= cts))) ((equal org-keys "/") (call-interactively (quote org-occur-in-agenda= -files))) ((equal org-keys "!") (customize-variable (quote org-stuck-projec= ts))) (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-n= ame) 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-ke= ys org-agenda-custom-commands org-agenda-custom-commands-contexts)) (buf (c= urrent-buffer)) (bfn (buffer-file-name (buffer-base-buffer))) entry key typ= e 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) (mo= ve-marker org-agenda-restrict-begin nil) (move-marker org-agenda-restrict-e= nd nil)) (put (quote org-agenda-redo-command) (quote org-lprops) nil) (put = (quote org-agenda-redo-command) (quote last-args) nil) (setq org-agenda-las= t-dispatch-buffer (current-buffer)) (unless org-keys (setq ans (org-agenda-= get-restriction-and-command prefix-descriptions) org-keys (car ans) restric= tion (cdr ans))) (if org-agenda-sticky (setq org-agenda-buffer-name (format= "*Org Agenda(%s)*" org-keys))) (when (and (not org-agenda-overriding-restr= iction) restriction) (put (quote org-agenda-files) (quote org-restrict) (li= st bfn)) (cond ((eq restriction (quote region)) (setq org-agenda-restrict t= ) (move-marker org-agenda-restrict-begin (region-beginning)) (move-marker o= rg-agenda-restrict-end (region-end))) ((eq restriction (quote subtree)) (sa= ve-excursion (setq org-agenda-restrict t) (org-back-to-heading t) (move-mar= ker org-agenda-restrict-begin (point)) (move-marker org-agenda-restrict-end= (progn ...)))))) (cond ((setq entry (assoc org-keys org-agenda-custom-comm= ands)) (if (or (symbolp (nth 2 entry)) (functionp (nth 2 entry))) (progn (s= etq type (nth 2 entry) org-match (eval ...) lprops (nth 4 entry)) (if org-a= genda-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) (cd= dr entry)))) ((equal org-keys "C") (setq org-agenda-custom-commands org-age= nda-custom-commands-orig) (customize-variable (quote org-agenda-custom-comm= ands))) ((equal org-keys "a") (call-interactively (quote org-agenda-list)))= ((equal org-keys "s") (call-interactively (quote org-search-view))) ((equa= l 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 (quo= te (4))))) ((equal org-keys "e") (call-interactively (quote org-store-agend= a-views))) ((equal org-keys "?") (org-tags-view nil "+FLAGGED") (org-add-ho= ok (quote post-command-hook) (lambda nil (unless (current-message) (let* ..= . ...))) t t)) ((equal org-keys "L") (unless (derived-mode-p (quote org-mod= e)) (error "This is not an Org-mode file")) (unless restriction (put (quote= org-agenda-files) (quote org-restrict) (list bfn)) (org-call-with-arg (quo= te org-timeline) arg))) ((equal org-keys "#") (call-interactively (quote or= g-agenda-list-stuck-projects))) ((equal org-keys "/") (call-interactively (= quote org-occur-in-agenda-files))) ((equal org-keys "!") (customize-variabl= e (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 =2D-=20 Why use Windows, since there is a door? (By fachat@galileo.rhein-neckar.de, Andre Fachat) --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (GNU/Linux) iEYEARECAAYFAlA+WxMACgkQ3epPyyKbwPZdwACg0ubU65lt9hDjWtf9H5koHty9 XB4AoIHI2IHIf1J3qvvIK5BYTbMpf8AW =fqFz -----END PGP SIGNATURE----- --=-=-=--