2010/5/7 Antoine Pitrou <solip...@pitrou.net>: > Le Fri, 07 May 2010 16:36:44 +0200, Giampaolo Rodolà a écrit : >> You can easily avoid this by setting a lower timeout when calling >> asyncore.loop(), like 1 second or less (for example, Twisted uses 0.001 >> secs). >> Actually there's no reason for asyncore to have such a high default >> timeout (30 seconds). > > The reason for a high default timeout would be to avoid waking the CPU > and do useless work too often. This is important on laptops and smaller > devices, in order to conserve power. >
Of course, but 30 seconds look a little bit too much to me, also because (I might be wrong here) I noticed that a smaller timeout seems to result in better performances. Plus, if scheduled callbacks are ever gonna be added to asyncore we would be forced to lower the default timeout anyway in order to have a decent reactivity. --- Giampaolo http://code.google.com/p/pyftpdlib http://code.google.com/p/psutil -- http://mail.python.org/mailman/listinfo/python-list