Nick Coghlan added the comment:
The main problem with the "undefined" encoding is that it actually *fails* the
application, rather than allowing it to continue, but providing a warning at
each new point where it encounters implicit encoding or decoding. This means
the parts of the standard lib
Marc-Andre Lemburg added the comment:
Nick, I think you've missed the "undefined" encoding that we've had for this
ever since Unicode was added to Python.
You put the needed code into your sitecustomize.py file and Python2 will then
behave just like Python3, i.e. raise an exception instead of
Nick Coghlan added the comment:
(Correction to the above: the case where this came up turned out to be due to
consuming code monkeypatching things when it really shouldn't have been, so it
fell into the second category of "It would have been helpful to be able to more
easily rule this out as a
New submission from Nick Coghlan:
Some of the hardest compatibility issues to track down in Python 3 migrations
are those where existing code is depending on an implicit str->unicode
promotion something in the depths of a support library (or sometimes even the
standard library - the context wh