Menu

#2 Improper use of bind, easy fix.

open
nobody
None
5
2002-10-21
2002-10-21
Anonymous
No

Traceback (most recent call last):
File "./mmaker.py", line 39, in ?
server = sServer.Server(port, world)
File "./sServer.py", line 29, in __init__
self._sock.bind('', port)

Call to bind should be:
self._sock.bind(('', port))

Bind only takes one argument, which is a tuple (hence
the double parenthesis). Kind of an odd mistake..
unless older versions of Python allowed this.

After this small modification the server seems to at
least start properly. Haven't gotten much farther into
looking at it then that though.

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.