Message224819
Serhiy: your patch still changes the type of exception, for
s.sendto(b'hello',(u'thisisaverylongstringthisisaverylongstringthisisaverylongstringthisisaverylongstring', 4242))
You get a UnicodeError now, but a socket.gaierror then. This is because the name encodes fine as ascii, but still violates the IDNA requirement on label length. My patch does the same. I don't see where your and my patch differ in behavior.
But I agree that your patch is certainly much simpler, while mine might be slightly faster (for not creating copies of the host name).
I'm fine with either being applied. Antoine? |
|
Date |
User |
Action |
Args |
2014-08-05 11:12:58 | loewis | set | recipients:
+ loewis, gvanrossum, ncoghlan, pitrou, vstinner, neologix, serhiy.storchaka |
2014-08-05 11:12:58 | loewis | set | messageid: <1407237178.09.0.481711982927.issue22127@psf.upfronthosting.co.za> |
2014-08-05 11:12:58 | loewis | link | issue22127 messages |
2014-08-05 11:12:57 | loewis | create | |
|