diff options
Diffstat (limited to 'lisp/progmodes/python.el')
| -rw-r--r-- | lisp/progmodes/python.el | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index 4f645ad64c8..f12486d0acb 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el | |||
| @@ -1905,7 +1905,7 @@ detection and just returns nil." | |||
| 1905 | (let ((code-file (python-shell--save-temp-file code))) | 1905 | (let ((code-file (python-shell--save-temp-file code))) |
| 1906 | ;; Use `process-file' as it is remote-host friendly. | 1906 | ;; Use `process-file' as it is remote-host friendly. |
| 1907 | (process-file | 1907 | (process-file |
| 1908 | (executable-find python-shell-interpreter) | 1908 | python-shell-interpreter |
| 1909 | code-file | 1909 | code-file |
| 1910 | '(t nil) | 1910 | '(t nil) |
| 1911 | nil | 1911 | nil |
| @@ -2061,11 +2061,14 @@ uniqueness for different types of configurations." | |||
| 2061 | (or python-shell-virtualenv-path "") | 2061 | (or python-shell-virtualenv-path "") |
| 2062 | (mapconcat #'identity python-shell-exec-path ""))))) | 2062 | (mapconcat #'identity python-shell-exec-path ""))))) |
| 2063 | 2063 | ||
| 2064 | (defun python-shell-parse-command () | 2064 | (defun python-shell-parse-command () ;FIXME: why name it "parse"? |
| 2065 | "Calculate the string used to execute the inferior Python process." | 2065 | "Calculate the string used to execute the inferior Python process." |
| 2066 | ;; FIXME: process-environment doesn't seem to be used anywhere within | ||
| 2067 | ;; this let. | ||
| 2066 | (let ((process-environment (python-shell-calculate-process-environment)) | 2068 | (let ((process-environment (python-shell-calculate-process-environment)) |
| 2067 | (exec-path (python-shell-calculate-exec-path))) | 2069 | (exec-path (python-shell-calculate-exec-path))) |
| 2068 | (format "%s %s" | 2070 | (format "%s %s" |
| 2071 | ;; FIXME: Why executable-find? | ||
| 2069 | (executable-find python-shell-interpreter) | 2072 | (executable-find python-shell-interpreter) |
| 2070 | python-shell-interpreter-args))) | 2073 | python-shell-interpreter-args))) |
| 2071 | 2074 | ||
| @@ -2101,11 +2104,10 @@ uniqueness for different types of configurations." | |||
| 2101 | (defun python-shell-calculate-exec-path () | 2104 | (defun python-shell-calculate-exec-path () |
| 2102 | "Calculate exec path given `python-shell-virtualenv-path'." | 2105 | "Calculate exec path given `python-shell-virtualenv-path'." |
| 2103 | (let ((path (append python-shell-exec-path | 2106 | (let ((path (append python-shell-exec-path |
| 2104 | exec-path nil))) | 2107 | exec-path nil))) ;FIXME: Why nil? |
| 2105 | (if (not python-shell-virtualenv-path) | 2108 | (if (not python-shell-virtualenv-path) |
| 2106 | path | 2109 | path |
| 2107 | (cons (format "%s/bin" | 2110 | (cons (expand-file-name "bin" python-shell-virtualenv-path) |
| 2108 | (directory-file-name python-shell-virtualenv-path)) | ||
| 2109 | path)))) | 2111 | path)))) |
| 2110 | 2112 | ||
| 2111 | (defvar python-shell--package-depth 10) | 2113 | (defvar python-shell--package-depth 10) |