Fixes a bug in which incorrect completion output was displayed, for
example when point was after a closing paren.
(string-match "^\\(from\\|import\\)[ \t]" line))
(python-shell-completion--get-completions
line process python-shell-module-completion-string-code)
- (python-shell-completion--get-completions
- input process python-shell-completion-string-code)))
+ (and (> (length input) 0)
+ (python-shell-completion--get-completions
+ input process python-shell-completion-string-code))))
(completion (when completions
(try-completion input completions))))
(cond ((eq completion t)