[xml/sgml-pkgs] Bug#375780: XPath error : Undefined namespace prefix

Mike Hommey mh at glandium.org
Fri Nov 17 07:12:48 UTC 2006


On Tue, Jun 27, 2006 at 06:20:46PM -0700, ms419 at freezone.co.uk <ms419 at freezone.co.uk> wrote:
> Package: xsltproc
> Version: 1.1.17-1
> 
> This test case should get the value of /package/name - "Auth_SASL"
> 
> fis% xsltproc --novalid --param Element "/pk:package/pk:name"
> http://cgi.sfu.ca/~jdbates/tmp/xslt/200606270/common.xsl
> http://cgi.sfu.ca/~jdbates/tmp/xslt/200606270/package0.xml
> XPath error : Undefined namespace prefix
> xmlXPathCompiledEval: evaluation failed
> runtime error
> Evaluating user parameter Element failed
> fis% 
> 
> A friend on #xml reports that libxslt 1.1.15-1ubuntu1 correctly gets
> "Auth_SASL"
> 
> Thanks - Jack

Actually, that sounds like not a bug to me.

Take a look at what xsltproc -v has to say about your transformation. It
actually can't resolve /pk:package/pk:name because it doesn't know the
pk namespace from the command line. If you do the same, but from within
the xslt, it will work.

Mike





More information about the debian-xml-sgml-pkgs mailing list