Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> you still can’t use XPath 2 portably because libxml2 never implemented it

That's not the fault of the XML community at large, but just a lack of resources for the implementation of an unpaid open source project.

You can happily use XPath 3.1 with Saxon, BaseX, eXist. All three use Java, so, it's not portable, but Saxon has a C library, that mirrors the Java version 1:1, and that C library is also available as open source, though, it lacks some XPath 3.x features, like higher order functions, then.

For the command line, there is a partial XPath 3.1 implementation with 'xidel'.

But I agree, libxml and libxslt being at XPath 1.0 for so long, did not serve XML well.



I classed that as something for the XML community to prioritize because implementations are so important to adoption for standards. If you design standards and want them to be used, at some point you need to figure out how to get resources to support development of key implementations, help major projects migrate to alternative implementations[1], or develop a replacement if nothing better is available.

The fragmentation you mentioned is part of what made this so frustrating: if everything you used was within certain toolchains, the experience was fairly good but then you'd need to use a different ecosystem and either drop back to good old XPath 1 or take on more technical debt. In many cases, the answer I saw people favor was leaving the XML world as quickly as possible, which is something the community has a strong interest in.

1. For example, Saxon added support for Python just a few days ago: https://www.saxonica.com/saxon-c/release-notes.xml Imagine if that had happened a decade ago and everyone who was stuck with libxml2 could have easily switched?


You are right. Too little, too late.

On a fair note, one should also take into account, that Saxonica is a rather small, even if highly skilled, shop and the program, they create, is a huge undertaking.


I’m not faulting Saxonica in any way. It’s just a shame that they seem to be taking this on alone.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: