Message119320
>>> s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
>>> s.bind(('', 0))
>>> s.sendto(u'hellé', s.getsockname())
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: sendto() takes exactly 3 arguments (2 given)
>>> s.sendto(3, s.getsockname())
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: sendto() takes exactly 3 arguments (2 given)
>>> s.sendto('hello', s.getsockname())
5
The TypeError gives the wrong explanation for what's wrong. |
|
Date |
User |
Action |
Args |
2010-10-21 17:22:08 | exarkun | set | recipients:
+ exarkun |
2010-10-21 17:22:08 | exarkun | set | messageid: <1287681728.0.0.651147678785.issue10169@psf.upfronthosting.co.za> |
2010-10-21 17:22:06 | exarkun | link | issue10169 messages |
2010-10-21 17:22:05 | exarkun | create | |
|