From c8bfbda556b998499d8155081cc848254ee05ecd Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Fri, 8 Jan 2021 17:45:33 -0500 Subject: [PATCH] Make anaconda & pipenv integrations remote-aware Resolve paths to pipenv and python-shell-interpreter on the remote if over tramp. --- modules/lang/python/config.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/lang/python/config.el b/modules/lang/python/config.el index f1d23d19e..043045bef 100644 --- a/modules/lang/python/config.el +++ b/modules/lang/python/config.el @@ -102,7 +102,7 @@ (unless (or (bound-and-true-p lsp-mode) (bound-and-true-p eglot--managed-mode) (bound-and-true-p lsp--buffer-deferred) - (not (executable-find python-shell-interpreter))) + (not (executable-find python-shell-interpreter t))) (anaconda-mode +1)))) :config (set-company-backend! 'anaconda-mode '(company-anaconda)) @@ -207,7 +207,7 @@ (set-eval-handler! 'python-mode '((:command . (lambda () python-shell-interpreter)) (:exec (lambda () - (if-let* ((bin (executable-find "pipenv")) + (if-let* ((bin (executable-find "pipenv" t)) (_ (pipenv-project-p))) (format "PIPENV_MAX_DEPTH=9999 %s run %%c %%o %%s %%a" bin) "%c %o %s %a")))