From cd4a38058039c188d1e164acf52668e99d8f4005 Mon Sep 17 00:00:00 2001 From: Gerard Vermeulen Date: Sun, 28 Aug 2022 11:00:34 +0200 Subject: [PATCH] Leave failed switching from IPython to Python as comments --- README.org | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/README.org b/README.org index 5480d87..146051c 100644 --- a/README.org +++ b/README.org @@ -1765,8 +1765,13 @@ backward compatibility. See table [[tab:org-latex-class-tag-placeholder]] and ty (with-eval-after-load 'ob-python (custom-set-variables - '(org-babel-python-command - "ipython3 --simple-prompt --HistoryAccessor.enabled=False"))) + ;; Python hangs, but IPython does not. + ;; `(org-babel-python-command + ;; ,(concat (or (executable-find "python3") (executable-find "python")) + ;; " -E")) + `(org-babel-python-command + ,(concat (or (executable-find "ipython3") (executable-find "ipython")) + " --simple-prompt --HistoryAccessor.enabled=False")))) #+end_src #+caption[Customize =ob-python=]: @@ -3581,7 +3586,12 @@ of [[https://github.com/jorgenschaefer/pyvenv#readme][pyvenv]]). Therefore, thi `(python-flymake-command '(,(executable-find "flake8") "-")) '(python-indent-guess-indent-offset nil) '(python-shell-completion-native-disabled-interpreters '("ipython3" "pypy")) - '(python-shell-interpreter "ipython3") + ;; Python hangs, but IPython does not. + ;; `(python-shell-interpreter + ;; ,(or (executable-find "python3") (executable-find "python"))) + ;; '(python-shell-interpreter-args "-E -i") + `(python-shell-interpreter + ,(or (executable-find "ipython3") (executable-find "ipython"))) '(python-shell-interpreter-args "--simple-prompt --HistoryAccessor.enabled=False"))) #+end_src