vscode-yaml icon indicating copy to clipboard operation
vscode-yaml copied to clipboard

VSCode extension yaml auto-complete not working in vscode 1.43.1 and yaml extension 0.7.2

Open chelsealopentinum opened this issue 4 years ago • 4 comments

I am testing vscode 1.43.1 example from here and have some issues. When I set registerCompletionItemProvider language option to "yaml", the auto complete item results not showing anymore until I uninstall the yaml extension. It worked on vscode 1.42.1 with yaml extension. Does anybody encounter the same issue?

I also ask this problem in vscode github: https://github.com/microsoft/vscode/issues/93279#issue-586666956

  • VSCode Version: 1.43.1
  • OS Version: Mac os mojave 10.14.5
  • YAML Extension Version: 0.7.2

Steps to Reproduce:

  1. Install YAML extension.
  2. Using vscode-extension-sample: completions. The trigger character is ., and I modify the language from plaintext to yaml.
  3. Run it and open an empty yaml file, then keying console..

Input console. in the empty yaml file. There has no item to show. nnn

When I disable YAML extension, it seems work. yy

chelsealopentinum avatar Mar 24 '20 10:03 chelsealopentinum

Hmm, I'm not sure what is causing this. I thought that VSCode would look for all language contributions for a specific filetype and then join them all together. We aren't doing anything special here that should cause it 🤷‍♂

Can you try this with something like the vscode java extension and try registering it as java and see what happens?

JPinkney avatar Apr 03 '20 14:04 JPinkney

I've also encountered this issue (here). I might try digging into vscode a bit to see what's up, but as far as I can tell (and I'm relatively new to vscode extensions so forgive me) registerCompletionItemProvider() isn't being used in favour of LanguageClient. My current assumption is that https://github.com/microsoft/vscode-languageserver-node somehow overrides the completions from other extensions.

gmemstr avatar May 27 '20 09:05 gmemstr

I suspect that's because of wordPattern https://github.com/redhat-developer/vscode-yaml/blob/main/language-configuration.json#L37

alexzuza avatar Apr 06 '23 15:04 alexzuza

Did someone find a solution?

dariocurr avatar Nov 15 '23 11:11 dariocurr