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

Show completions ignoring what is to right of cursor #286

Closed
gramster opened this issue Aug 26, 2020 · 2 comments
Closed

Show completions ignoring what is to right of cursor #286

gramster opened this issue Aug 26, 2020 · 2 comments
Labels
bug Something isn't working fixed in next version (main) A fix has been implemented and will appear in an upcoming version

Comments

@gramster
Copy link
Member

When generating completions, I'd like them to be based on what is to the left of the cursor, so, for example, if I have:

import pandas as pd

pd.r[]

and the cursor is between the r and [, I should see completions for pd.r such as read_csv.

@erictraut
Copy link
Contributor

Thanks for the bug report. This was due to a poor interaction between the parser (which was injecting an error node into the parse tree to deal with the syntax error due to the missing expression between the square brackets) and the completion provider. The same problem occurred when the right square bracket was missing. I've improved the behavior in this case.

If you see other specific cases where completion suggestions are missing but you expect them to appear, please file more bug reports.

@erictraut erictraut added bug Something isn't working fixed in next version (main) A fix has been implemented and will appear in an upcoming version labels Aug 26, 2020
@github-actions github-actions bot removed the triage label Aug 26, 2020
@jakebailey
Copy link
Member

This issue has been fixed in version 2020.8.3, which we've just released. You can find the changelog here: https://github.com/microsoft/pylance-release/blob/master/CHANGELOG.md#202083-28-august-2020

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fixed in next version (main) A fix has been implemented and will appear in an upcoming version
Projects
None yet
Development

No branches or pull requests

3 participants