lyngw...@gmail.com writes:

> I wrote a Python script, which executed as intended on Linux and from
> cmd.exe on Windows.  Then, I ran it from the PowerShell command line,
> all print statements added ^@ after every character.
>
> Have you seen this?  Do you know how to prevent this?

Script is printing UTF-16 or something, viewer is expecting ASCII or
some eight bit code and making null bytes visible as ^@.

Python gets some default encoding from its environment. There are ways
to set the default, and ways to override the default in the script. For
example, you can specify an encoding when you open a file.
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to