Fix filename completion in Python shell (bug#77853)

'comint-filename-completion' may complete the filename at
wrong locations.  Users who want proper filename completion
should use specialized completion backends (e.g. Jedi).
* lisp/progmodes/python.el (inferior-python-mode): Remove
'comint-filename-completion' in 'comint-dynamic-complete-functions'.
This commit is contained in:
Liu Hui 2025-04-21 12:46:55 +08:00 committed by Eli Zaretskii
parent 8f58f55551
commit 46776cae05

View file

@ -3755,6 +3755,8 @@ variable.
(setq-local compilation-error-regexp-alist
python-shell-compilation-regexp-alist)
(setq-local scroll-conservatively 1)
(setq-local comint-dynamic-complete-functions
'(comint-c-a-p-replace-by-expanded-history))
(add-hook 'completion-at-point-functions
#'python-shell-completion-at-point nil 'local)
(define-key inferior-python-mode-map "\t"