1

I'm running org-mode 9.0.9 which I downloaded off of the official org-mode website. When I execute a shell code block I get the following error.

executing Shell code block...
org-babel-execute:shell: Wrong number of arguments: #[(session body &optional params stdin) "ÆÇ!ÆÈ!ÉÊ    \"AÉË   \"AÌ?ÍÎÏ!!@AÐr@q5ÑPc
<ÑcBc)r@qÒÓAÓÔ%,Õ
Ö\"ÍÎÏ!!CD×rCqc)rCqÒÓDÓÔ%,ØÙ!ErEqÚÛ
ÜÝF
#p#Þ .ËG[ßàáâãä HåæG!½çèG\"GqéÓIJKêLBLëìíp!!b`dMNM{JNM|*îïðñâB!Ñ\"OC\"\"PbòóQ!Óô#òRÓô#)õíp!!üìíp!!bJc)BKö÷ÑøóB;é!#K\"KKÔÓOIñKR\".ù\"\"Ñ#ËÉÊ    \"AÃÉÊ    \"AGÔVÃÆÇ!ÉÊ  \"AÉË   \"AÌ?ÍÎÏ!!STúrSqÑPc
¢ÑcBc)rSqÒÓTÓÔ%,Õ
Ö\"û
é\"+ËûFâB!\"UtÉü    \"AVWýW?sþW9ÿW9[W9\\W9]W9^W0_W0`W0aW>bW>UsÆc!XÍÎÏ!!YZdrYqUc)rYqÒÓZÓÔ%,eX!)*)" [stdin params padline shebang stdin-file script-file org-babel-temp-file "sh-script-" "sh-stdin-" assoc ...] 12 ("/usr/local/share/emacs/24.5/lisp/org/ob-sh.elc" . 4485)], 5
byte-code: End of buffer [2 times]
Org mode version 9.0.9 (9.0.9-dist @ /home/charvey/.emacs.d/org-9.0.9/lisp/)

The line that references /usr/local/share/emacs/24.5/lisp/org/ob-sh.elc is suspicious. I don't want to use the built-in version of org-mode. How can I fix this error? Is it because org-mode is using mixed code versions?

1 Answer 1

2

ob-sh isn't a part of the org 9, so it loads it from the bundled version, probably by mistake. You can disable the 'sh' language, and enable the 'shell' language, which works with org 9.

(org-babel-do-load-languages
 'org-babel-load-languages
 '((python . t)
   (shell . t)))

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.