[Twisted-Python] Status of twisted.xish.xpath

Donovan Preston dp at ulaluma.com
Mon Apr 12 10:18:32 MDT 2004


On Apr 12, 2004, at 11:59 AM, Dave Smith wrote:

>> I was wondering what's the status of the xpath parser in Twisted.
>
> Well, xish.xpath isn't meant to be a "full" xpath implementation, per 
> se.
> I originally wrote it be used for routing XML packets from a Jabber
> connection, so it's really focused on providing matching/equality
> operations versus the transforms and other operations traditionally
> associated with XPath engines. In my happy little world, XPath is not a
> operational language -- it's a filtering/matching syntax.

Does XPath actually specify transformation operations? I thought that 
was up to something like XSLT. I agree that XPath should only be used 
for node matching, and that transformation should be done in other 
ways.

> I wasn't aware that Nevow was using xish.xpath, but that's cool if it 
> is.
> I'll be glad to add additional logic as necessary to enhance the
> filtering/matching aspects of XPath to support a RSS aggregator, but 
> I'd
> prefer to not see xish.xpath become a "full" XPath engine.

This is not related to the current discussion, but I have been 
contemplating replacing nevow's fixed scheme which only looks for nodes 
with nevow 'specials' on them (such as render and data) with a 
dictionary of {xpath expression object: transformation function}. It is 
not something I am planning on doing right away, but eventually, and it 
would be nice to use some existing code for this.

> FWIW, xish.xpath is "actively developed", there just haven't been any
> feature or bug requests against it for a while. :)

I wish more software were in this mode. "It's flexible enough to use 
without having to change the internals" is the holy grail of software 
engineering.

dp





More information about the Twisted-Python mailing list