On 2/11/21, Christopher Barker <python...@gmail.com> wrote:
> On Wed, Feb 10, 2021 at 12:33 AM Paul Moore <p.f.mo...@gmail.com> wrote:
>
>> So get PYTHONUTF8 added to the environment activate script. That's a
>> simple change to venv. And virtualenv, and conda
>
> That's probably a good solution for venv and virtualenv -- essentially add
> it as another environment creation option.

Note that using a virtual environment does not require activation. A
script can be deployed to run in a virtual environment by referring to
the environment's executable in a shebang line, e.g.:

    #!path\to\venv\Scripts\python.exe

Or with a Windows shell link that runs

    path\to\venv\Scripts\python.exe path\to\script.py

Setting PYTHONUTF8 in the activate script does nothing to educate
users about the default encoding in other contexts. The REPL shell
could print a short message at startup that informs the user that
Python is using UTF-8 mode, including a link to a web page that
explains this in more detail.
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/SN4HJZFL3CXOJS53DUTQDRQ4MCXRLERT/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to