dotnet / dotnet/roslyn

LanguageServerProjectSystem: loading a different solution doesn't unload projects from the previous solution

Open
#79,638 1 comment 0 reactions 1 assignee Claimed by @RikkiGibson View on GitHub
Area-IDE IDE-Project VSCode
Dominant language
C#
Stars
20.7k
Forks
4.3k
PR merge metrics
PR metrics pending

Description

**Version Used**: d834a2e7215b9d2a8783fcc0da4dbddc8c63273d

**Steps to Reproduce**:

1. Set up vscode with C# and without C# Dev Kit.
2. Open a workspace which has multiple different `A.sln` and `B.sln` with different projects.
3. Use `.NET: Open Solution` command to change between the solutions

**Expected Behavior**: Projects in `A.sln` are unloaded when `B.sln` is loaded. At least, those which are in `A` but not in `B` are unloaded, when changing from `A` to `B`.

**Actual Behavior**: Projects from both solutions remain loaded

See LanguageServerProjectSystem.OpenSolutionAsync:

https://github.com/dotnet/roslyn/blob/2525c873f1dbfa48b07c82f8a8662cae67d78dcb/src/LanguageServer/Microsoft.CodeAnalysis.LanguageServer/HostWorkspace/LanguageServerProjectSystem.cs#L56-L68

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.