R. David Murray <rdmur...@bitdance.com> added the comment:

I agree with you that this is inconsistent.  However, having str raise an error 
is pretty much a non-starter as a suggestion.  str always falls back to the 
repr; in general str(obj) should always return some value, otherwise the 
assumptions of a *lot* of Python code would be broken.

Personally I'm not at all sure why str takes encoding and errors arguments (I 
never use them). I'd rather there be only one way to do that, decode.  In other 
words, why do we have special case support for byte strings in the str 
conversion function?

But I don't think that can be changed either, so I think we are stuck with 
documenting the existing situation better.  Do you want to propose a doc patch?

----------
assignee:  -> docs@python
components: +Documentation -Interpreter Core
nosy: +docs@python, r.david.murray
versions: +Python 3.3

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

Reply via email to