I think the strictness comes from the observation that the stdlib is read and edited using *lots* of different tools and not every tool is with the program. That argument may be weaker now than when that PEP was written, but I still get emails and see websites with mojibake. (Most recently, the US-PyCon badges had spaces for all non-ASCII letters.)
The argument is also weaker for comments than it is for identifiers, since stdlib identifiers will be used through *even more* tools (anyone who uses a name imported from stdlib). Docstrings are perhaps halfway in between. On Sun, Jun 4, 2017 at 8:33 PM, Nick Coghlan <ncogh...@gmail.com> wrote: > On 5 June 2017 at 07:00, Guido van Rossum <gvanros...@gmail.com> wrote: > > AFAK it was in whatever PEP introduced Unicode identifiers. > > Ah, indeed it is: https://www.python.org/dev/peps/pep-3131/#policy- > specification > > Interestingly, that's stricter than my draft PR for PEP 8, and I'm not > entirely sure we follow the "string literals and comments must be in > ASCII" part in its entirety: > > ============ > All identifiers in the Python standard library MUST use ASCII-only > identifiers, and SHOULD use English words wherever feasible (in many > cases, abbreviations and technical terms are used which aren't > English). In addition, string literals and comments must also be in > ASCII. The only exceptions are (a) test cases testing the non-ASCII > features, and (b) names of authors. Authors whose names are not based > on the Latin alphabet MUST provide a Latin transliteration of their > names. > ============ > > That said, all the potential counter-examples that come to mind are in > the documentation, but *not* in the corresponding docstrings (e.g. the > Euro symbol used in in the docs for chr() and ord()). > > Cheers, > Nick. > > -- > Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia > -- --Guido van Rossum (python.org/~guido)
_______________________________________________ Python-ideas mailing list Python-ideas@python.org https://mail.python.org/mailman/listinfo/python-ideas Code of Conduct: http://python.org/psf/codeofconduct/