-
Notifications
You must be signed in to change notification settings - Fork 765
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
Mark deprecated CompletionItem
#6949
Comments
I requested the same thing here: #6149. |
@Viicos Thank you for the hint. I did not see that issue because I was only searching for it here. (perhaps question to maintainers:) Does it have to be a Pylance-exclusive feature? I believe since Pyright also provides completions this could be implemented here. |
Yes it's a bit tricky to know in which repository this should be reported, when in doubt I usually report to Pylance and the issue gets transferred if necessary ;) |
it looks like sadly your original issue (converted to a discussion) didn't get any response. let's hope it gets more activity over here. I am just gonna link to this issue in your discussion so that the progress can be tracked across both repositories |
LSP functionality is maintained by the pylance team, so I'll leave it to them to consider this enhancement request. Could someone from the pylance team please transfer this issue to pylance-release and triage / prioritize it as you see fit? Thanks! |
Resolving as a duplicate of #6179. At the moment this isn't really on our radar. If it gets more up-votes from the community, we'll consider adding it to our backlog. |
If you have a question about a behavior that you’re seeing in pyright, consider posting to the Pyright discussion forum.
Is your feature request related to a problem? Please describe.
Before selecting a completion candidate I'd like to know if the class/function is deprecated. For example the symbol could be shown as strikethrough in the completion list if it is marked as deprecated.
Describe the solution you’d like
The LSP specification defines
CompletionItemTag.Deprecated
for deprecated symbols. https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#completionItemTagPyright already supports the
@warnings.deprecated
decorator and assigns thereportDeprecated
diagnostic if it's already in the document. I think it would be helpful to provide this information already before the user picks it from the completion. As a user, I'd like to avoid the usage of deprecated symbols when writing new code.The text was updated successfully, but these errors were encountered: