dotnet / dotnet/vscode-dotnet-runtime

Uninstalled vscode-local runtimes still appear in “.NET Install Tool: Uninstall .NET” UI after folder deletion and cache reset

Open
#2,565 3 comments 1 reaction 2 assignees Claimed by @nagilson View on GitHub
bug P3
Dominant language
TypeScript
Stars
209
Forks
455
PR merge metrics
No merged PRs in 30d

Description

### Describe the bug.

## Environment

- VS Code
- Version: 1.109.2 (system setup)
- Commit: 591199df409fbf59b4b52d5ad4ee0470152a9b31
- Date: 2026-02-10T20:18:23.520Z
- Electron: 39.3.0
- ElectronBuildId: 13168319
- Chromium: 142.0.7444.265
- Node.js: 22.21.1
- V8: 14.2.231.22-electron.0
- OS: Windows_NT x64 10.0.26200
- **.NET Install Tool extension version: `ms-dotnettools.vscode-dotnet-runtime-3.0.0`**

### System-wide .NET installation

```powershell
dotnet --info

.NET SDK:
Version: 10.0.103
Commit: c2435c3e0f
Workload version: 10.0.100-manifests.c992be6d
MSBuild version: 18.0.11+c2435c3e0
Base Path: C:\Program Files\dotnet\sdk\10.0.103\

Host:
Version: 10.0.3
Architecture: x64
Commit: c2435c3e0f

where dotnet

C:\Program Files\dotnet\dotnet.exe
```

No `DOTNET_ROOT` environment variable is set.
No `global.json` file is present.

### Please attach log file(s) here if you have any.

The log file location:
```
%AppData%\Roaming\Code\logs\20260212T174416\window1\exthost\ms-dotnettools.vscode-dotnet-runtime
```

[DotNetAcquisition-sanitized-1.txt](https://github.com/user-attachments/files/25277575/DotNetAcquisition-sanitized-1.txt)
[DotNetAcquisition-sanitized-2.txt](https://github.com/user-attachments/files/25277576/DotNetAcquisition-sanitized-2.txt)

### Reproduction Steps

## After running

> Command Palette → ".NET Install Tool: Uninstall .NET" → `.NET Runtime 7.0.9 x64 | vscode-local`

The Output panel reports successful removal:

```powershell
Attempting to remove .NET 7.0.9~x64.
Uninstalled .NET 7.0.9~x64.
```

However, the runtime still appears in the uninstall picker UI:

- `.NET Runtime 7.0.9 x64 | vscode-local`
- `.NET Runtime 8.0.24 x64 | vscode-local; Used by dotnet-runtime-library, ms-toolsai.datawrangler`

---

## Additional Configuration

The following setting is configured to use the system .NET:
```json
"dotnetAcquisitionExtension.sharedExistingDotnetPath": "C:\\Program Files\\dotnet\\dotnet.exe",
"dotnetAcquisitionExtension.existingDotnetPath": [
{
"extensionId": "ms-dotnettools.csharp",
"path": "C:\\Program Files\\dotnet\\dotnet.exe"
},
{
"extensionId": "ms-dotnettools.csdevkit",
"path": "C:\\Program Files\\dotnet\\dotnet.exe"
}
]
```
Despite this configuration, the stale entries remain visible.

---

## Steps Already Taken

1. Fully closed VS Code (all windows).
2. Ensured no lingering `Code.exe` or `dotnet.exe` processes were running.
3. Deleted:
```
%APPDATA%\Code\User\globalStorage\ms-dotnettools.vscode-dotnet-runtime
```
4. Deleted:
```
%APPDATA%\Code\User\workspaceStorage
```
5. Reopened VS Code.

The `globalStorage` folder is recreated on startup (empty), but the same runtimes still appear in:

> Command Palette → ".NET Install Tool: Uninstall .NET"

6. Verified the actual runtime install directory does NOT contain the runtimes:
```
%APPDATA%\Code\User\globalStorage\ms-dotnettools.vscode-dotnet-runtime\.dotnet\
```
The runtime folders (`7.0.9~x64`, `8.0.24~x64`) are not present.

### Expected Behavior

- After Successful uninstall
- Automatic deletion of runtime folders
- Restarting VS Code

The runtime should no longer appear in the uninstall UI.

### Exceptions & Errors (if any)

**No error messages**

### .NET Install Tool Version

v3.0.0

### Your operating system? Please provide more detail, such as the version and or distro above.

Windows

### VS Code Version

1.109.2

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.