using the above, I ran into the following:
for client in server.clients.values(): RuntimeError: dictionary changed size during iteration
this seems a real problem, as some client may be connecting/disconnecting during this for loop. I think adding a list() around server.clients.values() should avoid this, but I haven't tested it thoroughly