[Python-Dev] Re: pth file encoding

2021-03-16 Thread Inada Naoki
OK. setuptools doesn't specify encoding at all. So locale-specific encoding is used. We can not fix it in short term. On Wed, Mar 17, 2021 at 4:56 AM Brett Cannon wrote: > > > > On Mon, Mar 15, 2021 at 7:53 PM Inada Naoki wrote: >> >> Hi, all. >> >> I found .pth file is decoded by the default (i

[Python-Dev] Re: pth file encoding

2021-03-16 Thread Brett Cannon
On Mon, Mar 15, 2021 at 7:53 PM Inada Naoki wrote: > Hi, all. > > I found .pth file is decoded by the default (i.e. locale-specific) > encoding. > > https://github.com/python/cpython/blob/0269ce87c9347542c54a653dd78b9f60bb9fa822/Lib/site.py#L173 > > pth files contain: > > * import statements > *

[Python-Dev] Re: Reviving PEP 473

2021-03-16 Thread Victor Stinner
For best performance (reduce time to build an exception object), I would be interested to only format the error message on demand. For example, when str(exception) is called. The problem is the Exception.args attribute. Example: $ ./python Python 3.10.0a6+ >>> exc=AttributeError("%s object has no

[Python-Dev] Re: Rejecting PEP 637 (Support for indexing with keyword arguments)

2021-03-16 Thread Stefano Borini
All right. Thanks for the feedback. Brandt should we terminate the branch, or restructure it for the *args mechanics? On Mon, 15 Mar 2021 at 18:43, Thomas Wouters wrote: > > > Hi Stefano, > > Thank you for submitting PEP 637 (Support for indexing with keyword > arguments). The Steering Council