jorgenschaefer / elpy

Emacs Python Development Environment
GNU General Public License v3.0
1.9k stars 261 forks source link

Code completion suggestions break into two windows #1814

Open zd1 opened 4 years ago

zd1 commented 4 years ago

Summary

Dear Elpy developers,

Thanks for developing the tool, really helpful! I've been having some problems with the code completion suggestions. It currently breaks into two windows. From the appearance one looks like by jedi and the other one by elpy. I've pasted a screenshot in this issue for reference. This happened after I installed the rpc backend.

Steps to reproduce

Install elpy via Melpa Use the code shown below in the init file Then installed the rpc when prompted as below

   Elpy is creating the RPC virtualenv (’/Users/zd/.emacs.d/elpy/rpc-venv’)
   Automatically install the RPC dependencies from PyPI (needed for completion, autoformatting and documentation) ? y

My configuration

OS

OSX

Result of (elpy-config)

Emacs.............: 26.3
Elpy..............: 1.34.0
Virtualenv........: None
Interactive Python: /Users/zd/mini3/bin/python 3.7.6 (/Users/zd/mini3/bin/python)
RPC virtualenv....: rpc-venv (/Users/zd/.emacs.d/elpy/rpc-venv)
 Python...........: python 3.7.6 (/Users/zd/.emacs.d/elpy/rpc-venv/bin/python)
 Jedi.............: 0.17.1
 Rope.............: Not found (0.17.0 available)
 Autopep8.........: 1.5.3
 Yapf.............: 0.30.0
 Black............: Not found (19.10b0 available)
Syntax checker....: flake8 (/Users/zd/git/env-darwin-geneio/bin/flake8)

Elpy configuration in my init.el

(elpy-enable)

Thanks a lot, Zhihao Screenshot 2020-06-24 at 13 23 29

galaunay commented 3 years ago

Hi,

It looks like a problem with company.

Could you first post the result of those two commands with the cursor at a position where this happens ? M-: (elpy-rpc-get-completions) and M-: (elpy-company--add-interpreter-completions-candidates '()) Just to make sure Elpy is behaving properly.

knowing the content of your company-backends variable may be useful as well.

gopar commented 3 years ago

Also, are you using any other completion framework (eg, auto-complete?) I vaguely remember an issue like this when you have both installed.

isukonnik-exos commented 2 years ago

@zd1, did you find what was wrong? It seems like I'm having the same issue.