dotnet / dotnet/vscode-dotnet-runtime

Add the ability to reinstall the local runtime

Open
#1,671 7 comments 1 reaction 1 assignee Claimed by @nagilson View on GitHub
cost: medium feature-request new-hire-issue P2
Dominant language
TypeScript
Stars
209
Forks
455
PR merge metrics
No merged PRs in 30d

Description

### Is your feature request related to a problem? Please describe.

In https://github.com/dotnet/vscode-csharp/issues/6889 we have a report of an error.

```
A fatal error was encountered. The library 'libhostpolicy.so' required to execute the application was not found in '/home/daniel/.config/Code/User/globalStorage/ms-dotnettools.vscode-dotnet-runtime/.dotnet/7.0.16~x64/shared/Microsoft.NETCore.App/7.0.16'.
```

In this case what appears to be a corrupt local install of the runtime is keeping the C# DevKit extension from starting.

### A clear and concise description of what you want to happen. Include any alternative solutions you've considered.

I would like the ability to reinstall the local runtime.

### Describe the solution you'd like

A VS Code command be added to the runtime extension allowing users to force a reinstall via the command palette.
1. The command would remove the current local runtime installation
2. It would then reinstall the runtime
3. Lastly, it would prompt the user to reload the window. This would in turn reload all the extensions which may have been trying to use the corrupted runtime install.

This would be similar to how the C# extension [prompts when option changes require a restart](https://github.com/dotnet/vscode-csharp/blob/bb2134804be15ae64b715cc7a29b06eed82cdbc5/src/lsptoolshost/optionChanges.ts#L37-L59).

![Image](https://github.com/dotnet/vscode-dotnet-runtime/assets/611219/385c6582-99e8-45a1-95d1-861c3b943ec9)

### Additional context

_No response_

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.