Description
Below I include
- a minimal Emacs init file
- a minimal org file
Attempting to export the org file to HTML (by using C-c C-e h h
) results in the error Wrong type argument: processp, nil
. A full debugger backtrace is included at the bottom.
This error can be made to disappear by removing any single one of the following three items:
(use-package elpy)
(use-package htmlize)
- The source block from the org file.
How can I resolve this problem?
Details
Configuration:
- Emacs 25.1.1
- Org mode 8.2.10
- elpy 20180406.217
- htmlize 20180328.2341
- use-package 20180314.1143
$HOME/.emacs.d/init.el
:
(require 'package)
(setq package-enable-at-startup nil)
(add-to-list 'package-archives '("melpa" . "http://melpa.org/packages/"))
(add-to-list 'package-archives '("gnu" . "http://elpa.gnu.org/packages/"))
(package-initialize)
(unless (package-installed-p 'use-package)
(package-refresh-contents)
(package-install 'use-package))
(eval-when-compile
(require 'use-package))
(setq use-package-always-ensure t)
(put 'use-package 'lisp-indent-function 1)
(use-package org
:config
(require 'ox-html) ;; Hack around backends not appearing in export dispatcher
(require 'ox-latex))
(use-package htmlize)
(use-package elpy)
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(package-selected-packages (quote (elpy htmlize use-package))))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
)
Org file
#+BEGIN_SRC shell
# comment
echo "string" > file
#+END_SRC
Debugger output
Debugger entered--Lisp error: (wrong-type-argument processp nil)
process-command(nil)
shell-mode()
org-html-fontify-code("# comment\necho \"string\" > file\n" "shell")
org-html-do-format-code("# comment\necho \"string\" > file\n" "shell" nil t nil)
org-html-format-code((src-block (:language "shell" :switches nil :parameters nil :begin 1 :end 60 :number-lines nil :preserve-indent nil :retain-labels t :use-labels t :label-fmt nil :hiddenp nil :value "# comment\necho \"string\" > file\n" :post-blank 0 :post-affiliated 1 :parent (section (:begin 1 :end 60 :contents-begin 1 :contents-end 60 :post-blank 0 :parent (org-data nil #2)) #0))) (:export-options nil :input-file "/home/jacek/DELETEME/emacs-htmlize-org-export-disaster/.emacs.d/testing.org" :input-buffer "testing.org" :html-extension "html" :html-link-org-as-html t :html-doctype "xhtml-strict" :html-container "div" :html-html5-fancy nil :html-link-use-abs-url nil :html-link-home "" :html-link-up "" :html-mathjax "" :html-postamble auto :html-preamble t :html-head "" :html-head-extra "" :html-head-include-default-style t :html-head-include-scripts t :html-table-attributes (:border "2" :cellspacing "0" :cellpadding "6" :rules "groups" :frame "hsides") :html-table-row-tags ("<tr>" . "</tr>") :html-xml-declaration (("html" . "<?xml version=\"1.0\" encoding=\"%s\"?>") ("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>")) :html-inline-images t :infojs-opt nil :creator "<a href=\"http://www.gnu.org/software/emacs/\">Emacs</a> 25.1.1 (<a href=\"http://orgmode.org\">Org</a> mode 8.2.10)" :with-latex t ...))
org-html-src-block((src-block (:language "shell" :switches nil :parameters nil :begin 1 :end 60 :number-lines nil :preserve-indent nil :retain-labels t :use-labels t :label-fmt nil :hiddenp nil :value "# comment\necho \"string\" > file\n" :post-blank 0 :post-affiliated 1 :parent (section (:begin 1 :end 60 :contents-begin 1 :contents-end 60 :post-blank 0 :parent (org-data nil #2)) #0))) nil (:export-options nil :input-file "/home/jacek/DELETEME/emacs-htmlize-org-export-disaster/.emacs.d/testing.org" :input-buffer "testing.org" :html-extension "html" :html-link-org-as-html t :html-doctype "xhtml-strict" :html-container "div" :html-html5-fancy nil :html-link-use-abs-url nil :html-link-home "" :html-link-up "" :html-mathjax "" :html-postamble auto :html-preamble t :html-head "" :html-head-extra "" :html-head-include-default-style t :html-head-include-scripts t :html-table-attributes (:border "2" :cellspacing "0" :cellpadding "6" :rules "groups" :frame "hsides") :html-table-row-tags ("<tr>" . "</tr>") :html-xml-declaration (("html" . "<?xml version=\"1.0\" encoding=\"%s\"?>") ("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>")) :html-inline-images t :infojs-opt nil :creator "<a href=\"http://www.gnu.org/software/emacs/\">Emacs</a> 25.1.1 (<a href=\"http://orgmode.org\">Org</a> mode 8.2.10)" :with-latex t ...))
org-export-data((src-block (:language "shell" :switches nil :parameters nil :begin 1 :end 60 :number-lines nil :preserve-indent nil :retain-labels t :use-labels t :label-fmt nil :hiddenp nil :value "# comment\necho \"string\" > file\n" :post-blank 0 :post-affiliated 1 :parent (section (:begin 1 :end 60 :contents-begin 1 :contents-end 60 :post-blank 0 :parent (org-data nil #2)) #0))) (:export-options nil :input-file "/home/jacek/DELETEME/emacs-htmlize-org-export-disaster/.emacs.d/testing.org" :input-buffer "testing.org" :html-extension "html" :html-link-org-as-html t :html-doctype "xhtml-strict" :html-container "div" :html-html5-fancy nil :html-link-use-abs-url nil :html-link-home "" :html-link-up "" :html-mathjax "" :html-postamble auto :html-preamble t :html-head "" :html-head-extra "" :html-head-include-default-style t :html-head-include-scripts t :html-table-attributes (:border "2" :cellspacing "0" :cellpadding "6" :rules "groups" :frame "hsides") :html-table-row-tags ("<tr>" . "</tr>") :html-xml-declaration (("html" . "<?xml version=\"1.0\" encoding=\"%s\"?>") ("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>")) :html-inline-images t :infojs-opt nil :creator "<a href=\"http://www.gnu.org/software/emacs/\">Emacs</a> 25.1.1 (<a href=\"http://orgmode.org\">Org</a> mode 8.2.10)" :with-latex t ...))
#[(element) "\302 \"\207" [element info org-export-data] 3]((src-block (:language "shell" :switches nil :parameters nil :begin 1 :end 60 :number-lines nil :preserve-indent nil :retain-labels t :use-labels t :label-fmt nil :hiddenp nil :value "# comment\necho \"string\" > file\n" :post-blank 0 :post-affiliated 1 :parent (section (:begin 1 :end 60 :contents-begin 1 :contents-end 60 :post-blank 0 :parent (org-data nil #2)) #0))))
mapconcat(#[(element) "\302 \"\207" [element info org-export-data] 3] ((src-block (:language "shell" :switches nil :parameters nil :begin 1 :end 60 :number-lines nil :preserve-indent nil :retain-labels t :use-labels t :label-fmt nil :hiddenp nil :value "# comment\necho \"string\" > file\n" :post-blank 0 :post-affiliated 1 :parent (section (:begin 1 :end 60 :contents-begin 1 :contents-end 60 :post-blank 0 :parent (org-data nil #3)) #1)))) "")
org-export-data((section (:begin 1 :end 60 :contents-begin 1 :contents-end 60 :post-blank 0 :parent (org-data nil #0)) (src-block (:language "shell" :switches nil :parameters nil :begin 1 :end 60 :number-lines nil :preserve-indent nil :retain-labels t :use-labels t :label-fmt nil :hiddenp nil :value "# comment\necho \"string\" > file\n" :post-blank 0 :post-affiliated 1 :parent #0))) (:export-options nil :input-file "/home/jacek/DELETEME/emacs-htmlize-org-export-disaster/.emacs.d/testing.org" :input-buffer "testing.org" :html-extension "html" :html-link-org-as-html t :html-doctype "xhtml-strict" :html-container "div" :html-html5-fancy nil :html-link-use-abs-url nil :html-link-home "" :html-link-up "" :html-mathjax "" :html-postamble auto :html-preamble t :html-head "" :html-head-extra "" :html-head-include-default-style t :html-head-include-scripts t :html-table-attributes (:border "2" :cellspacing "0" :cellpadding "6" :rules "groups" :frame "hsides") :html-table-row-tags ("<tr>" . "</tr>") :html-xml-declaration (("html" . "<?xml version=\"1.0\" encoding=\"%s\"?>") ("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>")) :html-inline-images t :infojs-opt nil :creator "<a href=\"http://www.gnu.org/software/emacs/\">Emacs</a> 25.1.1 (<a href=\"http://orgmode.org\">Org</a> mode 8.2.10)" :with-latex t ...))
#[(element) "\302 \"\207" [element info org-export-data] 3]((section (:begin 1 :end 60 :contents-begin 1 :contents-end 60 :post-blank 0 :parent (org-data nil #0)) (src-block (:language "shell" :switches nil :parameters nil :begin 1 :end 60 :number-lines nil :preserve-indent nil :retain-labels t :use-labels t :label-fmt nil :hiddenp nil :value "# comment\necho \"string\" > file\n" :post-blank 0 :post-affiliated 1 :parent #0))))
mapconcat(#[(element) "\302 \"\207" [element info org-export-data] 3] ((section (:begin 1 :end 60 :contents-begin 1 :contents-end 60 :post-blank 0 :parent (org-data nil #1)) (src-block (:language "shell" :switches nil :parameters nil :begin 1 :end 60 :number-lines nil :preserve-indent nil :retain-labels t :use-labels t :label-fmt nil :hiddenp nil :value "# comment\necho \"string\" > file\n" :post-blank 0 :post-affiliated 1 :parent #1)))) "")
org-export-data((org-data nil (section (:begin 1 :end 60 :contents-begin 1 :contents-end 60 :post-blank 0 :parent #0) (src-block (:language "shell" :switches nil :parameters nil :begin 1 :end 60 :number-lines nil :preserve-indent nil :retain-labels t :use-labels t :label-fmt nil :hiddenp nil :value "# comment\necho \"string\" > file\n" :post-blank 0 :post-affiliated 1 :parent #1)))) (:export-options nil :input-file "/home/jacek/DELETEME/emacs-htmlize-org-export-disaster/.emacs.d/testing.org" :input-buffer "testing.org" :html-extension "html" :html-link-org-as-html t :html-doctype "xhtml-strict" :html-container "div" :html-html5-fancy nil :html-link-use-abs-url nil :html-link-home "" :html-link-up "" :html-mathjax "" :html-postamble auto :html-preamble t :html-head "" :html-head-extra "" :html-head-include-default-style t :html-head-include-scripts t :html-table-attributes (:border "2" :cellspacing "0" :cellpadding "6" :rules "groups" :frame "hsides") :html-table-row-tags ("<tr>" . "</tr>") :html-xml-declaration (("html" . "<?xml version=\"1.0\" encoding=\"%s\"?>") ("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>")) :html-inline-images t :infojs-opt nil :creator "<a href=\"http://www.gnu.org/software/emacs/\">Emacs</a> 25.1.1 (<a href=\"http://orgmode.org\">Org</a> mode 8.2.10)" :with-latex t ...))
org-export-as(html nil nil nil (:output-file "./testing.html"))
org-export-to-file(html "./testing.html" nil nil nil nil nil)
org-html-export-to-html(nil nil nil nil)
org-export-dispatch(nil)
funcall-interactively(org-export-dispatch nil)
call-interactively(org-export-dispatch nil nil)
command-execute(org-export-dispatch)