Yahoo screenscrape example was not working for long time now. I had not had a chance to find a reason why. Search sample sitemaps, I had included yahoo screenscrape pipeline somewhere..... Oops, it's gone.
Found it in blocks/html/samples/sitemap.xmap. Does not work:
That happens only if used with the xpath parameter. I debugged a bit as far as possible (is it possible to tell Eclipse not to use the Xalan sources out of JDK's src.zip, but from the path I'm telling it?) and I found out:
org.apache.excalibur.xml.xpath.XPathProcessorImpl:265
final XObject result =
XPathAPI.eval(contextNode, str, new XalanResolver(resolver));works, but the next line
result.nodelist()
(converting the XNodeSet into a nodelist) results in the ArrayIndexOutOfBoundsException.
Found no relating bug in bugzilla.
Tried it with Xalan jar built from CVS and it did neither work.
Joerg
Caused by: java.lang.ArrayIndexOutOfBoundsException: -1
at org.apache.xml.dtm.ref.ExpandedNameTable.getType(ExpandedNameTable.java:354)
at org.apache.xml.dtm.ref.DTMDefaultBase.indexNode(DTMDefaultBase.java:359)
at org.apache.xml.dtm.ref.dom2dtm.DOM2DTM.addNode(DOM2DTM.java:333)
at org.apache.xml.dtm.ref.dom2dtm.DOM2DTM.nextNode(DOM2DTM.java:558)
at org.apache.xml.dtm.ref.DTMDefaultBase._nextsib(DTMDefaultBase.java:603)
at org.apache.xml.dtm.ref.DTMDefaultBase.getNextSibling(DTMDefaultBase.java:1180)
at org.apache.xml.dtm.ref.DTMDefaultBaseTraversers$ChildTraverser.next(DTMDefaultBaseTraversers.java:499)
at org.apache.xpath.axes.AxesWalker.getNextNode(AxesWalker.java:370)
at org.apache.xpath.axes.AxesWalker.nextNode(AxesWalker.java:398)
at org.apache.xpath.axes.WalkingIterator.nextNode(WalkingIterator.java:229)
at org.apache.xpath.axes.NodeSequence.nextNode(NodeSequence.java:318)
at org.apache.xpath.axes.NodeSequence.runTo(NodeSequence.java:472)
at org.apache.xml.dtm.ref.DTMNodeList.<init>(DTMNodeList.java:117)
at org.apache.xpath.objects.XNodeSet.nodelist(XNodeSet.java:376)
at org.apache.excalibur.xml.xpath.XPathProcessorImpl.selectNodeList(XPathProcessorImpl.java:266)
at org.apache.excalibur.xml.xpath.XPathProcessorImpl.selectNodeList(XPathProcessorImpl.java:133)
at org.apache.cocoon.generation.HTMLGenerator.generate(HTMLGenerator.java:320)
Vadim
