Describe the bug
The Refactoring feature of PowerShell Pro Tools in VS Code does not behave as expected, when trying to apply a suggestion in a yet-to-be-saved PS1-document. The context menu with refactor suggestions does appear by clicking on the lightbulb icon, but clicking on a suggestion does not change the selected element.
To Reproduce
Steps to reproduce the behavior:
Open a new file (Ctrl+N)
Set the editor's Language Mode to 'PowerShell'
Type '$_'
Click on the light bulb icon -> 'Convert to $PSItem'
See unexpected behaviour: nothing happens
Now save the document (Ctrl+S) as a PS1-document
Try 'Concert to $PSItem' again
See expected behaviour: the element gets refactored
Expected behavior
My expectation is that either the element also gets refactored in unsaved documents, or that the refactor functionality is not available.
Screenshots
When saving the new document as a PS1-file, refactoring does work:
Version
VS Code: 1.80.1 (user setup)
Version Number: PowerShell Pro Tools v2023.9.0
Operating System: Windows 10 Enterprise 22H2
Additional context
The Output window inside VS Code does not show an error of PowerShell Pro Tools or anything.
Logs
I cannot find PPT logfiles. There is no directory $Env:AppData\PowerShellProTools. There is directory $Env:AppData\PowerShell Pro Tools\ but only a license file is inside.
Describe the bug The Refactoring feature of PowerShell Pro Tools in VS Code does not behave as expected, when trying to apply a suggestion in a yet-to-be-saved PS1-document. The context menu with refactor suggestions does appear by clicking on the lightbulb icon, but clicking on a suggestion does not change the selected element.
To Reproduce Steps to reproduce the behavior:
Expected behavior My expectation is that either the element also gets refactored in unsaved documents, or that the refactor functionality is not available.
Screenshots When saving the new document as a PS1-file, refactoring does work:
Version VS Code: 1.80.1 (user setup) Version Number: PowerShell Pro Tools v2023.9.0 Operating System: Windows 10 Enterprise 22H2
Additional context The Output window inside VS Code does not show an error of PowerShell Pro Tools or anything.
Logs I cannot find PPT logfiles. There is no directory $Env:AppData\PowerShellProTools. There is directory $Env:AppData\PowerShell Pro Tools\ but only a license file is inside.