[issue26151] str(bytes) does __repr__() instead of __str__()

2016-01-19 Thread Johnny Wezel
Johnny Wezel added the comment: > But this leads to uninspectable objects. An inspection would be done with repr() which should not cause a problem. Besides. the official and correct way of handling an ff character is to emit a Unicode replacement code, not to issue an exception. Another f

[issue26151] str(bytes) does __repr__() instead of __str__()

2016-01-19 Thread Johnny Wezel
Johnny Wezel added the comment: The other question is why one would want to run such a statement. This is almost certainly a bug in which case an error one would be better off with an exception. -- ___ Python tracker <http://bugs.python.

[issue26151] str(bytes) does __repr__() instead of __str__()

2016-01-19 Thread Johnny Wezel
Johnny Wezel added the comment: Who's talking about latin-1 in Python3? Of course str() needs to return decode('utf-8'). -- ___ Python tracker <http://bugs.pyt

[issue26151] str(bytes) does __repr__() instead of __str__()

2016-01-19 Thread Johnny Wezel
Johnny Wezel added the comment: Bad feature, as it is a violation of POLA. -- ___ Python tracker <http://bugs.python.org/issue26151> ___ ___ Python-bugs-list m

[issue26151] str(bytes) does __repr__() instead of __str__()

2016-01-19 Thread Johnny Wezel
New submission from Johnny Wezel: str(b'xxx') returns "b'xxx'" instead of 'xxx' -- components: Interpreter Core, Unicode messages: 258583 nosy: ezio.melotti, haypo, jwezel priority: normal severity: normal status: open title: str(bytes) d

[issue20562] sqlite3 returns result set with doubled first entry

2014-02-08 Thread Johnny Wezel
New submission from Johnny Wezel: I could isolate a bug where sqlite3 returns a result set from a select where the first entry occurs twice. >>> sys.version_info sys.version_info(major=2, minor=7, micro=5, releaselevel='final', serial=0) >>> import sqlite3 >&