From: Justin Silverman <jsilve24@gmail.com>
To: emacs-orgmode@gnu.org
Subject: bug: wrong-type-argument when trying export to pdf.
Date: Tue, 11 Oct 2022 15:08:47 -0400 [thread overview]
Message-ID: <87y1tmxjkj.fsf@gmail.com> (raw)
[-- Attachment #1.1: Type: text/plain, Size: 4332 bytes --]
I am having a problem and getting a wrong-type-argument error when trying to run `org-beamer-export-to-pdf' on the attached file `debug.org' (see backtrace below). The problem also occurs when running `org-latex-export-to-pdf'.
The bug can be reproduced using `emacs -Q' with the configuration provided in `simple-config.el'.
Note that the problem can be solved by commenting out the lines:
(org-babel-do-load-languages
'org-babel-load-languages
'((R . t)
(emacs-lisp . t)
(latex . t)))
yet doing this then makes it not possible to run C-c C-c on the R src block (without those lines you get an error about not being able to find ESS).
Am I just setting up org-babel incorrectly or is this a bug?
Best,
Justin
Backtrace:
Debugger entered--Lisp error: (wrong-type-argument number-or-marker-p nil)
jit-lock--run-functions(1218 1284)
jit-lock-fontify-now(1218 #<marker at 1284 in L4-6_CoDA.org<2>>)
#<subr font-lock-ensure>(1218 #<marker at 1284 in L4-6_CoDA.org<2>>)
polymode-inhibit-during-initialization(#<subr font-lock-ensure> 1218 #<marker at 1284 in L4-6_CoDA.org<2>>)
apply(polymode-inhibit-during-initialization #<subr font-lock-ensure> (1218 #<marker at 1284 in L4-6_CoDA.org<2>>))
font-lock-ensure(1218 #<marker at 1284 in L4-6_CoDA.org<2>>)
org-table-align()
org-babel-insert-result(((0.333333333333333) (0.333333333333333) (0.333333333333333)) ("value" "replace") ("R" "w1 <- c(1, 1, 1) \nw2 <- c(1, 1, 5) \n\nx1 <- w1/sum(..." ((:colname-names) (:rowname-names) (:result-params "value" "replace") (:result-type . value) (:results . "value replace") (:exports . "both") (:cache . "no") (:hlines . "no") (:noweb . "no") (:session . "*R*") (:tangle . "no")) "" nil 1072 "(ref:%s)") nil "R" (0 0 257283 648000))
org-babel-execute-src-block(nil ("R" "w1 <- c(1, 1, 1) \nw2 <- c(1, 1, 5) \n\nx1 <- w1/sum(..." ((:colname-names) (:rowname-names) (:result-params "replace" "value") (:result-type . value) (:results . "replace value") (:exports . "both") (:tangle . "no") (:session . "*R*") (:noweb . "no") (:hlines . "no") (:cache . "no")) "" nil 1072 "(ref:%s)"))
org-babel-exp-results(("R" "w1 <- c(1, 1, 1) \nw2 <- c(1, 1, 5) \n\nx1 <- w1/sum(..." ((:cache . "no") (:colname-names) (:exports . "both") (:hlines . "no") (:noweb . "no") (:result-params "replace" "value") (:result-type . value) (:results . "replace value") (:rowname-names) (:session . "*R*") (:tangle . "no")) "" nil 1072 "(ref:%s)") block nil "2da1507400b1866895fab4840062db146ee4de1e")
org-babel-exp-do-export(("R" "w1 <- c(1, 1, 1) \nw2 <- c(1, 1, 5) \n\nx1 <- w1/sum(..." ((:cache . "no") (:colname-names) (:exports . "both") (:hlines . "no") (:noweb . "no") (:result-params "replace" "value") (:result-type . value) (:results . "replace value") (:rowname-names) (:session . "*R*") (:tangle . "no")) "" nil 1072 "(ref:%s)") block "2da1507400b1866895fab4840062db146ee4de1e")
org-babel-exp-src-block((src-block (:language "R" :switches nil :parameters ":exports both :results value :session \"*R*\"" :begin 1072 :end 1207 :number-lines nil :preserve-indent nil :retain-labels t :use-labels t :label-fmt nil :value " w1 <- c(1, 1, 1) \n w2 <- c(1, 1, 5) \n\n x1 <- w..." :post-blank 1 :post-affiliated 1072 :mode planning :granularity element :cached nil :parent (section (:begin 1072 :end 1207 :contents-begin 1072 :contents-end 1206 :robust-begin 1072 :robust-end 1204 :post-blank 1 :post-affiliated 1072 :mode section :granularity element :cached nil :parent (headline (:raw-value "Spurious Conclusions" :begin 1047 :end 1285 :pre-blank 1 :contents-begin 1072 :contents-end 1284 :robust-begin 1074 :robust-end 1282 :level 2 :priority nil :tags nil :todo-keyword nil :todo-type nil :post-blank 1 :footnote-section-p nil :archivedp nil :commentedp nil :post-affiliated 1047 :title (...) :parent (org-data ...) :cached t :org-element--cache-sync-key (0 . 1047))) :org-element--cache-sync-key (0 . 1071))) :org-element--cache-sync-key (0 . 1072))))
org-babel-exp-process-buffer()
org-export-as(beamer nil nil nil (:output-file "L4-6_CoDA.tex"))
org-export-to-file(beamer "L4-6_CoDA.tex" nil nil nil nil nil org-latex-compile)
org-beamer-export-to-pdf()
funcall-interactively(org-beamer-export-to-pdf)
command-execute(org-beamer-export-to-pdf)
[-- Attachment #1.2: Type: text/html, Size: 7110 bytes --]
[-- Attachment #2: simple-config.el --]
[-- Type: text/plain, Size: 1405 bytes --]
;; This buffer is for text that is not saved, and for Lisp evaluation.
;; To create a file, visit it with C-x C-f and enter text in its buffer.
;; Install Straight -- per straight documentation
(defvar bootstrap-version)
(let ((bootstrap-file
(expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
(bootstrap-version 5))
(unless (file-exists-p bootstrap-file)
(with-current-buffer
(url-retrieve-synchronously
"https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
'silent 'inhibit-cookies)
(goto-char (point-max))
(eval-print-last-sexp)))
(load bootstrap-file nil 'nomessage))
;; Install use-package through straight
;; Now use-package will use straight.el to automatically install
;; missing packages if you provide :straight t:
(straight-use-package 'use-package)
; This is only needed once, near the top of the file
(eval-when-compile
;; Following line is not needed if use-package.el is in ~/.emacs.d
;; (add-to-list 'load-path "<path where use-package is installed>")
(require 'use-package))
(straight-use-package 'org)
(straight-use-package '(org-contrib :type git :host github :repo "emacsmirror/org-contrib"))
(use-package 'org
:config
(org-babel-do-load-languages
'org-babel-load-languages
'((R . t)
(emacs-lisp . t)
(latex . t)))
)
[-- Attachment #3: debug.org --]
[-- Type: application/vnd.lotus-organizer, Size: 1144 bytes --]
next reply other threads:[~2022-10-11 19:13 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-11 19:08 Justin Silverman [this message]
2022-10-12 4:08 ` bug: wrong-type-argument when trying export to pdf Ihor Radchenko
2022-10-12 14:19 ` Justin Silverman
2022-10-12 15:11 ` Justin Silverman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87y1tmxjkj.fsf@gmail.com \
--to=jsilve24@gmail.com \
--cc=emacs-orgmode@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).