Omnisharp-vscode: Compilation Hints Get Scrambled

Created on 4 May 2017  路  10Comments  路  Source: OmniSharp/omnisharp-vscode

_From @jrieken on May 23, 2016 10:59_

_From @robbpriestley on May 22, 2016 16:47_

  • VSCode Version: 1.1.1
  • OS Version: OSX El Capitan 10.11.4

This has been an annoying issue ever since I started using VS Code in March. I've been living with it and don't want to complain because I love VS Code, but perhaps it will help if I report it.

Steps to Reproduce:

  1. Work normally and do a minor refactor, change the signature of a method, or modify a class structure
  2. The compilation hints spontaneously get all scrambled and remain that way

Sometimes clicking on the error list and selecting an "error" from the list jumps me to the source location helps to snap VS Code out of it, but most often I need to save everything and restart VS Code to fix it. Then it "re-indexes" the code and the mistaken compilation error hints go away. Executing dotnet build doesn't do it.

Attached is a screenshot showing a very weird one that occurred spontaneously just now.

Type 'ServiceLogRepository' already defines a member called '.ctor' with the same parameter types [netcoreapp1.0]

I hope I'm getting the terminology decently OK here, there are probably better names for things.

untitled

_Copied from original issue: Microsoft/vscode#6632_

_Copied from original issue: OmniSharp/omnisharp-roslyn#559_

Needs More Info

Most helpful comment

Hello,

I'm using Emacs with omnisharp recently and encountered this problem. Even for simple console project.

System:

  • Debian 9
  • Emacs 25.2
  • dotnet 2.1.4
  • omnisharp-roslyn 1.32.6

Steps to reproduce:

  • Create new console project (dotnet new console)
  • Open with emacs and try to do a minor edit to trigger lint

screenshot at 2018-10-24 12-02-26

Here's the log

omnisharp.log

Workaround:
At the moment I use v1.32.0 which doesn't have this issue.

All 10 comments

_From @robbpriestley on May 23, 2016 20:57_

Here's another interesting one:

The call is ambiguous between the following methods or properties: 'ISocialMediaRepository.Add(SocialMedia)' and 'ISocialMediaRepository.Add(SocialMedia)' [netcoreapp1.0]

_From @tugberkugurlu on May 31, 2016 8:59_

As stated on #567 and #566, I am seeing the same errors.

_From @robbpriestley on August 12, 2016 20:16_

This continues to be a really serious usability problem and in my humble opinion it should be top priority to fix. Easy for me to say, I know, but here's an example:

I'm doing a refactor today and I've quite literally needed to restart VS Code a dozen times in order to clear the scrambled compilation hints. Now members of my team are reporting it as a distraction as well. It's more than just annoying, it leads to incorrect conversations between team members as well, and is a productivity hit.

_From @robbpriestley on April 23, 2017 1:8_

Don't get me wrong, I am a huge fan of VS Code and I'm sorry to be critical, but it baffles me that so many features I never use keep getting added to the product while this major fundamental usability issue continues to plague it.

I find myself needing to shut down and re-open VS Code on a regular basis to help it correct itself of faulty compiler issues and errors, and it affects my basic productivity. 馃憥

Here's a good visual example:

screen shot 2017-04-23 at 8 46 38 am

Hey guys --- sorry I hadn't noticed this C# for VS Code issue. I'll migrate it over to the omnisharp-vscode repo where it belongs.

@robbpriestley: Could you provide your OmniSharp Log when this happens? You can display the OmniSharp Log by selecting View->Output in VS Code. Then, click the combobox at the top-right of the Output pane and choose "OmniSharp Log".

@DustinCampbell for sure I'd be glad to. In fact, I spent a while last night trying to re-create. Of course, it was as if VSCode felt it was being observed and so was on its best behaviour in two separate scenarios. But, if/when it happens again, I will post my OmniSharp Log as you have requested. Although, come to think of it, this problem hasn't happened in a couple of weeks of heavy VSCode use. Perhaps it went away. That would be a win!

That's good to hear. We've been doing a good deal of work on this and there a couple of fixes that went in a few weeks ago that I could imagine addressing this. I'm going to go ahead and close this. If you run into the issue again, please feel free to add more information here and we'll re-open, or file a fresh issue at https://github.com/OmniSharp/omnisharp-vscode/issues.

Thanks!

@DustinCampbell I don't know exactly what you guys did or fixed, but things are working so much better now. It's so much less frustrating now that my compilation hints are accurate and reliable. Thank you!

Hello,

I'm using Emacs with omnisharp recently and encountered this problem. Even for simple console project.

System:

  • Debian 9
  • Emacs 25.2
  • dotnet 2.1.4
  • omnisharp-roslyn 1.32.6

Steps to reproduce:

  • Create new console project (dotnet new console)
  • Open with emacs and try to do a minor edit to trigger lint

screenshot at 2018-10-24 12-02-26

Here's the log

omnisharp.log

Workaround:
At the moment I use v1.32.0 which doesn't have this issue.

Was this page helpful?
0 / 5 - 0 ratings