microsoft / PTVS

Python Tools for Visual Studio
https://aka.ms/PTVS
Apache License 2.0
2.52k stars 673 forks source link

Listen and modify client messages to make code actions work #7876

Closed StellaHuang95 closed 2 months ago

StellaHuang95 commented 2 months ago

fixes https://github.com/microsoft/PTVS/issues/7864

In the code action requests that VS client sends, the _vs_selectionRange is supposed to be the range property that Pylance can understand, so intercept the messages and modify the property to make code actions work.

codeaction-extractmethod

sonarcloud[bot] commented 2 months ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud