Skip to content

v2020.6.0 (preview) - #2962

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ghost opened this issue Sep 17, 2020 · 2 comments
Closed

v2020.6.0 (preview) - #2962

ghost opened this issue Sep 17, 2020 · 2 comments
Labels
Resolution-Duplicate Will close automatically.

Comments

@ghost
Copy link

ghost commented Sep 17, 2020

System Details

System Details Output

### VSCode version: 1.49.0 e790b931385d72cf5669fcefc51cdf65990efa5d x64

### VSCode extensions:
hashicorp.terraform@2.2.3
ms-python.python@2020.8.109390
ms-vscode.powershell@2020.6.0
rebornix.ruby@0.27.0
wingrunr21.vscode-ruby@0.27.0


### PSES version:

### PowerShell version:

Name                           Value
----                           -----
PSVersion                      5.1.18362.752
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.18362.752
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

Issue Description

Format Document feature removes ": " (colon space) when beside a variable in a double quoted string. This occurs if the colon is escaped with the ` character, or, if the variable is wrapped in subexpression operator $().

Expected Behaviour

-- Description of what should be happening --

Nothing - escaping the character is valid, as is using a subexpression.

Actual Behaviour

-- Description of what actually happens --
Assuming the following two lines in code:
write-host "There is an issue doing the thing on $server`: $($_.exception.message)"
or
write-host "There is an issue doing the thing on $($server): $($_.exception.message)"

Format document removes the : characters, leaving:
write-host "There is an issue doing the thing on $server$($_.exception.message)"
or
write-host "There is an issue doing the thing on $($server)$($_.exception.message)"

Attached Logs

I'm not aware of any logging for this.

Follow the instructions in the troubleshooting docs
about capturing and sending logs.

@ghost ghost added the Needs: Triage Maintainer attention needed! label Sep 17, 2020
@SydneyhSmith
Copy link
Collaborator

Thanks @bwhitehead0 looks like a duplicate of the issues we are seeing with formatting being tracked in PSScriptAnalyzer PowerShell/PSScriptAnalyzer#1580

@SydneyhSmith SydneyhSmith added Resolution-Duplicate Will close automatically. and removed Needs: Triage Maintainer attention needed! labels Sep 17, 2020
@ghost
Copy link

ghost commented Sep 18, 2020

This issue has been marked as duplicate and has not had any activity for 1 day. It has been closed for housekeeping purposes.

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution-Duplicate Will close automatically.
Projects
None yet
Development

No branches or pull requests

1 participant