On Tue, 9 Feb 2021 at 16:52, Anders Munch <[email protected]> wrote: >> How about swapping around "locale" and None? That is, make "locale" the new >> default that emits a warning, and encoding=None emits no warning. That has >> the advantage that old code can be updated to say encoding=None, and then it >> will work on both old and new Pythons without warning. Paul Moore [mailto:[email protected]] > I don't understand why working code should have to change *twice*.
The idea is to make is so that working code only needs to change once, even when supporting multiple Python versions. That one change is to add either an explicit encoding=None (for backwards-compatibility) or an explicit encoding='utf-8' (because that was intended all along). No twice about it, one change. regards, Anders _______________________________________________ Python-Dev mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/[email protected]/message/BTIXV47LDYPKNIGWNRQSG6LXG4DORS7W/ Code of Conduct: http://python.org/psf/codeofconduct/
