DEV Community

Michael Simmonds
Michael Simmonds

Posted on

1 1

Omnisharp not working in vscode - fix

My intellisense for vscode suddenly bailed out on me:

Before we start mucking about too much let's try some standard things to get it back up and running:

  1. Reset the OmniSharp server - Command palette - OmniSharp: Restart OmniSharp.
  2. Check that OmniSharp is looking at the right project - Command palette - OmniSharp: Select Project.

If neither of these work - follow on for another option:

Microsoft released a new version of the C# extension (v1.25) for vscode that breaks for older projects (the one I'm using is 2.1 :\ ). The tools required for it to work are no longer included in the extension - so you need to download them yourself.

  1. In vscode go to settings (I used workspace settings) and search for "Omnisharp - use modern net" set this to off.
  2. Mac: Download and install Mono that includes the build tools (Visual Studio Channel). Windows: Download and install Visual Studio MSBuild Tools or a full Visual Studio version.

Restart vscode. I had restart the OnmiSharp server (see above) even after a restart of vscode itself.

If this helps a single person I'll be happy - I lost hours to this!

AWS Q Developer image

Your AI Code Assistant

Implement features, document your code, or refactor your projects.
Built to handle large projects, Amazon Q Developer works alongside you from idea to production code.

Get started free in your IDE

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

AWS GenAI LIVE!

GenAI LIVE! is a dynamic live-streamed show exploring how AWS and our partners are helping organizations unlock real value with generative AI.

Tune in to the full event

DEV is partnering to bring live events to the community. Join us or dismiss this billboard if you're not interested. ❤️