Jan-28-2017, 03:27 PM
You should post an example and python version is important.
Use a better shell cmder.
In cmd:
Quote:I tried with .encode('utf-8') and .decode('utf-8') and seems ok.From where?
Use a better shell cmder.
In cmd:
C:\>which python 'which' is not recognized as an internal or external command, operable program or batch file. C:\>python -c "import sys; print(sys.stdout.encoding)" utf-8 C:\>python -c "print('Spicy jalapeño ? ? ? ? ')" Spicy jalapeño ? ? ? ? C:\>python -c "print('? ? ? ? ?')" ? ? ? ? ?The same in cmder:
C:\ λ which python /c/python36/python C:\ λ python -c "import sys; print(sys.stdout.encoding)" utf-8 C:\ λ python -c "print('Spicy jalapeño ☂ ☃ ★ ☁')" Spicy jalapeño ☂ ☃ ★ ☁ C:\ λ python -c "print('♚ ✈ ☹ ☠ ☝')" ♚ ✈ ☹ ☠ ☝