[Python-bugs-list] [Bug #132933] list.sort doesn't detect comparision errors
noreply@sourceforge.net
noreply@sourceforge.net
Sun, 18 Feb 2001 03:28:56 -0800
Bug #132933, was updated on 2001-Feb-18 03:28
Here is a current snapshot of the bug.
Project: Python
Category: Python Interpreter Core
Status: Open
Resolution: None
Bug Group: None
Priority: 5
Submitted by: effbot
Assigned to : nobody
Summary: list.sort doesn't detect comparision errors
Details: 2.0 does the right thing:
Python 2.0 (#8, Jan 29 2001, 22:28:01) on win32
>>> a = [u"foo", "bär"]
>>> a.sort()
Traceback (most recent call last):
File "<stdin>", line 1, in ?
UnicodeError: ASCII decoding error: ordinal not in range(128)
2.1 doesn't:
Python 2.1a2 (#10, Feb 18 2001, 00:16:17) on win32
>>> a = [u"foo", "bär"]
>>> a.sort()
>>> a
UnicodeError: ASCII decoding error: ordinal not in range(128)
>>> a
['b\x84r', u'foo']
>>> a.sort()
>>> a = 10
UnicodeError: ASCII decoding error: ordinal not in range(128)
>>> a.sort()
>>> # hey, what's going on here?
...
UnicodeError: ASCII decoding error: ordinal not in range(128)
>>> quit
'Use Ctrl-Z plus Return to exit.'
(reboot)
For detailed info, follow this link:
http://sourceforge.net/bugs/?func=detailbug&bug_id=132933&group_id=5470