Emacs Builtin Python Intellisense Support

930 views Asked by At

Is there any working Intellisense/Completion in Emacs' built-in module python.el? If so how do I activate it permantenly?

Update:

When I hit C-M-i (completion-at-point) my Vanilla Emacs errors as

Debugger entered--Lisp error: (wrong-type-argument integer-or-marker-p nil)
  buffer-substring-no-properties(nil 243)
  python-shell-completion-at-point(#<process Python>)
  python-completion-at-point()
  completion--capf-wrapper(python-completion-at-point all)
  run-hook-wrapped(completion--capf-wrapper python-completion-at-point all)
  completion-at-point()
  funcall-interactively(completion-at-point)
  call-interactively(completion-at-point nil nil)
  command-execute(completion-at-point)

What have I missed?

2

There are 2 answers

0
Andrew Winterbotham On

I would personally recommend using elpy and autocomplete, using jedi as the backend for code completion.

See here and here for more detail.

1
Stefan On

AFAIK it's enabled by default. Just hit TAB when you want completion. If you want the completion candidates to be suggested in a popup menu without you hitting a special key, you can use company-mode from GNU ELPA.