dotnet / vscode-csharp

Official C# support for Visual Studio Code
MIT License
2.86k stars 671 forks source link

C# plugin doesn't work for me in vs code #4474

Open Shadowblitz16 opened 3 years ago

Shadowblitz16 commented 3 years ago

Please paste the output from your clipboard

Issue Description

The C# extension is not working for me under kubuntu 20.10 as has not even when I was in windows

Steps to Reproduce

I don't think you will be able to reproduce this due to the fact I am not even getting errors. (I have debugged with people in the C# discord aka Klarth and 333fred)

Expected Behavior

I would assume I would just have the same or simular experience to vs 2019

Actual Behavior

Logs

not sure what to put I assume nothing since i get no errors?

OmniSharp log

https://gist.github.com/Shadowblitz16/c01b50a4231b8b8d71808827962ecb7e

C# log

NA

Environment information

VSCode version: 1.55.0 C# Extension: 1.23.9

Mono Information OmniSharp using built-in mono
Dotnet Information .NET SDK (reflecting any global.json): Version: 5.0.201 Commit: a09bd5c86c Runtime Environment: OS Name: ubuntu OS Version: 20.10 OS Platform: Linux RID: ubuntu.20.10-x64 Base Path: /usr/share/dotnet/sdk/5.0.201/ Host (useful for support): Version: 5.0.4 Commit: f27d337295 .NET SDKs installed: 5.0.201 [/usr/share/dotnet/sdk] .NET runtimes installed: Microsoft.AspNetCore.App 5.0.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App] Microsoft.NETCore.App 5.0.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App] To install additional .NET runtimes or SDKs: https://aka.ms/dotnet-download
Visual Studio Code Extensions |Extension|Author|Version| |---|---|---| |better-toml|bungcip|0.3.2| |cargo|panicbit|0.2.3| |crates|serayuzgur|0.5.7| |csharp|ms-dotnettools|1.23.9| |kde-breeze-dark-cs|Shadowblitz16|0.0.1| |rust-analyzer|matklad|0.2.538| |rust-and-friends|nyxiative|1.0.0| |rust-doc-viewer|JScearcy|2.0.1| |rust-flash-snippets|lorenzopirro|1.2.0| |rust-mod-generator|ZhangYue|1.0.3| |rust-syntax|dustypomerleau|0.5.0| |rust-targets|PolyMeilex|1.0.1| |syntax-highlighter|evgeniypeshkov|0.5.0| |vscode-lldb|vadimcn|1.6.1| |vscode-nuget-package-manager|jmrog|1.1.6| |vsliveshare|ms-vsliveshare|1.0.4070|;

Example

Menu has a Update method but.. image image

JoeRobich commented 3 years ago

@Shadowblitz16 It appears from you log that the project was loaded. I am not sure why you are not seeing completion. Is this a project that you can share with us?

JoeRobich commented 3 years ago

@Shadowblitz16 We found an issue in your log that has been fixed in the newer builds of OmniSharp. Could you try this prerelease C# extension and see if your issue is resolved https://github.com/OmniSharp/omnisharp-vscode/releases/tag/v1.23.10 (Instructions for installing beta releases)

Shadowblitz16 commented 3 years ago

@JoeRobich Its not my project. I debugged it with the people on C# discord and it worked for them

I can try the newer version. I will get back to you.

Shadowblitz16 commented 3 years ago

@JoeRobich I am getting autocomplete now as far as I know but its slow and now my project doesn't run when I do dotnet run also I am still not getting quick fixes image

EDIT: actually I am still getting bugs. image

JoeRobich commented 3 years ago

@Shadowblitz16 Could you set the OmniSharp LogLevel to trace and share the OmniSharp log from the output pane when you are seeing these issues? Also, to it would be helpful if you could share the project or repo that issues can be reproduced with. I was able to build and run the following Raylib repo with no issue - https://github.com/ChrisDill/Raylib-cs-Examples.

Shadowblitz16 commented 3 years ago

https://gist.github.com/Shadowblitz16/0479c5d4f27ec1d65711792bb0314e99 https://github.com/Shadowblitz16/Asteroids-Raylib/blob/master/src/Program.cs

JoeRobich commented 3 years ago

@Shadowblitz16 If I swap the Raylib.InitWindow and Menu.ObjectCreate lines in Program.cs your app runs. Can you tell me what you were doing in the editor when you saw the code highlighted incorrectly?

Shadowblitz16 commented 3 years ago

@JoeRobich I was just trying to get it to compile and then I looked up and it was highlighted wrongly. Also thankyou

JoeRobich commented 3 years ago

I was just trying to get it to compile and then I looked up and it was highlighted wrongly.

Ah, ok. We have had issues where the editor and the language server would end up with different views of the source code. There was a change in 1.23.10 which I believed would fix this issue. Please let me know if you see this again.

Shadowblitz16 commented 3 years ago

@JoeRobich I have been coding with the extension all day today and it kinda worked but its slow and eventually just stops working. not sure if it helps but here is a log from my entire day of coding.. https://gist.github.com/Shadowblitz16/055d053451d6c11c4028ec771a2c4e2d