Skip to content

Adds the option ignoreCompleteItemsIsIncomplete.#626

Merged
yegappan merged 1 commit intoyegappan:mainfrom
berggeist:add-option-ignoreCompleteItemsIsIncomplete
May 6, 2025
Merged

Adds the option ignoreCompleteItemsIsIncomplete.#626
yegappan merged 1 commit intoyegappan:mainfrom
berggeist:add-option-ignoreCompleteItemsIsIncomplete

Conversation

@berggeist
Copy link
Contributor

Optional list of LSP server names for which
'IsIncomplete' messages should be ignored and
filtering of received completion item lists
is enforced. This is helpful for LSP servers
that are misbehaving and always send this
kind of 'IsIncomplete' messages.

Optional list of LSP server names for which
'IsIncomplete' messages should be ignored and
filtering of received completion item lists
is enforced. This is helpful for LSP servers
that are misbehaving and always send this
kind of 'IsIncomplete' messages.
@berggeist
Copy link
Contributor Author

This is an attempt to fix #583
Fix completion item filtering condition

@berggeist
Copy link
Contributor Author

As an example for a LSP server for which this new option might be helpful:

See this issue of the Rust language server rust-lang/rust-analyzer#7649

According to the language server protocol specification CompletionList.isIncomplete

     /**
 * This list is not complete. Further typing should result in recomputing
 * this list.
 *
 * Recomputed lists have all their items replaced (not appended) in the
 * incomplete completion sessions.
 */
isIncomplete: boolean;

shall provide a hint to the client that the provided completion list is only temporarily and will be soon replaced by another list so it is not necessary to apply any filtering to this completion list, because it will be lost anyway.
Unfortunately the Rust language server rust-analyzer does always set this flag CompletionList.isIncomplete to true. See also the link to the according github issue above.

@yegappan yegappan merged commit a22009c into yegappan:main May 6, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants