Bug#336280: [xml/sgml] Re: Bug#336280: FTBFS: Unable to stat doc/dtd.html

2005-11-05 Thread Mike Hommey
On Sat, Nov 05, 2005 at 03:20:18PM +0100, Raphael Hertzog [EMAIL PROTECTED] 
wrote:
 reassign xsltproc 1.1.15-1
 retitle 336280 xsltproc: doesn't recognize variables in some particular 
 situations
 thanks
 
 Le vendredi 28 octobre 2005 à 08:06 -0700, Matt Kraai a écrit :
  Package: logidee-tools
  Version: 1.2.4-2
  Severity: serious
  
  pbuilder fails to build logidee-tools in an unstable chroot on i386:
  
   xsltproc --xinclude --stringparam selection none --stringparam cycle 
   false --stringparam charte gfdl --stringparam trainer false 
   --stringparam lang en --stringparam dir 
   /tmp/buildd/logidee-tools-1.2.4/doc/tools.html  ../xsl/module-html.xsl  
   tools.xml  tools.html/index.html
   XPath error : Undefined variable
   not(@restriction='all' or contains(concat(' ',$selection,' '),concat(' 
   ',@restriction,' '))or not(@restriction) or  $selection='all')
   ^
   compilation error: file ../xsl/ignore.xsl line 23 element template
   Failed to compile predicate
   XPath error : Undefined variable
 
 This is a bug in xsltproc ... because the variable exists and is even
 defined in the command line (and also with xsl:param inside the top
 XSL stylesheet). I could reproduce the bug with xsltproc 1.1.15-1... and
 this code has been working for 4 years already with xsltproc without any
 problem.
 
 Thus I'm reassigning the bug. I also attach ignore.xsl which can be
 used as a minimal test case to reproduce the bug :
 $ xsltproc --stringparam trainer false ignore.xsl
 XPath error : Undefined variable
 not(@trainer=$trainer or $trainer='true' or not(@trainer))
   ^
 compilation error: file ignore.xsl line 9 element template
 Failed to compile predicate

I guess this is the same as #334784, but i don't have time to check
right now. If you have some time, would you test the patch and see if it
helps your problem ?

Cheers,

Mike


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Bug#336280: [xml/sgml] Re: Bug#336280: FTBFS: Unable to stat doc/dtd.html

2005-11-05 Thread Raphael Hertzog
reassign 336280 logidee-tools
retitle 336280 XSL files incorrectly use variables in match pattern
thanks

Le samedi 05 novembre 2005 à 18:06 +0100, Mike Hommey a écrit :
  Thus I'm reassigning the bug. I also attach ignore.xsl which can be
  used as a minimal test case to reproduce the bug :
  $ xsltproc --stringparam trainer false ignore.xsl
  XPath error : Undefined variable
  not(@trainer=$trainer or $trainer='true' or not(@trainer))
^
  compilation error: file ignore.xsl line 9 element template
  Failed to compile predicate
 
 I guess this is the same as #334784, but i don't have time to check
 right now. If you have some time, would you test the patch and see if it
 helps your problem ?

I tried and it doesn't help. Actually it looks like #329678 because the
variable is in a match pattern too ... but I don't understand your
reasoning for closing the bug.

If I check the Pattern grammar, it leads Predicate which is [Expr]
and Expr can certainly include variables... so I checked the ChangeLog
of libxslt and by recursion I found this :
http://bugzilla.gnome.org/show_bug.cgi?id=303289
http://www.w3.org/TR/xslt#section-Defining-Template-Rules

I hate when good features are removed because the standard says so
without explaining why it makes sense ... in particular when I don't
know any clean workaround to do the same thing. :-(

Regards,
-- 
Raphaël Hertzog -+- http://www.ouaza.com

Freexian : des développeurs Debian au service des entreprises
http://www.freexian.com




Bug#336280: [xml/sgml] Re: Bug#336280: FTBFS: Unable to stat doc/dtd.html

2005-11-05 Thread Mike Hommey
On Sat, Nov 05, 2005 at 07:15:27PM +0100, Raphael Hertzog [EMAIL PROTECTED] 
wrote:
 reassign 336280 logidee-tools
 retitle 336280 XSL files incorrectly use variables in match pattern
 thanks
 
 Le samedi 05 novembre 2005 à 18:06 +0100, Mike Hommey a écrit :
   Thus I'm reassigning the bug. I also attach ignore.xsl which can be
   used as a minimal test case to reproduce the bug :
   $ xsltproc --stringparam trainer false ignore.xsl
   XPath error : Undefined variable
   not(@trainer=$trainer or $trainer='true' or not(@trainer))
 ^
   compilation error: file ignore.xsl line 9 element template
   Failed to compile predicate
  
  I guess this is the same as #334784, but i don't have time to check
  right now. If you have some time, would you test the patch and see if it
  helps your problem ?
 
 I tried and it doesn't help. Actually it looks like #329678 because the
 variable is in a match pattern too ... but I don't understand your
 reasoning for closing the bug.
 
 If I check the Pattern grammar, it leads Predicate which is [Expr]
 and Expr can certainly include variables... so I checked the ChangeLog
 of libxslt and by recursion I found this :
 http://bugzilla.gnome.org/show_bug.cgi?id=303289
 http://www.w3.org/TR/xslt#section-Defining-Template-Rules
 
 I hate when good features are removed because the standard says so
 without explaining why it makes sense ... in particular when I don't
 know any clean workaround to do the same thing. :-(

You can work around with xsl:choose or xsl:if clauses inside the
xsl:template.

If you can tell which files are concerned and where i can find them, i
can help when i have some time for it (or if it's just trivial).

Mike


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Bug#336280: [xml/sgml] Re: Bug#336280: FTBFS: Unable to stat doc/dtd.html

2005-11-05 Thread Raphael Hertzog
Le samedi 05 novembre 2005 à 20:02 +0100, Mike Hommey a écrit :
  I hate when good features are removed because the standard says so
  without explaining why it makes sense ... in particular when I don't
  know any clean workaround to do the same thing. :-(
 
 You can work around with xsl:choose or xsl:if clauses inside the
 xsl:template.

Yeah I know that, but in my case it's uglier than before. I have an
ignore stylesheet which defines high priority templates to override some
specific templates ... but the criteria to define the specificity
includes this variable.

This ignore stylesheet is used by several other stylesheet. I have to
put dozens of xsl:if in several stylesheets when 3 generic templates did
the work until now.

 If you can tell which files are concerned and where i can find them, i
 can help when i have some time for it (or if it's just trivial).

Thanks for the offer, but I'm the upstream of logidee-tools so I know it
well enough to be able to fix it myself ... It's just bothersome to do
when it used to work. :-)

Cheers,
-- 
Raphaël Hertzog -+- http://www.ouaza.com

Freexian : des développeurs Debian au service des entreprises
http://www.freexian.com




Bug#336280: [xml/sgml] Re: Bug#336280: FTBFS: Unable to stat doc/dtd.html

2005-11-05 Thread Mike Hommey
On Sat, Nov 05, 2005 at 09:16:19PM +0100, Raphael Hertzog [EMAIL PROTECTED] 
wrote:
 Le samedi 05 novembre 2005 à 20:02 +0100, Mike Hommey a écrit :
   I hate when good features are removed because the standard says so
   without explaining why it makes sense ... in particular when I don't
   know any clean workaround to do the same thing. :-(
  
  You can work around with xsl:choose or xsl:if clauses inside the
  xsl:template.
 
 Yeah I know that, but in my case it's uglier than before. I have an
 ignore stylesheet which defines high priority templates to override some
 specific templates ... but the criteria to define the specificity
 includes this variable.
 
 This ignore stylesheet is used by several other stylesheet. I have to
 put dozens of xsl:if in several stylesheets when 3 generic templates did
 the work until now.

Maybe you can hack something with modes ? Well, that depends on how your
stuff is done...

Mike


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]