[issue44275] Is there a mojibake problem rendering interactive help in the REPL on Windows?

Inada Naoki report at bugs.python.org
Tue Jun 1 18:26:49 EDT 2021


Inada Naoki <songofacandy at gmail.com> added the comment:

>> PS > $OutputEncoding =  [System.Text.Encoding]::GetEncoding("UTF-8")

> FYI, $OutputEncoding in PowerShell has nothing to do with the python.exe and more.com processes, nor the console session to which they're attached.

>> PS > [System.Console]::OutputEncoding = $OutputEncoding

> The console output code page is irrelevant since more.com writes wide-character text via WriteConsoleW() and decodes the file using the console input code page, GetConsoleCP(). The console output codepage from GetConsoleOutputCP() isn't used for anything here.

Yes, both are unrelated to this specific issue. But both are highly recommended for using Python with UTF-8 mode.

Now many people want to use Python with UTF-8 mode in PowerShell in Windows Terminal. And they don't want to care about legacy encoding at all.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue44275>
_______________________________________


More information about the Python-bugs-list mailing list