-
Notifications
You must be signed in to change notification settings - Fork 97
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
Re-factor can only find instances of function in opened files #519
Comments
Ok this is weird it seems to work on some functions as exected but not in others, I'm not sure yet what causes some to fail and not others.... For example on the Edit: Repo in question if you wanted to test for yourselves - https://github.com/insightsengineering/rbmi |
It is a known behavior of the language server, i.e. the language server provides language features such as find references, rename, etc. within the language server workspace. More specifically,
Related: #386 |
If i'm understanding you correctly, then the behaviour I'm experiancing is a bug because both of the files shown above are in the same project & folder which is also an R package. Based on your description I wouldn't have expected the references for "validate" to work and those for "draws" not to work as they are both within the same R package. For reference the Edit: I'm assuming I need to re-raise this as a bug on the languageserver repo then ? |
From your screencasts, it seems that you are trying to find-reference or rename a symbol defined in |
ah apologies well spotted I will close this then and put any more comments in the linked issue. Thank you for looking at this ! |
This might be a limitation of vscode rather than this extension but I thought I'd raise it anyway just encase (feel free to close if its a vscode issue)
Describe the bug
Using vscodes refactor features in an R package seems to only detect occurances in files that have been opened at least once during the session. If a file has not been opened then the occurance is not detected and it will be excluded from the renaming.
In the above screenshot instances of the "draws" function are only shown from files that I have previously opened. If I haven't opened the file then the occourance of "draws" is not shown
To Reproduce
Steps to reproduce the behavior:
Do you want to fix by self? (We hope your help!)
No
Expected behavior
that all instances would be shown even if the file hasn't yet been opened
Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: