* eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
@ 2010-12-10 17:56 Thomas S. Dye
2010-12-10 18:15 ` Nick Dokos
0 siblings, 1 reply; 14+ messages in thread
From: Thomas S. Dye @ 2010-12-10 17:56 UTC (permalink / raw)
To: emacs-orgmode list
Aloha all,
I get subject error when exporting this subtree to LaTeX:
* Export problem
#+begin_src emacs-lisp :results wrap :exports both
"code block results"
#+end_src
#+begin_src emacs-lisp :var lst=a-list :results list
(reverse lst)
#+end_src
The error goes away and LaTeX export succeeds if I get rid of
the :exports header argument in the first source block, or get rid of
the second code block.
I'm using Org-mode version 7.3 (release_7.4.2.g32f816.dirty)
All the best,
Tom
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-10 17:56 eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode) Thomas S. Dye
@ 2010-12-10 18:15 ` Nick Dokos
2010-12-10 18:27 ` Thomas S. Dye
0 siblings, 1 reply; 14+ messages in thread
From: Nick Dokos @ 2010-12-10 18:15 UTC (permalink / raw)
To: Thomas S. Dye; +Cc: nicholas.dokos, emacs-orgmode list
Thomas S. Dye <tsd@tsdye.com> wrote:
> Aloha all,
>
> I get subject error when exporting this subtree to LaTeX:
>
> * Export problem
>
> #+begin_src emacs-lisp :results wrap :exports both
> "code block results"
> #+end_src
>
> #+begin_src emacs-lisp :var lst=a-list :results list
> (reverse lst)
> #+end_src
>
> The error goes away and LaTeX export succeeds if I get rid of the
> :exports header argument in the first source block, or get rid of the
> second code block.
>
> I'm using Org-mode version 7.3 (release_7.4.2.g32f816.dirty)
>
This sounds suspiciously like something that Seb ran into a few weeks ago:
http://thread.gmane.org/gmane.emacs.orgmode/33922
but I'm not sure how that was resolved.
FWIW, I cannot reproduce it:
GNU Emacs 23.2.50.1 (i686-pc-linux-gnu, GTK+ Version 2.14.4) of 2010-10-27 on gamaville.dokosmarshall.org
Org-mode version 7.4 (release_7.4.5.gb0844.dirty)
Nick
> All the best,
> Tom
>
> _______________________________________________
> Emacs-orgmode mailing list
> Please use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
>
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-10 18:15 ` Nick Dokos
@ 2010-12-10 18:27 ` Thomas S. Dye
2010-12-10 18:34 ` Nick Dokos
` (2 more replies)
0 siblings, 3 replies; 14+ messages in thread
From: Thomas S. Dye @ 2010-12-10 18:27 UTC (permalink / raw)
To: nicholas.dokos; +Cc: emacs-orgmode list
So, Seb and I have two things that others can't reproduce: the error
in the OP, and the version string for the latest Org-mode.
Tom
On Dec 10, 2010, at 8:15 AM, Nick Dokos wrote:
> Thomas S. Dye <tsd@tsdye.com> wrote:
>
>> Aloha all,
>>
>> I get subject error when exporting this subtree to LaTeX:
>>
>> * Export problem
>>
>> #+begin_src emacs-lisp :results wrap :exports both
>> "code block results"
>> #+end_src
>>
>> #+begin_src emacs-lisp :var lst=a-list :results list
>> (reverse lst)
>> #+end_src
>>
>> The error goes away and LaTeX export succeeds if I get rid of the
>> :exports header argument in the first source block, or get rid of
>> the
>> second code block.
>>
>> I'm using Org-mode version 7.3 (release_7.4.2.g32f816.dirty)
>>
>
> This sounds suspiciously like something that Seb ran into a few
> weeks ago:
>
> http://thread.gmane.org/gmane.emacs.orgmode/33922
>
> but I'm not sure how that was resolved.
>
> FWIW, I cannot reproduce it:
>
> GNU Emacs 23.2.50.1 (i686-pc-linux-gnu, GTK+ Version 2.14.4) of
> 2010-10-27 on gamaville.dokosmarshall.org
> Org-mode version 7.4 (release_7.4.5.gb0844.dirty)
>
> Nick
>
>> All the best,
>> Tom
>>
>> _______________________________________________
>> Emacs-orgmode mailing list
>> Please use `Reply All' to send replies to the list.
>> Emacs-orgmode@gnu.org
>> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
>>
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-10 18:27 ` Thomas S. Dye
@ 2010-12-10 18:34 ` Nick Dokos
2010-12-10 18:55 ` Thomas S. Dye
2010-12-11 18:04 ` Bernt Hansen
2010-12-11 20:26 ` Sébastien Vauban
2 siblings, 1 reply; 14+ messages in thread
From: Nick Dokos @ 2010-12-10 18:34 UTC (permalink / raw)
To: Thomas S. Dye; +Cc: nicholas.dokos, emacs-orgmode list
Thomas S. Dye <tsd@tsdye.com> wrote:
> So, Seb and I have two things that others can't reproduce: the error
> in the OP, and the version string for the latest Org-mode.
>
Looks that way :-)
BTW, can you get a backtrace for the OP?
Nick
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-10 18:34 ` Nick Dokos
@ 2010-12-10 18:55 ` Thomas S. Dye
0 siblings, 0 replies; 14+ messages in thread
From: Thomas S. Dye @ 2010-12-10 18:55 UTC (permalink / raw)
To: nicholas.dokos; +Cc: emacs-orgmode list
Aloha Nick,
On Dec 10, 2010, at 8:34 AM, Nick Dokos wrote:
> Thomas S. Dye <tsd@tsdye.com> wrote:
>
>> So, Seb and I have two things that others can't reproduce: the error
>> in the OP, and the version string for the latest Org-mode.
>>
>
> Looks that way :-)
>
> BTW, can you get a backtrace for the OP?
>
> Nick
Here you go:
Debugger entered--Lisp error: (invalid-read-syntax "#")
read("(progn #+end_src\n#+begin_src emacs-lisp :var lst=a-
list :results list\n)")
(eval (read (format "(progn %s)" ...)))
(org-babel-reassemble-table (eval (read ...)) (org-babel-pick-name
(cdr ...) (cdr ...)) (org-babel-pick-name (cdr ...) (cdr ...)))
(save-window-excursion (org-babel-reassemble-table (eval ...) (org-
babel-pick-name ... ...) (org-babel-pick-name ... ...)))
org-babel-execute:emacs-lisp("#+end_src\n#+begin_src emacs-
lisp :var lst=a-list :results list\n" ((:comments . "") (:shebang .
"") (:cache . "no") (:noweb . "yes") (:tangle . "no") (:exports .
"both") (:results . "replace wrap") (:colnames . "no") (:hlines .
"yes") (:session . "none") (:result-type . value) (:result-params
"replace" "wrap") (:rowname-names) (:colname-names)))
funcall(org-babel-execute:emacs-lisp "#+end_src\n#+begin_src emacs-
lisp :var lst=a-list :results list\n" ((:comments . "") (:shebang .
"") (:cache . "no") (:noweb . "yes") (:tangle . "no") (:exports .
"both") (:results . "replace wrap") (:colnames . "no") (:hlines .
"yes") (:session . "none") (:result-type . value) (:result-params
"replace" "wrap") (:rowname-names) (:colname-names)))
((lambda (result) (cond ... ... ...)) (funcall cmd body params))
(setq result ((lambda ... ...) (funcall cmd body params)))
(if (and (not arg) new-hash (equal new-hash old-hash)) (save-
excursion (goto-char ...) (end-of-line 1) (forward-char 1) (setq
result ...) (message ...) result) (message "executing %s code block
%s..." (capitalize lang) (if ... ... "")) (setq result (... ...)) (org-
babel-insert-result result result-params info new-hash indent lang)
(run-hooks (quote org-babel-after-execute-hook)) result)
(progn (fset (quote call-process-region) (function* ...)) (unless
(fboundp cmd) (error "No org-babel-execute function for %s!" lang))
(if (and ... new-hash ...) (save-excursion ... ... ... ... ... result)
(message "executing %s code block%s..." ... ...) (setq result ...)
(org-babel-insert-result result result-params info new-hash indent
lang) (run-hooks ...) result))
(unwind-protect (progn (fset ... ...) (unless ... ...)
(if ... ... ... ... ... ... result)) (if --cl-letf-bound-- (fset ... --
cl-letf-save--) (fmakunbound ...)))
(let* ((--cl-letf-bound-- ...) (--cl-letf-save-- ...)) (unwind-
protect (progn ... ... ...) (if --cl-letf-bound-- ... ...)))
(letf ((... ...)) (unless (fboundp cmd) (error "No org-babel-
execute function for %s!" lang)) (if (and ... new-hash ...) (save-
excursion ... ... ... ... ... result) (message "executing %s code block
%s..." ... ...) (setq result ...) (org-babel-insert-result result
result-params info new-hash indent lang) (run-hooks ...) result))
(letf* ((... ...)) (unless (fboundp cmd) (error "No org-babel-
execute function for %s!" lang)) (if (and ... new-hash ...) (save-
excursion ... ... ... ... ... result) (message "executing %s code block
%s..." ... ...) (setq result ...) (org-babel-insert-result result
result-params info new-hash indent lang) (run-hooks ...) result))
(flet ((call-process-region ... ...)) (unless (fboundp cmd) (error
"No org-babel-execute function for %s!" lang)) (if (and ... new-
hash ...) (save-excursion ... ... ... ... ... result) (message
"executing %s code block%s..." ... ...) (setq result ...) (org-babel-
insert-result result result-params info new-hash indent lang) (run-
hooks ...) result))
(unwind-protect (flet (...) (unless ... ...)
(if ... ... ... ... ... ... result)) (setq call-process-region (quote
org-babel-call-process-region-original)))
(let* ((lang ...) (params ...) (cache\? ...) (result-params ...)
(new-hash ...) (old-hash ...) (body ...) (cmd ...) (dir ...) (default-
directory ...) (org-babel-call-process-region-original ...)
(indent ...) result) (unwind-protect (flet ... ... ...) (setq call-
process-region ...)))
(progn (let* (... ... ... ... ... ... ... ... ... ... ... ...
result) (unwind-protect ... ...)))
(if (org-babel-confirm-evaluate info) (progn (let* ... ...)))
(when (org-babel-confirm-evaluate info) (let*
(... ... ... ... ... ... ... ... ... ... ... ... result) (unwind-
protect ... ...)))
(let ((info ...)) (when (org-babel-confirm-evaluate info)
(let* ... ...)))
org-babel-execute-src-block(nil ("emacs-lisp" "#+end_src\n#
+begin_src emacs-lisp :var lst=a-list :results list\n" ((:comments .
"") (:shebang . "") (:cache . "no") (:noweb . "yes") (:tangle . "no")
(:exports . "both") (:results . "replace wrap") (:colnames . "no")
(:hlines . "yes") (:session . "none") (:result-type . value) (:result-
params "replace" "wrap") (:rowname-names) (:colname-names)) "" nil 0))
(cond ((equal type ...) (org-babel-execute-src-block nil info))
((equal type ...) (save-excursion ... ...)))
(prog1 nil (setf (nth 2 info) (org-babel-merge-params ... ...))
(cond (... ...) (... ...)))
(if (equal type (quote inline)) (let (... ...) (unless silent ...))
(prog1 nil (setf ... ...) (cond ... ...)))
(progn (org-babel-eval-wipe-error-buffer) (if (equal type ...)
(let ... ...) (prog1 nil ... ...)))
(if (fboundp (intern ...)) (progn (org-babel-eval-wipe-error-
buffer) (if ... ... ...)))
(when (fboundp (intern ...)) (org-babel-eval-wipe-error-buffer) (if
(equal type ...) (let ... ...) (prog1 nil ... ...)))
(let ((lang ...) (body ...)) (setf (nth 2 info) (org-babel-exp-in-
export-file ...)) (when (fboundp ...) (org-babel-eval-wipe-error-
buffer) (if ... ... ...)))
(progn (let (... ...) (setf ... ...) (when ... ... ...)))
(if org-export-babel-evaluate (progn (let ... ... ...)))
(when org-export-babel-evaluate (let (... ...) (setf ... ...)
(when ... ... ...)))
(or (when org-export-babel-evaluate (let ... ... ...)) "")
org-babel-exp-results(("emacs-lisp" "#+end_src\n#+begin_src emacs-
lisp :var lst=a-list :results list\n" ((:comments . "") (:shebang .
"") (:cache . "no") (:noweb . "yes") (:tangle . "no") (:exports .
"both") (:results . "replace wrap") (:colnames . "no") (:hlines .
"yes") (:session . "none") (:result-type . value) (:result-params
"replace" "wrap") (:rowname-names) (:colname-names)) "" nil 0) block)
(concat (org-babel-exp-code info type) "\n\n" (org-babel-exp-
results info type))
(cond ((member* --cl-var-- ...) (silently) (clean) "") ((member* --
cl-var-- ...) (silently) (clean) (org-babel-exp-code info type))
((member* --cl-var-- ...) (org-babel-exp-results info type)) ((member*
--cl-var-- ...) (concat ... "\n\n" ...)))
(let ((--cl-var-- ...)) (cond (... ... ... "") (... ... ... ...)
(... ...) (... ...)))
(case (intern (or ... "code")) ((quote none) (silently) (clean) "")
((quote code) (silently) (clean) (org-babel-exp-code info type))
((quote results) (org-babel-exp-results info type)) ((quote both)
(concat ... "\n\n" ...)))
(progn (fset (quote clean) (function* ...)) (case (intern ...)
(... ... ... "") (... ... ... ...) (... ...) (... ...)))
(unwind-protect (progn (fset ... ...) (case ... ... ... ... ...))
(if --cl-letf-bound-- (fset ... --cl-letf-save--) (fmakunbound ...)))
(let* ((--cl-letf-bound-- ...) (--cl-letf-save-- ...)) (unwind-
protect (progn ... ...) (if --cl-letf-bound-- ... ...)))
(letf ((... ...)) (case (intern ...) (... ... ... "")
(... ... ... ...) (... ...) (... ...)))
(progn (fset (quote silently) (function* ...)) (letf (...)
(case ... ... ... ... ...)))
(unwind-protect (progn (fset ... ...) (letf ... ...)) (if --cl-letf-
bound-- (fset ... --cl-letf-save--) (fmakunbound ...)))
(let* ((--cl-letf-bound-- ...) (--cl-letf-save-- ...)) (unwind-
protect (progn ... ...) (if --cl-letf-bound-- ... ...)))
(letf ((... ...)) (letf (...) (case ... ... ... ... ...)))
(letf* ((... ...) (... ...)) (case (intern ...) (... ... ... "")
(... ... ... ...) (... ...) (... ...)))
(flet ((silently nil ...) (clean nil ...)) (case (intern ...)
(... ... ... "") (... ... ... ...) (... ...) (... ...)))
org-babel-exp-do-export(("emacs-lisp" "#+end_src\n#+begin_src emacs-
lisp :var lst=a-list :results list\n" ((:comments . "") (:shebang .
"") (:cache . "no") (:noweb . "yes") (:tangle . "no") (:exports .
"both") (:results . "replace wrap") (:colnames . "no") (:hlines .
"yes") (:session . "none") (:result-type . value) (:result-params
"replace" "wrap") (:rowname-names) (:colname-names)) "" nil 0) block)
(progn (org-babel-exp-in-export-file (setf ... ...)) (setf (nth 1
info) (if ... ... ...)) (org-babel-exp-do-export info (quote block)))
(if info (progn (org-babel-exp-in-export-file ...) (setf ... ...)
(org-babel-exp-do-export info ...)))
(when info (org-babel-exp-in-export-file (setf ... ...)) (setf (nth
1 info) (if ... ... ...)) (org-babel-exp-do-export info (quote block)))
(let* ((info ...) (lang ...) (raw-params ...)) (when info (org-
babel-exp-in-export-file ...) (setf ... ...) (org-babel-exp-do-export
info ...)))
(save-excursion (goto-char (match-beginning 0)) (let* (... ... ...)
(when info ... ... ...)))
org-babel-exp-src-blocks(#("#+end_src\n#+begin_src emacs-lisp :var
lst=a-list :results list" 0 8 (font-lock-fontified t fontified nil) 8
9 (font-lock-fontified t fontified nil) 9 10 (rear-nonsticky t
fontified nil) 10 33 (font-lock-fontified t fontified nil) 33 62 (font-
lock-fontified t fontified nil)) #("emacs-lisp" 0 10 (fontified nil
font-lock-fontified t)) #(":results" 0 8 (fontified nil font-lock-
fontified t)) #("wrap" 0 4 (fontified nil font-lock-fontified t))
#(":exports" 0 8 (fontified nil font-lock-fontified t)) #("both" 0 4
(fontified nil font-lock-fontified t)))
apply(org-babel-exp-src-blocks #("#+end_src\n#+begin_src emacs-
lisp :var lst=a-list :results list" 0 8 (font-lock-fontified t
fontified nil) 8 9 (font-lock-fontified t fontified nil) 9 10 (rear-
nonsticky t fontified nil) 10 33 (font-lock-fontified t fontified nil)
33 62 (font-lock-fontified t fontified nil)) (#("emacs-lisp" 0 10
(fontified nil font-lock-fontified t)) #(":results" 0 8 (fontified nil
font-lock-fontified t)) #("wrap" 0 4 (fontified nil font-lock-
fontified t)) #(":exports" 0 8 (fontified nil font-lock-fontified t))
#("both" 0 4 (fontified nil font-lock-fontified t))))
(if (memq type org-export-blocks-witheld) "" (apply func body
headers))
(progn (if (memq type org-export-blocks-witheld) "" (apply func
body headers)))
(unwind-protect (progn (if ... "" ...)) (set-match-data save-match-
data-internal (quote evaporate)))
(let ((save-match-data-internal ...)) (unwind-protect (progn ...)
(set-match-data save-match-data-internal ...)))
(save-match-data (if (memq type org-export-blocks-witheld)
"" (apply func body headers)))
(let ((replacement ...)) (when replacement (replace-match
replacement t t) (unless preserve-indent ...)))
(progn (let (...) (when replacement ... ...)))
(if (setq func (cadr ...)) (progn (let ... ...)))
(when (setq func (cadr ...)) (let (...) (when replacement ... ...)))
(while (re-search-forward "^\\([ ]*\\)#\\+begin_\\(\\S-+\\)[ ]*\\
(.*\\)?[
\n]\\([^\0]*?\\)[
\n][ ]*#\\+end_\\S-+.*[
\n]?" nil t) (setq indentation (length ...)) (setq type (intern ...))
(setq headers (save-match-data ...)) (setq body (match-string 4))
(setq preserve-indent (or org-src-preserve-indentation ...)) (unless
preserve-indent (setq body ...)) (unless (memq type types) (setq
types ...)) (save-match-data (interblock start ...)) (when (setq
func ...) (let ... ...)) (setq start (match-end 0)))
(progn (fset (quote interblock) (function* ...)) (goto-char (point-
min)) (setq start (point)) (while (re-search-forward "^\\([ ]*\\)#\\
+begin_\\(\\S-+\\)[ ]*\\(.*\\)?[
\n]\\([^\0]*?\\)[
\n][ ]*#\\+end_\\S-+.*[
\n]?" nil t) (setq indentation ...) (setq type ...) (setq headers ...)
(setq body ...) (setq preserve-indent ...) (unless preserve-
indent ...) (unless ... ...) (save-match-data ...) (when ... ...)
(setq start ...)) (interblock start (point-max)) (run-hooks (quote org-
export-blocks-postblock-hook)))
(unwind-protect (progn (fset ... ...) (goto-char ...) (setq
start ...) (while ... ... ... ... ... ... ... ... ... ... ...)
(interblock start ...) (run-hooks ...)) (if --cl-letf-bound--
(fset ... --cl-letf-save--) (fmakunbound ...)))
(let* ((--cl-letf-bound-- ...) (--cl-letf-save-- ...)) (unwind-
protect (progn ... ... ... ... ... ...) (if --cl-letf-bound-- ... ...)))
(letf ((... ...)) (goto-char (point-min)) (setq start (point))
(while (re-search-forward "^\\([ ]*\\)#\\+begin_\\(\\S-+\\)[ ]*\\(.*\
\)?[
\n]\\([^\0]*?\\)[
\n][ ]*#\\+end_\\S-+.*[
\n]?" nil t) (setq indentation ...) (setq type ...) (setq headers ...)
(setq body ...) (setq preserve-indent ...) (unless preserve-
indent ...) (unless ... ...) (save-match-data ...) (when ... ...)
(setq start ...)) (interblock start (point-max)) (run-hooks (quote org-
export-blocks-postblock-hook)))
(letf* ((... ...)) (goto-char (point-min)) (setq start (point))
(while (re-search-forward "^\\([ ]*\\)#\\+begin_\\(\\S-+\\)[ ]*\\(.*\
\)?[
\n]\\([^\0]*?\\)[
\n][ ]*#\\+end_\\S-+.*[
\n]?" nil t) (setq indentation ...) (setq type ...) (setq headers ...)
(setq body ...) (setq preserve-indent ...) (unless preserve-
indent ...) (unless ... ...) (save-match-data ...) (when ... ...)
(setq start ...)) (interblock start (point-max)) (run-hooks (quote org-
export-blocks-postblock-hook)))
(flet ((interblock ... ...)) (goto-char (point-min)) (setq start
(point)) (while (re-search-forward "^\\([ ]*\\)#\\+begin_\\(\\S-+\\)
[ ]*\\(.*\\)?[
\n]\\([^\0]*?\\)[
\n][ ]*#\\+end_\\S-+.*[
\n]?" nil t) (setq indentation ...) (setq type ...) (setq headers ...)
(setq body ...) (setq preserve-indent ...) (unless preserve-
indent ...) (unless ... ...) (save-match-data ...) (when ... ...)
(setq start ...)) (interblock start (point-max)) (run-hooks (quote org-
export-blocks-postblock-hook)))
(let ((case-fold-search t) (types ...) indentation type func start
body headers preserve-indent progress-marker) (flet (...) (goto-
char ...) (setq start ...)
(while ... ... ... ... ... ... ... ... ... ... ...) (interblock
start ...) (run-hooks ...)))
(save-window-excursion (let (... ... indentation type func start
body headers preserve-indent progress-marker)
(flet ... ... ... ... ... ...)))
org-export-blocks-preprocess()
(save-current-buffer (set-buffer (get-buffer-create " org-mode-
tmp")) (erase-buffer) (insert string) (setq case-fold-search t) (let
(...) (remove-text-properties ... ... ...)) (org-export-kill-licensed-
text) (let (...) (org-mode)) (setq case-fold-search t) (org-install-
letbind) (run-hooks (quote org-export-preprocess-hook)) (org-export-
preprocess-apply-macros) (run-hooks (quote org-export-preprocess-after-
macros-hook)) (untabify (point-min) (point-max)) (org-export-handle-
include-files-recurse) (run-hooks (quote org-export-preprocess-after-
include-files-hook)) (org-export-remove-archived-trees archived-trees)
(org-export-remove-comment-blocks-and-subtrees) (org-export-handle-
export-tags (plist-get parameters :select-tags) (plist-get
parameters :exclude-tags)) (run-hooks (quote org-export-preprocess-
after-tree-selection-hook)) (org-export-mark-list-ending backend) (org-
export-blocks-preprocess) (org-export-replace-src-segments-and-
examples backend) (org-export-protect-colon-examples) (org-export-
convert-protected-spaces backend) (when (plist-get
parameters :footnotes) (org-footnote-normalize nil t)) (setq target-
alist (org-export-define-heading-targets target-alist)) (run-hooks
(quote org-export-preprocess-after-headline-targets-hook)) (org-export-
remember-html-container-classes) (org-export-remove-or-extract-drawers
drawers (plist-get parameters :drawers) backend) (when (plist-get
parameters :skip-before-1st-heading) (goto-char ...)
(when ... ... ... ...)) (when (plist-get parameters :add-text) (goto-
char ...) (insert ... "\n")) (org-export-remove-headline-metadata
parameters) (setq target-alist (org-export-handle-invisible-targets
target-alist)) (run-hooks (quote org-export-preprocess-before-
selecting-backend-code-hook)) (org-export-select-backend-specific-text
backend) (org-export-protect-quoted-subtrees) (org-export-remove-clock-
lines) (org-export-protect-verbatim) (org-export-mark-blockquote-verse-
center) (run-hooks (quote org-export-preprocess-after-blockquote-
hook)) (unless (plist-get parameters :timestamps) (org-export-remove-
timestamps)) (setq target-alist (org-export-attach-captions-and-
attributes backend target-alist)) (org-export-mark-radio-links) (run-
hooks (quote org-export-preprocess-after-radio-targets-hook)) (org-
export-concatenate-multiline-links) (run-hooks (quote org-export-
preprocess-before-normalizing-links-hook)) (org-export-normalize-
links) (org-export-target-internal-links target-alist) (when (plist-
get parameters :emph-multiline) (org-export-concatenate-multiline-
emphasis)) ...)
(with-current-buffer (get-buffer-create " org-mode-tmp") (erase-
buffer) (insert string) (setq case-fold-search t) (let (...) (remove-
text-properties ... ... ...)) (org-export-kill-licensed-text) (let
(...) (org-mode)) (setq case-fold-search t) (org-install-letbind) (run-
hooks (quote org-export-preprocess-hook)) (org-export-preprocess-apply-
macros) (run-hooks (quote org-export-preprocess-after-macros-hook))
(untabify (point-min) (point-max)) (org-export-handle-include-files-
recurse) (run-hooks (quote org-export-preprocess-after-include-files-
hook)) (org-export-remove-archived-trees archived-trees) (org-export-
remove-comment-blocks-and-subtrees) (org-export-handle-export-tags
(plist-get parameters :select-tags) (plist-get parameters :exclude-
tags)) (run-hooks (quote org-export-preprocess-after-tree-selection-
hook)) (org-export-mark-list-ending backend) (org-export-blocks-
preprocess) (org-export-replace-src-segments-and-examples backend)
(org-export-protect-colon-examples) (org-export-convert-protected-
spaces backend) (when (plist-get parameters :footnotes) (org-footnote-
normalize nil t)) (setq target-alist (org-export-define-heading-
targets target-alist)) (run-hooks (quote org-export-preprocess-after-
headline-targets-hook)) (org-export-remember-html-container-classes)
(org-export-remove-or-extract-drawers drawers (plist-get
parameters :drawers) backend) (when (plist-get parameters :skip-
before-1st-heading) (goto-char ...) (when ... ... ... ...)) (when
(plist-get parameters :add-text) (goto-char ...) (insert ... "\n"))
(org-export-remove-headline-metadata parameters) (setq target-alist
(org-export-handle-invisible-targets target-alist)) (run-hooks (quote
org-export-preprocess-before-selecting-backend-code-hook)) (org-export-
select-backend-specific-text backend) (org-export-protect-quoted-
subtrees) (org-export-remove-clock-lines) (org-export-protect-
verbatim) (org-export-mark-blockquote-verse-center) (run-hooks (quote
org-export-preprocess-after-blockquote-hook)) (unless (plist-get
parameters :timestamps) (org-export-remove-timestamps)) (setq target-
alist (org-export-attach-captions-and-attributes backend target-
alist)) (org-export-mark-radio-links) (run-hooks (quote org-export-
preprocess-after-radio-targets-hook)) (org-export-concatenate-
multiline-links) (run-hooks (quote org-export-preprocess-before-
normalizing-links-hook)) (org-export-normalize-links) (org-export-
target-internal-links target-alist) (when (plist-get parameters :emph-
multiline) (org-export-concatenate-multiline-emphasis)) ...)
(let* ((htmlp ...) (asciip ...) (latexp ...) (docbookp ...)
(backend ...) (archived-trees ...) (inhibit-read-only t) (drawers org-
drawers) (outline-regexp "\\*+ ") target-alist rtn) (setq org-export-
target-aliases nil org-export-preferred-target-alist nil org-export-id-
target-alist nil org-export-code-refs nil) (with-current-buffer (get-
buffer-create " org-mode-tmp") (erase-buffer) (insert string) (setq
case-fold-search t) (let ... ...) (org-export-kill-licensed-text)
(let ... ...) (setq case-fold-search t) (org-install-letbind) (run-
hooks ...) (org-export-preprocess-apply-macros) (run-hooks ...)
(untabify ... ...) (org-export-handle-include-files-recurse) (run-
hooks ...) (org-export-remove-archived-trees archived-trees) (org-
export-remove-comment-blocks-and-subtrees) (org-export-handle-export-
tags ... ...) (run-hooks ...) (org-export-mark-list-ending backend)
(org-export-blocks-preprocess) (org-export-replace-src-segments-and-
examples backend) (org-export-protect-colon-examples) (org-export-
convert-protected-spaces backend) (when ... ...) (setq target-
alist ...) (run-hooks ...) (org-export-remember-html-container-
classes) (org-export-remove-or-extract-drawers drawers ... backend)
(when ... ... ...) (when ... ... ...) (org-export-remove-headline-
metadata parameters) (setq target-alist ...) (run-hooks ...) (org-
export-select-backend-specific-text backend) (org-export-protect-
quoted-subtrees) (org-export-remove-clock-lines) (org-export-protect-
verbatim) (org-export-mark-blockquote-verse-center) (run-hooks ...)
(unless ... ...) (setq target-alist ...) (org-export-mark-radio-links)
(run-hooks ...) (org-export-concatenate-multiline-links) (run-
hooks ...) (org-export-normalize-links) (org-export-target-internal-
links target-alist) (when ... ...) ...) (kill-buffer " org-mode-tmp")
rtn)
org-export-preprocess-string(#("* Export problem\n\n#+begin_src
emacs-lisp :results wrap :exports both\n \"code block results\"\n#
+end_src\n\n#+begin_src emacs-lisp :var lst=a-list :results list\n
(reverse lst)\n#+end_src\n\n" 0 2 (fontified nil :org-license-to-kill
t) 2 16 (fontified nil :org-license-to-kill t) 16 17 (fontified
nil :org-license-to-kill t) 17 18 (fontified nil :org-license-to-kill
t) 18 68 (font-lock-fontified t fontified nil) 68 69 (font-lock-
fontified t fontified nil) 69 72 (font-lock-fontified t fontified
nil :org-license-to-kill t) 72 73 (font-lock-fontified t fontified
nil :org-license-to-kill t) 73 92 (font-lock-fontified t fontified
nil :org-license-to-kill t) 92 93 (font-lock-fontified t fontified
nil :org-license-to-kill t) 93 101 (font-lock-fontified t fontified
nil) 101 102 (font-lock-fontified t fontified nil) 102 103 (rear-
nonsticky t fontified nil) 103 104 (fontified nil :org-license-to-kill
t) 104 127 (font-lock-fontified t fontified nil) 127 156 (font-lock-
fontified t fontified nil) 156 157 (font-lock-fontified t fontified
nil) 157 160 (font-lock-fontified t fontified nil :org-license-to-kill
t) 160 161 (font-lock-fontified t fontified nil :org-license-to-kill
t) 161 162 (font-lock-fontified t fontified nil :org-license-to-kill
t) 162 172 (font-lock-fontified t fontified nil :org-license-to-kill
t) 172 173 (rear-nonsticky t font-lock-fontified t fontified nil :org-
license-to-kill t) 173 174 (font-lock-fontified t fontified nil :org-
license-to-kill t) 174 182 (font-lock-fontified t fontified nil) 182
183 (font-lock-fontified t fontified nil) 183 184 (rear-nonsticky t
fontified nil) 184 185 (fontified nil)) :emph-multiline t :for-LaTeX
t :comments nil :tags not-in-toc :priority nil :footnotes t :drawers
nil :timestamps t :todo-keywords t :add-text nil :skip-before-1st-
heading nil :select-tags ("export") :exclude-tags ("noexport") :LaTeX-
fragments nil)
(let* ((wcf ...) (opt-plist org-export-latex-options-plist) (region-
p ...) (rbeg ...) (rend ...) (subtree-p ...) (opt-plist ...) (org-
export-latex-options-plist ...) (org-current-export-dir ...) (org-
current-export-file buffer-file-name) (title ...) (filename ...)
(filename ...) (buffer ...) (odd org-odd-levels-only) (header ...)
(skip ...) (text ...) (org-export-preprocess-hook ...) (first-
lines ...) (coding-system ...) (coding-system-for-write ...) (save-
buffer-coding-system ...) (region ...) (text ...) (string-for-
export ...)) (set-buffer buffer) (erase-buffer) (org-install-letbind)
(and (fboundp ...) (set-buffer-file-coding-system coding-system-for-
write)) (unless (or ... body-only) (insert header)) (when (and
text ...) (insert ... "\n\n")) (unless skip (insert first-lines)) (org-
export-latex-global (with-temp-buffer ... ... ...)) (unless body-only
(insert "\n\\end{document}")) (goto-char (point-min)) (while (re-
search-forward "^[ ]*\\\\item\\([ ]+\\)\\[" nil t) (delete-
region ... ...)) (goto-char (point-min)) (when (re-search-forward "\\
[TABLE-OF-CONTENTS\\]" nil t) (goto-char ...) (while ... ...) (goto-
char ...) (and ... ...)) (goto-char (point-min)) (while (re-search-
forward "^[ ]*\\\\item\\>.*\\(\\\\\\\\\\)[ ]*\\(\n\\\\label.*\\)*\n\\
\\begin" nil t) (delete-region ... ...)) (goto-char (point-min))
(while (re-search-forward "^[ ]*\\\\item\\>.*\\(\\\\\\\\\\)[ ]*\\(\n\
\\\label.*\\)*" nil t) (if ... ...)) (run-hooks (quote org-export-
latex-final-hook)) (if to-buffer (unless ... ...) (save-buffer)) (org-
export-latex-fix-inputenc) (run-hooks (quote org-export-latex-after-
save-hook)) (goto-char (point-min)) (or (org-export-push-to-kill-ring
"LaTeX") (message "Exporting to LaTeX...done")) (prog1
(if ... ... ...) (set-window-configuration wcf)))
org-export-as-latex(nil)
call-interactively(org-export-as-latex)
(if (and bg (nth 2 ass) (not ...) (not ...)) (let (...) (set-
process-sentinel p ...) (message "Background process \"%s\": started"
p)) (if subtree-p (progn ... ...)) (call-interactively (nth 1 ass))
(when (and bpos ...) (let ... ... ... ... ...)))
(let* ((bg ...) subtree-p (help "[t] insert the export option
template\n[v] limit export to visible part of outline tree\n[1]
only export the current subtree\n[SPC] publish enclosing subtree (with
LaTeX_CLASS or EXPORT_FILE_NAME prop)\n\n[a/n/u] export as ASCII/
Latin-1/UTF-8 [A/N/U] to temporary buffer\n\n[h] export as
HTML [H] to temporary buffer [R] export region\n[b] export as
HTML and open in browser\n\n[l] export as LaTeX [L] to temporary
buffer\n[p] export as LaTeX and process to PDF [d] ... and
open PDF file\n\n[D] export as DocBook [V] export as DocBook,
process to PDF, and open\n\n[j] export as
TaskJuggler [J] ... and open\n\n[m] export as
Freemind mind map\n[x] export as XOXO\n[g] export using Wes Hardaker's
generic exporter\n\n[i] export current file as iCalendar file\n[I]
export all agenda files as iCalendar files [c] ...as one combined
file\n\n[F] publish current file [P] publish current project
\n[X] publish a project... [E] publish every projects")
(cmds ...) r1 r2 ass (cpos ...) (cbuf ...) bpos) (save-excursion (save-
window-excursion ... ... ... ... ... ... ...)) (and bpos (goto-char
bpos)) (setq r2 (if ... ... r1)) (unless (setq ass ...) (error "No
command associated with key %c" r1)) (if (and bg ... ... ...)
(let ... ... ...) (if subtree-p ...) (call-interactively ...)
(when ... ...)))
org-export(nil)
call-interactively(org-export nil nil)
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-10 18:27 ` Thomas S. Dye
2010-12-10 18:34 ` Nick Dokos
@ 2010-12-11 18:04 ` Bernt Hansen
2010-12-11 18:51 ` Nick Dokos
2010-12-11 20:26 ` Sébastien Vauban
2 siblings, 1 reply; 14+ messages in thread
From: Bernt Hansen @ 2010-12-11 18:04 UTC (permalink / raw)
To: Thomas S. Dye; +Cc: nicholas.dokos, emacs-orgmode list
"Thomas S. Dye" <tsd@tsdye.com> writes:
> So, Seb and I have two things that others can't reproduce: the error
> in the OP, and the version string for the latest Org-mode.
>
>>>
>>> I'm using Org-mode version 7.3 (release_7.4.2.g32f816.dirty)
>>>
>>
>>
>> FWIW, I cannot reproduce it:
>>
>> GNU Emacs 23.2.50.1 (i686-pc-linux-gnu, GTK+ Version 2.14.4) of
>> 2010-10-27 on gamaville.dokosmarshall.org
>> Org-mode version 7.4 (release_7.4.5.gb0844.dirty)
The version string problem is reproducible. At commit 32f816 (2 commits
after the release_7.4 tag) the version number is 7.3 even though it is
after the release_7.4 tag.
In b0844 (5 commits after the release_7.4 tag) this problem has been
fixed which is why Nick doesn't see it.
HTH,
Bernt
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-11 18:04 ` Bernt Hansen
@ 2010-12-11 18:51 ` Nick Dokos
0 siblings, 0 replies; 14+ messages in thread
From: Nick Dokos @ 2010-12-11 18:51 UTC (permalink / raw)
To: Bernt Hansen; +Cc: nicholas.dokos, emacs-orgmode list
Bernt Hansen <bernt@norang.ca> wrote:
> "Thomas S. Dye" <tsd@tsdye.com> writes:
>
> > So, Seb and I have two things that others can't reproduce: the error
> > in the OP, and the version string for the latest Org-mode.
> >
> >>>
> >>> I'm using Org-mode version 7.3 (release_7.4.2.g32f816.dirty)
> >>>
> >>
> >>
> >> FWIW, I cannot reproduce it:
> >>
> >> GNU Emacs 23.2.50.1 (i686-pc-linux-gnu, GTK+ Version 2.14.4) of
> >> 2010-10-27 on gamaville.dokosmarshall.org
> >> Org-mode version 7.4 (release_7.4.5.gb0844.dirty)
>
> The version string problem is reproducible. At commit 32f816 (2 commits
> after the release_7.4 tag) the version number is 7.3 even though it is
> after the release_7.4 tag.
>
> In b0844 (5 commits after the release_7.4 tag) this problem has been
> fixed which is why Nick doesn't see it.
>
I was really talking about the latex-export/eval problem that Tom is
seeing, not the version string problem.
Speaking of the eval problem, I notice in the backtrace[fn:1] that Tom
posted that org-babel-exp-src-blocks is called with
"#+end_src\n#+begin_src emacs-lisp :var lst=a-list :results list" as
argument:
org-babel-exp-src-blocks(#("#+end_src\n#+begin_src emacs-lisp :var lst=a-list :results list" ...)
But when I latex-export the same blocks through my setup (I edebug
org-babel-exp-src-blocks and when it stops, I evaluate the variable
``body''), org-babel-exp-src-blocks is called twice with the *body* of
each of the blocks as argument:
o the first time I get: #("\"code block results\"" 0 20 (fontified nil font-lock-fontified t))
o the second time I get: #("(reverse lst)" 0 13 (fontified nil font-lock-fontified t))
So it looks as if the parsing somehow gets out of sync in Tom's case,
but I don't understand why or how. In my case, the latex export goes
through with no problems.
Nick
Footnotes:
[fn:1] A backtrace of Tolstoian proportions...
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-10 18:27 ` Thomas S. Dye
2010-12-10 18:34 ` Nick Dokos
2010-12-11 18:04 ` Bernt Hansen
@ 2010-12-11 20:26 ` Sébastien Vauban
2010-12-11 22:14 ` Thomas S. Dye
2 siblings, 1 reply; 14+ messages in thread
From: Sébastien Vauban @ 2010-12-11 20:26 UTC (permalink / raw)
To: emacs-orgmode-mXXj517/zsQ
Hi Thomas, Nick and others,
"Thomas S. Dye" wrote:
> On Dec 10, 2010, at 8:15 AM, Nick Dokos wrote:
>> Thomas S. Dye <tsd-P0awH739Ni4AvxtiuMwx3w@public.gmane.org> wrote:
> So, Seb and I have two things that others can't reproduce: the error in the
> OP, and the version string for the latest Org-mode.
Let's say it's an honor to share things with you ;-)
>>> I'm using Org-mode version 7.3 (release_7.4.2.g32f816.dirty)
First, regarding the string problem, as just reported, that has been fixed.
Org-mode version 7.4 (release_7.4.6.g561c0)
>>> I get subject error when exporting this subtree to LaTeX:
>>>
>>> * Export problem
>>>
>>> #+begin_src emacs-lisp :results wrap :exports both
>>> "code block results"
>>> #+end_src
>>>
>>> #+begin_src emacs-lisp :var lst=a-list :results list
>>> (reverse lst)
>>> #+end_src
>>>
>>> The error goes away and LaTeX export succeeds if I get rid of the :exports
>>> header argument in the first source block, or get rid of the second code
>>> block.
>>
>> This sounds suspiciously like something that Seb ran into a few weeks ago:
>>
>> http://thread.gmane.org/gmane.emacs.orgmode/33922
>>
>> but I'm not sure how that was resolved.
I cannot really say it has been resolved. It simply disappeared after I came
back to a more standard version. I had applied a couple of patches from Eric
(Org RESULT block) and Dan (fontification minibug), and just git pulled to
come back to the master branch.
After that, and with no native fontification anymore[1], it did not occur
again. But I don't think it has been solved. Simply it occurs in particular
contexts.
>> FWIW, I cannot reproduce it:
I did export the above both to HTML and PDF with no problem. First code block
is run, and results exported; second simply exported.
Sorry. Do you still have the problem with current current current git? No
sandbox with extra patches?
Best regards,
Seb
Footnotes:
[1] "No native fontification" is still my current standard, among others
because of the fontification minibug -- not yet applied by Dan --, and
because I need more visibility of code blocks inside the prose -- see my
patch, not yet accepted, and hopefully other coming patches to add new
faces to the Babel lines).
--
Sébastien Vauban
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode-mXXj517/zsQ@public.gmane.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-11 20:26 ` Sébastien Vauban
@ 2010-12-11 22:14 ` Thomas S. Dye
2010-12-11 23:06 ` Nick Dokos
2010-12-12 22:57 ` Nick Dokos
0 siblings, 2 replies; 14+ messages in thread
From: Thomas S. Dye @ 2010-12-11 22:14 UTC (permalink / raw)
To: Sébastien Vauban; +Cc: emacs-orgmode
Aloha Seb,
Thanks for looking into this. I pulled as you suggested and now get
consistent version strings. I'm pleased that we share a solution to
that inconsistency. Thanks!
The other problem persists. I put the example in its own buffer and
was able to export the entire buffer without problem.
Are you able to export a subtree? I get an error if I try to export
just the subtree.
The problem appears to be related to exporting results. If I
have :exports code, all is well. With :exports results or :exports
both, the error pops up.
Also, I followed your lead and switched off org-src-fontify-natively
and org-src-tabify-natively, but neither of these made the error go
away.
All the best,
Tom
On Dec 11, 2010, at 10:26 AM, Sébastien Vauban wrote:
> Hi Thomas, Nick and others,
>
> "Thomas S. Dye" wrote:
>> On Dec 10, 2010, at 8:15 AM, Nick Dokos wrote:
>>> Thomas S. Dye <tsd@tsdye.com> wrote:
>> So, Seb and I have two things that others can't reproduce: the
>> error in the
>> OP, and the version string for the latest Org-mode.
>
> Let's say it's an honor to share things with you ;-)
>
>>>> I'm using Org-mode version 7.3 (release_7.4.2.g32f816.dirty)
>
> First, regarding the string problem, as just reported, that has been
> fixed.
>
> Org-mode version 7.4 (release_7.4.6.g561c0)
>
>>>> I get subject error when exporting this subtree to LaTeX:
>>>>
>>>> * Export problem
>>>>
>>>> #+begin_src emacs-lisp :results wrap :exports both
>>>> "code block results"
>>>> #+end_src
>>>>
>>>> #+begin_src emacs-lisp :var lst=a-list :results list
>>>> (reverse lst)
>>>> #+end_src
>>>>
>>>> The error goes away and LaTeX export succeeds if I get rid of
>>>> the :exports
>>>> header argument in the first source block, or get rid of the
>>>> second code
>>>> block.
>>>
>>> This sounds suspiciously like something that Seb ran into a few
>>> weeks ago:
>>>
>>> http://thread.gmane.org/gmane.emacs.orgmode/33922
>>>
>>> but I'm not sure how that was resolved.
>
> I cannot really say it has been resolved. It simply disappeared
> after I came
> back to a more standard version. I had applied a couple of patches
> from Eric
> (Org RESULT block) and Dan (fontification minibug), and just git
> pulled to
> come back to the master branch.
>
> After that, and with no native fontification anymore[1], it did not
> occur
> again. But I don't think it has been solved. Simply it occurs in
> particular
> contexts.
>
>>> FWIW, I cannot reproduce it:
>
> I did export the above both to HTML and PDF with no problem. First
> code block
> is run, and results exported; second simply exported.
>
> Sorry. Do you still have the problem with current current current
> git? No
> sandbox with extra patches?
>
> Best regards,
> Seb
>
> Footnotes:
>
> [1] "No native fontification" is still my current standard, among
> others
> because of the fontification minibug -- not yet applied by Dan
> --, and
> because I need more visibility of code blocks inside the prose --
> see my
> patch, not yet accepted, and hopefully other coming patches to
> add new
> faces to the Babel lines).
>
> --
> Sébastien Vauban
>
>
> _______________________________________________
> Emacs-orgmode mailing list
> Please use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-11 22:14 ` Thomas S. Dye
@ 2010-12-11 23:06 ` Nick Dokos
2010-12-12 0:03 ` Sébastien Vauban
2010-12-12 22:57 ` Nick Dokos
1 sibling, 1 reply; 14+ messages in thread
From: Nick Dokos @ 2010-12-11 23:06 UTC (permalink / raw)
To: Thomas S. Dye; +Cc: Sébastien Vauban, nicholas.dokos, emacs-orgmode
[Double argh: I forgot to copy the list...]
Thomas S. Dye <tsd@tsdye.com> wrote:
> Aloha Seb,
>
> Thanks for looking into this. I pulled as you suggested and now get
> consistent version strings. I'm pleased that we share a solution to
> that inconsistency. Thanks!
>
> The other problem persists. I put the example in its own buffer and
> was able to export the entire buffer without problem.
>
> Are you able to export a subtree? I get an error if I try to export
> just the subtree.
>
> The problem appears to be related to exporting results. If I have
> :exports code, all is well. With :exports results or :exports both,
> the error pops up.
>
> Also, I followed your lead and switched off org-src-fontify-natively
> and org-src-tabify-natively, but neither of these made the error go
> away.
>
Argh - I missed the subtree part in your OP. I can reproduce the
problem when I try to export the subtree, just as you describe.
Nick
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-11 23:06 ` Nick Dokos
@ 2010-12-12 0:03 ` Sébastien Vauban
2010-12-12 0:42 ` Thomas S. Dye
0 siblings, 1 reply; 14+ messages in thread
From: Sébastien Vauban @ 2010-12-12 0:03 UTC (permalink / raw)
To: emacs-orgmode-mXXj517/zsQ
Hi Thomas and Nick,
Nick Dokos wrote:
> Thomas S. Dye <tsd-P0awH739Ni4AvxtiuMwx3w@public.gmane.org> wrote:
>> Thanks for looking into this. I pulled as you suggested and now get
>> consistent version strings. I'm pleased that we share a solution to that
>> inconsistency. Thanks!
Good start.
>> The other problem persists. I put the example in its own buffer and was
>> able to export the entire buffer without problem.
Idem.
>> Are you able to export a subtree? I get an error if I try to export just
>> the subtree.
>>
>> The problem appears to be related to exporting results. If I have :exports
>> code, all is well. With :exports results or :exports both, the error pops
>> up.
>>
>> Also, I followed your lead and switched off org-src-fontify-natively and
>> org-src-tabify-natively, but neither of these made the error go away.
>
> Argh - I missed the subtree part in your OP. I can reproduce the problem
> when I try to export the subtree, just as you describe.
With my same old good settings (no native fontification[1]) and the same
example I used a couple of hours ago, yes, I can reproduce your problem.
I wasn't aware you talked of subtree export (read too quickly, maybe).
So, export of whole buffer is OK. But export of subtree gives the exact same
error string as in your subject. So, we're now 3 getting the same problem.[2]
Best regards,
Seb
Footnotes:
[1] Did not know about `org-src-tabify-natively'... Though, it does not exist
(as variable) on my current git system!?
[2] Regarding the previous error I had (described in a previous thread), that
was when exporting the whole buffer, as I do 99% of the time. I almost
never use subtree export, hence my (too) optimistic first answer on your
problem.
--
Sébastien Vauban
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode-mXXj517/zsQ@public.gmane.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-12 0:03 ` Sébastien Vauban
@ 2010-12-12 0:42 ` Thomas S. Dye
0 siblings, 0 replies; 14+ messages in thread
From: Thomas S. Dye @ 2010-12-12 0:42 UTC (permalink / raw)
To: Sébastien Vauban; +Cc: emacs-orgmode
Sorry Seb, I typed carelessly. The variable is org-src-tab-acts-
natively.
Tom
On Dec 11, 2010, at 2:03 PM, Sébastien Vauban wrote:
> Footnotes:
> [1] Did not know about `org-src-tabify-natively'... Though, it does
> not exist
> (as variable) on my current git system!?
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-11 22:14 ` Thomas S. Dye
2010-12-11 23:06 ` Nick Dokos
@ 2010-12-12 22:57 ` Nick Dokos
2010-12-13 19:42 ` Eric Schulte
1 sibling, 1 reply; 14+ messages in thread
From: Nick Dokos @ 2010-12-12 22:57 UTC (permalink / raw)
To: Thomas S. Dye; +Cc: Sébastien Vauban, nicholas.dokos, emacs-orgmode
Thomas S. Dye <tsd@tsdye.com> wrote:
> ...
> The other problem persists. I put the example in its own buffer and
> was able to export the entire buffer without problem.
>
> Are you able to export a subtree? I get an error if I try to export
> just the subtree.
>
> The problem appears to be related to exporting results. If I have
> :exports code, all is well. With :exports results or :exports both,
> the error pops up.
>
I've been playing with the following org file (basically, Tom's example,
except for the results block that gets added when the first src block gets
executed):
--8<---------------cut here---------------start------------->8---
* Export problem
#+begin_src emacs-lisp :results wrap :exports both
"code block results"
#+end_src
#+results:
#+BEGIN_RESULT
: code block results
#+END_RESULT
#+begin_src emacs-lisp :var lst=a-list :results list
(reverse lst)
#+end_src
--8<---------------cut here---------------end--------------->8---
Exporting the whole buffer to LaTeX (C-c C-e l): no problem. Exporting
the subtree (C-c C-e 1 l): invalid read syntax: "#'. Just as Tom
described.
The problem seems to have something to do with text properties, in
particular the :org-export-license-to-kill property, but I don't know
either the code or text properties well enough to figure it
out. Nevertheless, here are some observations:
o org-export-preprocess-string creates a temp buffer, inserts its string
argument into the buffer and then does a series of transformations on
the temp buffer (among them org-export-kill-licensed-text and
org-export-blocks-preprocess), and finally scrapes what's left in the
buffer and returns it as its result. BTW, as a minor nit, this should
probably be slightly rewritten to use with-temp-buffer.
o org-export-preprocess-string is called twice: the first time, the
string argument begins on the newline before the first #+begin_src and
ends at the last #+end_src. There are no license-to-kill properties
anywhere. The second time, the string argument is the whole thing from
the asterisk to the last #+end_src. This time, the innards of the code
blocks (the actual code, of face "org-block") have
an :org-license-to-kill property, whereas the meta-lines (starting
with #+ and whose face is "org-meta-line") do not.
o When org-export-kill-licensed-text gets its hands on this buffer, it
kills the code block innards, since they possess the license-to-kill
property, leaving empty src/result blocks:
#+begin_src emacs-lisp :results wrap :exports both
#+end_src
#+results:
#+BEGIN_RESULT
#+END_RESULT
#+begin_src emacs-lisp :var lst=a-list :results list
#+end_src
o Then org-export-blocks-preprocess loops over this and blows up the first
time through its regexp-matching loop: it parses the first line as a header
and it thinks the rest (from the first #+end+_src to the last #+end_src)
is the "body" of the code block, tries to evaluate it as elisp and fails
with the invalid read syntax error.
o One experiment I tried was to comment out the call to
org-export-kill-licensed-text in org-export-preprocess-string: that's
obviously the wrong thing to do, but it does prevent the error from happening,
since the code block innards do not get deleted.
I'm not sure how any of this is supposed to work, so I cannot really go
any further with what I've got. I hope the information above is helpful
to whoever decides to take a look. Or if someone can describe how this
is supposed to work at a high level, maybe I can dig a bit further.
Thanks,
Nick
GNU Emacs 23.2.50.1 (i686-pc-linux-gnu, GTK+ Version 2.14.4) of 2010-10-27 on gamaville.dokosmarshall.org
Org-mode version 7.4 (release_7.4.13.gb65ba.dirty)
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: Re: eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode)
2010-12-12 22:57 ` Nick Dokos
@ 2010-12-13 19:42 ` Eric Schulte
0 siblings, 0 replies; 14+ messages in thread
From: Eric Schulte @ 2010-12-13 19:42 UTC (permalink / raw)
To: nicholas.dokos; +Cc: Sébastien Vauban, emacs-orgmode
Hi Nick,
Thanks for your thorough investigation below. I walked through the
steps you outlined locally and ran into the same problems, one
surprising issue is that if you export the subtree by first narrowing to
the subtree with org-narrow-to-subtree and then export the problem does
not present itself.
I don't know enough about the export mechanism to understand why
org-export-preprocess-string is called twice but it seems to me that is
the source of the problem.
I've added this as a test to the Org-mode test suite to help whoever
does know enough about the export mechanics to tell what is taking
place. This is also troubling in that it appears that even without this
error code block would be evaluated twice on export, which would not be
desirable in the case of code blocks with side-effects.
Best -- Eric
Nick Dokos <nicholas.dokos@hp.com> writes:
> Thomas S. Dye <tsd@tsdye.com> wrote:
>
>> ...
>> The other problem persists. I put the example in its own buffer and
>> was able to export the entire buffer without problem.
>>
>> Are you able to export a subtree? I get an error if I try to export
>> just the subtree.
>>
>> The problem appears to be related to exporting results. If I have
>> :exports code, all is well. With :exports results or :exports both,
>> the error pops up.
>>
>
> I've been playing with the following org file (basically, Tom's example,
> except for the results block that gets added when the first src block gets
> executed):
>
> * Export problem
>
> #+begin_src emacs-lisp :results wrap :exports both
> "code block results"
> #+end_src
>
> #+results:
> #+BEGIN_RESULT
> : code block results
> #+END_RESULT
> #+begin_src emacs-lisp :var lst=a-list :results list
> (reverse lst)
> #+end_src
>
>
> Exporting the whole buffer to LaTeX (C-c C-e l): no problem. Exporting
> the subtree (C-c C-e 1 l): invalid read syntax: "#'. Just as Tom
> described.
>
> The problem seems to have something to do with text properties, in
> particular the :org-export-license-to-kill property, but I don't know
> either the code or text properties well enough to figure it
> out. Nevertheless, here are some observations:
>
> o org-export-preprocess-string creates a temp buffer, inserts its string
> argument into the buffer and then does a series of transformations on
> the temp buffer (among them org-export-kill-licensed-text and
> org-export-blocks-preprocess), and finally scrapes what's left in the
> buffer and returns it as its result. BTW, as a minor nit, this should
> probably be slightly rewritten to use with-temp-buffer.
>
> o org-export-preprocess-string is called twice: the first time, the
> string argument begins on the newline before the first #+begin_src and
> ends at the last #+end_src. There are no license-to-kill properties
> anywhere. The second time, the string argument is the whole thing from
> the asterisk to the last #+end_src. This time, the innards of the code
> blocks (the actual code, of face "org-block") have
> an :org-license-to-kill property, whereas the meta-lines (starting
> with #+ and whose face is "org-meta-line") do not.
>
> o When org-export-kill-licensed-text gets its hands on this buffer, it
> kills the code block innards, since they possess the license-to-kill
> property, leaving empty src/result blocks:
>
> #+begin_src emacs-lisp :results wrap :exports both
> #+end_src
> #+results:
> #+BEGIN_RESULT
> #+END_RESULT
>
> #+begin_src emacs-lisp :var lst=a-list :results list
> #+end_src
>
>
> o Then org-export-blocks-preprocess loops over this and blows up the first
> time through its regexp-matching loop: it parses the first line as a header
> and it thinks the rest (from the first #+end+_src to the last #+end_src)
> is the "body" of the code block, tries to evaluate it as elisp and fails
> with the invalid read syntax error.
>
> o One experiment I tried was to comment out the call to
> org-export-kill-licensed-text in org-export-preprocess-string: that's
> obviously the wrong thing to do, but it does prevent the error from happening,
> since the code block innards do not get deleted.
>
> I'm not sure how any of this is supposed to work, so I cannot really go
> any further with what I've got. I hope the information above is helpful
> to whoever decides to take a look. Or if someone can describe how this
> is supposed to work at a high level, maybe I can dig a bit further.
>
> Thanks,
> Nick
>
> GNU Emacs 23.2.50.1 (i686-pc-linux-gnu, GTK+ Version 2.14.4) of 2010-10-27 on gamaville.dokosmarshall.org
> Org-mode version 7.4 (release_7.4.13.gb65ba.dirty)
>
>
>
>
>
>
>
>
>
>
>
> _______________________________________________
> Emacs-orgmode mailing list
> Please use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2010-12-13 19:43 UTC | newest]
Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-10 17:56 eval: Invalid read syntax: "#"Error during redisplay: (void-function -mode) Thomas S. Dye
2010-12-10 18:15 ` Nick Dokos
2010-12-10 18:27 ` Thomas S. Dye
2010-12-10 18:34 ` Nick Dokos
2010-12-10 18:55 ` Thomas S. Dye
2010-12-11 18:04 ` Bernt Hansen
2010-12-11 18:51 ` Nick Dokos
2010-12-11 20:26 ` Sébastien Vauban
2010-12-11 22:14 ` Thomas S. Dye
2010-12-11 23:06 ` Nick Dokos
2010-12-12 0:03 ` Sébastien Vauban
2010-12-12 0:42 ` Thomas S. Dye
2010-12-12 22:57 ` Nick Dokos
2010-12-13 19:42 ` Eric Schulte
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).