Guido van Rossum added the comment:

Any solution that encodes Unicode in a way that works for some characters but 
fails for others has the same problem that Unicode had in Python 3. 
Unfortunately we're stuck with such a solution (Latin-1) and for backwards 
compatibility reasons we can't change it. If we were to deprecate it, we should 
warn for *any* data given as a Unicode string, even if it's plain ASCII (even 
if it's an empty string :-).

But even if we don't deprecate it, we can still change the text of the error 
message (but not the type of the exception used) to be more clear.

Can we please start drafting a suitable error message here?

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue26045>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to