Message239236
| Author |
serhiy.storchaka |
| Recipients |
larry, serhiy.storchaka, taleinat |
| Date |
2015年03月25日.08:25:28 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1427271928.64.0.665277905014.issue20181@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
The only difference is in error message.
For now:
>>> unicodedata.name(123)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: must be str, not int
>>> unicodedata.name('123')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: need a single Unicode character as parameter
Patched:
>>> unicodedata.name(123)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: must be a unicode character, not int
>>> unicodedata.name('123')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: must be a unicode character, not str
If you think old messages were better, we can change standard error messages for 'C' format unit. We already changed standard and specialized error messages in 3.5 and earlier. In 3.4 it looks as:
>>> unicodedata.name(123)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: must be str, not int
>>> unicodedata.name('123')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: need a single Unicode character as parameter |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2015年03月25日 08:25:28 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, taleinat, larry |
| 2015年03月25日 08:25:28 | serhiy.storchaka | set | messageid: <1427271928.64.0.665277905014.issue20181@psf.upfronthosting.co.za> |
| 2015年03月25日 08:25:28 | serhiy.storchaka | link | issue20181 messages |
| 2015年03月25日 08:25:28 | serhiy.storchaka | create |
|