pypa / installer

A low-level library for installing from a Python wheel distribution.
https://installer.readthedocs.io/
MIT License
123 stars 51 forks source link

Avoid `coding: utf-8` in Python 3 scripts #225

Closed DimitriPapadopoulos closed 1 week ago

DimitriPapadopoulos commented 2 months ago

As far as I know, only Python 3 is supported. Therefore, get rid of coding: utf-8 in generated scripts, as UTF-8 is the default.

Also, it could be that module or import_name are not ASCII, but then I would rather add tests with non-ASCII module and function names.

Secrus commented 2 weeks ago

This is not really valid, since you can use installer as library and make it install a wheel into Python 2 environment (in which case, IIRC, the coding info is needed).

DimitriPapadopoulos commented 2 weeks ago

If Python 2 target environments are supported, then yes, it's best to keep this as is for non-ASCII module and function names.

I may be mistaken, but I cannot find details about support for Python 2 environments in the documentation.

Secrus commented 1 week ago

There might not be a mention of that in the docs. No matter that, I would leave the coding comment in place. It doesn't hurt us to keep it there.