Message206165
Okay, I think the error message can be improved because in Python 2.7 we differentiate very clearly the string from the unicode.
>>> import struct
>>> struct.Struct(1)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: Struct() argument 1 must be string, not int
But you can give unicode, right?
>>> struct.Struct(u'b')
<Struct object at 0x1f484b8>
This is consistent with other example:
>>> " cutecat ".strip(1)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: strip arg must be None, str or unicode
What do you say, Serhiy?
Here is the patch. |
|
Date |
User |
Action |
Args |
2013-12-14 04:13:50 | vajrasky | set | recipients:
+ vajrasky, mark.dickinson, pitrou, ezio.melotti, miwa, meador.inge, python-dev, serhiy.storchaka |
2013-12-14 04:13:50 | vajrasky | set | messageid: <1386994430.22.0.113816783649.issue19099@psf.upfronthosting.co.za> |
2013-12-14 04:13:50 | vajrasky | link | issue19099 messages |
2013-12-14 04:13:49 | vajrasky | create | |
|