I m following this tutorial: http://www.raywenderlich.com/3932/how-to-create-a-socket-based-iphone-app-and-server
但我写了字。
reactor.listenTCP(80, factory)
eclipse tells me that it s an undefined variable.. I installed twisted and can get autocomplete for the import, but this won t work.. Google showed a few more having this issue but I couldn t find any solution to it.. Thanks!
EDIT: The complete code:
from twisted.internet.protocol import Factory
from twisted.internet import reactor
factory = Factory()
reactor.listenTCP(80, factory)
reactor.run()