ycm-core / YouCompleteMe

A code-completion engine for Vim
http://ycm-core.github.io/YouCompleteMe/
GNU General Public License v3.0
25.44k stars 2.81k forks source link

Python completion does not show function signature #2518

Closed fabioperez closed 7 years ago

fabioperez commented 7 years ago

I want YCM to show the function signature the same way jedi-vim does. I know that YCM uses jedi-vim for Python, but I'm getting different results:

jedi-vim:

image

YouCompleteMe:

image

vheon commented 7 years ago

I know that YCM uses jedi-vim for Python

That is actually not true: YCM (ycmd actually uses JediHTTP which is a simple wrapper around jedi that is the same library that jedi-vim uses. The "show signature" feature comes from jedi-vim.

Duplicate of #234

enkeyz commented 6 years ago

Hm. My vim don't even show function signatures for python(using default config). Anyway to fix it?

ducklin5 commented 6 years ago

I know this issue is already closed, but I'm having the same issue with a python completion: image Has there been some change in python's semantic completion since then. I using python3. I was apple to get the argument information by installing jedi-vim, but I really don't want to have more plugins that I already do.

bstaletic commented 6 years ago

YCM has never provided argument hints for python. You should however have function signature and docstring in the preview window.

ducklin5 commented 6 years ago

I see, the I guess @fabioperez must have been running some additional module or function.

bstaletic commented 6 years ago

That's actually a change in jedi behaviour. That's a change we didn't really like, but also were not responsible for.

NewUserHa commented 5 years ago

python needs the signatures hint like jedi-vim.

there're far more cases but I just post two: simple usage:

import request
requests.get(

this is a very usual case which can work. but YCM has no signature hint nor preview window pop-out.

antoher usage:

with open('a.b', enco

YCM also doesn't help on this situation.

completion help ppl type less?

bstaletic commented 5 years ago

Check out #3412, it's very usable and needs perhaps a bit of polishing. Merge the PR locally and use it.

NewUserHa commented 5 years ago

thanks. and python without this makes ppl feel like a typer.

puremourning commented 5 years ago

@NewUserHa please carefully search and read the issues/faq and contributing guide before contributing. Please also consider the tone of your contributions.