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

Proposal: Allow to return additional information in CompletionItem #235

Closed
ko1 opened this issue Dec 17, 2021 · 5 comments
Closed

Proposal: Allow to return additional information in CompletionItem #235

ko1 opened this issue Dec 17, 2021 · 5 comments
Assignees
Labels
feature-request Request for new features or functionality
Milestone

Comments

@ko1
Copy link
Contributor

ko1 commented Dec 17, 2021

Can we return additional information for users on completion with CompletionItem?

Debug adapter can know detailed information of complemented text. For example: On Ruby, if the given text is 1.time, then it returns 1.times because DAP can know 1 is Integer and it has the method Integer#times. On this case, with the completion results 1.times, showing Integer#times is informative for users. In other words, showing type information seems useful.

If the type information is short, it is enough by containing the information in label, but it's better to show them separately.

@connor4312
Copy link
Member

This is requesting the detail that is present in the VS Code/LSP CompletionItem:

		/**
		 * A human-readable string with additional information
		 * about this item, like type or symbol information.
		 */
		detail?: string;

I think copying that property verbatim makes sense for DAP's CompletionItems as well.

@weinand weinand self-assigned this Jan 10, 2022
@weinand weinand added the feature-request Request for new features or functionality label Jan 10, 2022
@weinand weinand added this to the February 2022 milestone Feb 3, 2022
@weinand
Copy link
Contributor

weinand commented Feb 3, 2022

Yes, a detail property on the completionItem makes sense.

@connor4312 could you take care of getting this into the spec?

@weinand
Copy link
Contributor

weinand commented Feb 3, 2022

@connor4312 thanks for taking care of this.
I've moved the change log item under the previous version because I typically batch all changes under a single version per milestone.
Could you please create an adoption item in VS Code that refers to this item and explains what to do.

@connor4312
Copy link
Member

connor4312 commented Feb 3, 2022

Ah, sorry, I didn't realize -- I already copied the change to vscode-debugadapter-node and published it as 1.53 following semver. Unpublishing is possible though somewhat dangerous -- what would you prefer I do to fix this?

@weinand
Copy link
Contributor

weinand commented Feb 3, 2022

no problem, I've reverted my commit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request Request for new features or functionality
Projects
None yet
Development

No branches or pull requests

4 participants