Author scoder
Recipients eli.bendersky, ethan.furman, flox, jcea, jkloth, ncoghlan, python-dev, scoder
Date 2013-08-27.10:37:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1377599841.03.0.176667545523.issue17741@psf.upfronthosting.co.za>
In-reply-to
Content
> The whole point of the new API is not to replace XMLParser, but to provide a convenience API to set up a particular combination of an XMLParser with a particular kind of custom target.

Ok, but I'm saying that we don't need that. It's all there, it all comes together at the interfaces of the parser. The two-way communication between parser and target already exists and is used by iterparse().

So, what I'm advocating is that we should not complicate the module interface with a new class (and eventually two classes) at all. Instead, we should just expose the *existing* interface of the parser in two ways, once as callbacks and once as collected events. I find that much easier to explain than any of the other proposals I've seen so far.

This is really not about doing it this way because it's technically too difficult to do differently. It's about keeping things simple for users and well integrated with what's there.

BTW, Eli asked for working code before we discuss. I've provided it. Now I would like to see working code for the proposed three-level design in order to make sure it actually works and feels right. I've already said that I've tried it and it didn't feel right. We can continue to discuss hot air for another month or two, or we can stick to discussing real code and real APIs.
History
Date User Action Args
2013-08-27 10:37:21scodersetrecipients: + scoder, jcea, ncoghlan, jkloth, eli.bendersky, flox, ethan.furman, python-dev
2013-08-27 10:37:21scodersetmessageid: <1377599841.03.0.176667545523.issue17741@psf.upfronthosting.co.za>
2013-08-27 10:37:21scoderlinkissue17741 messages
2013-08-27 10:37:20scodercreate