Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python autocompletion issues #3790

Closed
CPapadim opened this issue Dec 9, 2018 · 4 comments
Closed

Python autocompletion issues #3790

CPapadim opened this issue Dec 9, 2018 · 4 comments
Labels
python issues related to the python language / extension

Comments

@CPapadim
Copy link

CPapadim commented Dec 9, 2018

I set up Theia and installed pyls and associated packages. Everything is working great except for a couple of issues with autcomplete.

Issue 1 - When importing modules
When I do this:
from matplotlib import pyplot. autocomplete won't read deeper into pyplot and won't show any module functions when the suggestion box pops up. For example, pyplot.Axes is a thing, but it won't show up as a suggestion. This is true even if I start typing pyplot.A ... with only suggestions being taken from the current file.

If I do this though:

from matplotlib.pyplot import it will suggest things (including the Axes() class) that are inside pyplot, so in that case it's reading them.

Case 2 - in the code itself after modules like pyplot is imported, doing this returns suggestions

pyplot. will show suggestions automatically.

but pyplot.Axes. will not show suggestions E.g. Axes.fill is a thing but won't show up, and the only suggestions are things taken from the current file. However, if I type pyplot.Axes.f then the fill() function shows up as a suggestion, so if I start typing the first letter, then the suggestion seems to pop up correctly, which is different behavior from the case when importing modules.

pyplot.Axes. will not show suggestions unless I type a letter first. So if I type f after the period, then functions with f like fill will show up.

On the other hand, this works:

pyplot.cm.cbook.delete_masked_points() to suggest completions along the entire path (so after pyplot, after cm, and after cbook), at each dot, so it's not necessarily an issue of the number of levels.

@CPapadim CPapadim changed the title Python autocompletion after period /dot Python autocompletion issues Dec 9, 2018
@svenefftinge
Copy link
Contributor

We are using the pyls. Did you check another IDE that uses pyls (e.g. VS Code)?
Does it have the same issues?

@CPapadim
Copy link
Author

Hmm that's a good question, I don't think I have an easy way to do that since I'm on windows and running theia in a linux docker container. I can maybe give installing monaco on the docker image a shot to verify if this behavior is due to pyls or theia.

@svenefftinge
Copy link
Contributor

No, I mean could you install VS Code locally together with the python extension that uses pyls (not the new ms one) and see if your issues can be reproduced?

@vince-fugnitto vince-fugnitto added the python issues related to the python language / extension label Jan 30, 2020
@vince-fugnitto
Copy link
Member

Closing due to inactivity and #6933.
Issues regarding Python support should now be filed against the appropriate VS Code extension if the problem persists.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
python issues related to the python language / extension
Projects
None yet
Development

No branches or pull requests

3 participants