How to use Sockets with wxPython?
no at sp.am
Fri Mar 12 22:49:42 CET 2004
> I am having this problem:
> I use Python for my teaching and right now we are trying to implement some
> sort of very simple graphical game the pupils can play across the
> Internet. For this, we use wxPython.
> Now it has turned out that wxPython does not implement wxWidget sockets,
> so we have to use Python sockets instead. Implementing a separate thread
> for this would be too complicated and I am going to use the wxIdle event
> to do the socket processing, as the amount of data sent from one player to
> the other is very small.
You might want to use Twisted instead. You need the very latest version
(1.2 or later) for it to work with wxPython:
You would use Twisted's wxreactor class. Look at the wxdemo.py file
See also this tutorial (part 2 on game networking) on using Twisted with
More information about the Python-list