You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When outputting UTF-8 from a native application PowerShell pipes fail to parse the data correctly even if a BOM is present.
In contrast this works in PowerShell 5.1 - that's why I'm reporting this as a bug.
The following python script will produce UTF-8 encoded output with a BOM.
Powershell 5.1 is able to recognise the output is UTF-8 encoded if the BOM is present. PowerShell 7.2.4 does not.
Note that both shells were started with the -noprofile option to ensure default configuration.
Expected behavior
PS> python .\test.py | echoäöüß αβγδ
Actual behavior
PS > python .\test.py | echo´╗┐├ñ├Â├╝├ƒ ╬▒╬▓╬│╬┤
Error details
No response
Environment data
PS>$PSVersionTable
Name Value
---------
PSVersion 7.2.4
PSEdition Core
GitCommitId 7.2.4
OS Microsoft Windows 10.0.19044
Platform Win32NT
PSCompatibleVersions {1.0,2.0,3.0,4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
Prerequisites
Steps to reproduce
When outputting UTF-8 from a native application PowerShell pipes fail to parse the data correctly even if a BOM is present.
In contrast this works in PowerShell 5.1 - that's why I'm reporting this as a bug.
The following python script will produce UTF-8 encoded output with a BOM.
Powershell 5.1 is able to recognise the output is UTF-8 encoded if the BOM is present. PowerShell 7.2.4 does not.
Note that both shells were started with the
-noprofileoption to ensure default configuration.Expected behavior
Actual behavior
Error details
No response
Environment data
Visuals
No response