-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Find All References does not work on function definition #810
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
Comments
@MikhailArkhipov The docs say that I should be able to set the PYTHONPATH in the .env file with a relative path. I am using Pylint in my solution as well and I get no such error - the imports are resolved just fine. You can also explicitly set PYTHONPATH in Powershell using $env:PYTHONPATH="whatever". Even if there is an import error, which in my solution there isn't, there is still some sort of bug here. |
Please change the entry as follows: Please confirm that fixes the issue. |
@DonJayamanne That did not solve the issue for me. I made the change you suggested in the .env file, closed VS Code, reopened, and click find all references. I get the same result - only a single reference to the function definition is found. Thanks for looking into this issue, which I'm sure seems minor. |
Please could you go into the If this works, then its most likely a bug in Jedi. |
@DonJayamanne Yes, go to definition is working fine. I will open a bug report on the Jedi repo and see what they think. Thanks! |
I have created a full example demonstrating the issue at the following Git repo: https://github.com/KyleMoser/findrefs/tree/master
Environment data
VS Code version: 1.20.0
Python Extension version: 2018.1.0
Python Version: 3.6, 64-bit
OS and version: Windows 10
Actual behavior
In the project, if you right click on the function definition for "configure_params" in the contrived.py file, and click "Find All References", it will not find any references outside of the current file. However, if you click "Find All References" in the prove_its_broken.py, it will find two references - one from prove_its_broken.py and the other from contrived.py.
Expected behavior
I would expect ALL references to be found when you click find all references on the function header.
Steps to reproduce:
The text was updated successfully, but these errors were encountered: