ycm-core / ycmd

A code-completion & code-comprehension server
https://ycm-core.github.io/ycmd/
GNU General Public License v3.0
1.69k stars 764 forks source link

[RFC] Switch C# completer to LSP #1752

Open bstaletic opened 1 month ago

bstaletic commented 1 month ago

Very much not finished. Needs a lot more testing.

Currently missing pieces:

Diagostics work, rename works. I have not tried the rest tonight, but I remember them working.

@dkaszews This should be enough to try it out a bit.


This change is Reviewable

bstaletic commented 1 month ago

CodeActions are ill-formed and hit a million asserts in ycmd. Starting with this one.

I got CodeActions working.

Omnisharp does not seem to be picking up docstrings in LSP mode.

It should be there! https://github.com/OmniSharp/omnisharp-roslyn/blob/dacc49a3176c30767d0c1604cce6073afb0a7f6e/src/OmniSharp.LanguageServerProtocol/Handlers/OmniSharpHoverHandler.cs#L41 I really need someone with a proper omnisharp/C# setup to try GetType and give me the logs.

Currently only works with user_option roslyn_binary_path.

This should only need an updated monisharp, via ./update_omnisharp.py.

GetProjectRootFiles returns an empty list, so users need to cd to their desired project root.

Fixed as well.

I could not get omnisharp to log anything at all.

Hmm... still true. not sure what I'm doing wrong.

bstaletic commented 1 month ago

Currently only works with user_option roslyn_binary_path.

We can now communicate with the bundled server, but it won't initialize on my machine.

This is where my knowledge of C# mess ends and I will be needing help from here on out.

bstaletic commented 4 weeks ago

All tests are passing on non-Winblows. Winblows is hanging for some reason.