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

Wrong reference to shadow name #14

Open
guoquan opened this issue Oct 10, 2019 · 1 comment
Open

Wrong reference to shadow name #14

guoquan opened this issue Oct 10, 2019 · 1 comment
Labels
bug Something isn't working enhancement New feature or request

Comments

@guoquan
Copy link

guoquan commented Oct 10, 2019

When I have a property of an object with the same name as a local variable, alt+click always points me to the local variable even if I want the property. An example to reproduce the error could be as follows:

name = 'hello'
obj = object()
obj.name = 'world'
print(obj.name)

and when you alt+click on name on print line, it goes to 'hello' line.

@krassowski krassowski added bug Something isn't working enhancement New feature or request labels Oct 11, 2019
@krassowski
Copy link
Owner

Thank you for reporting this issue. This behaviour is indeed not ideal, however, it might be difficult to fix with the current design of this extension.

This should be easier to implement in jupyterlab-lsp but it does not work there yet either (without any in-depth testing I think that we are currently passing .name to the LSP server but we may need to pass obj.name).

This is a useful test-case, thank you again for your feedback.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants