On Jul 1, 2005, at 9:39 AM, Antoine Pitrou wrote:
IMHO the point here is the trivial functionality. As far as I can tell from the few examples of event-driven applications that I use which I didn't write :-), there is a progression that many event-driven Python programs go through these days:
- Implement something with asyncore - realize asyncore's deficiencies, start enhancing it - discover Twisted, re-implement networking code (from scratch)
If the event loop in Python provided similar interfaces to the one in Twisted, the amount of work involved in stage 3 could be greatly reduced.
As a humble lurker on this list, I just wanna say that this argument rings a bell. I had to rewrite a P2P program which had chosen to implement its own event loop instead of using Twisted... ;)
I did this once too, s/P2P program/XML Socket Server/ It turned out that doing one in Twisted was so easy, that I never bothered to package another one again. Everything else I had in there was more or less YAGNI because Twisted already did it, or made implementing the features so trivial as it wasn't worth including it. These days I just whip up app-specific LineReceivers with a '\0' delimiter that parse/generate with ElementTree.. takes like 5 minutes. -bob