dotnet / dotnet/roslyn

Remove/review our `SupportsCodeActionResolve` code

Open
#85,537 0 comments 0 reactions 0 assignees View on GitHub
Area-Razor
Dominant language
C#
Stars
20.7k
Forks
4.3k
PR merge metrics
PR metrics pending

Description

Our code actions bits have a method that detects if a client supports resolving code actions:

https://github.com/dotnet/razor/blob/5173e34bcaff8b5972f9b98f4547e6ff66fdb12f/src/Razor/src/Microsoft.VisualStudio.LanguageServices.Razor/LanguageClient/Endpoints/RazorCustomMessageTarget_CodeActions.cs#L157

This is used either as a "detection" for VS Code, or simply to support that scenario:

https://github.com/dotnet/razor/blob/5173e34bcaff8b5972f9b98f4547e6ff66fdb12f/src/Razor/src/Microsoft.AspNetCore.Razor.LanguageServer/CodeActions/CodeActionEndpoint.cs#L102-L104

Presumably it didn't used to, but VS Code currently _does_ support code action resolve which means the false condition of these checks is currently never exercised (outside of presumably questionable tests) so is at best, redundant and at worst, broken.

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.