ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Loehr, Ruel" <>
Subject RE: Java error in heretofore stable, working task
Date Thu, 23 Aug 2007 14:55:15 GMT
The errors where nothing has changed are always tough to debug.    When
it happens to me, I usually find out something has changed.

Have you tried printing out the classpath that the xslt task is using?

Seems to me that it is the most likely culprit.

-----Original Message-----
From: [] 
Sent: Thursday, August 23, 2007 9:51 AM
Subject: Java error in heretofore stable, working task

Pertinent facts:
Ant - version 1.7.0
JDK - version

I have a task that has been performing as expected for about five
months. Today, with no change in the version of Ant, the build.xml file,
the JDK, the stylesheet, or the XSLT processor, this error occurred for
the first time (and appears on all subsequent attempts to run the task):

build.xml:82: java.lang.reflect.InvocationTargetException

The task beginning on line 82 is:

<xslt style="${env.REPORTS_HOME}/Errors/PackedField/xslt/stage-1.xslt"
in="${xml.dir}/${DSTAMP}.c.xml" out="${xml.dir}/${DSTAMP}.d.xml"
  <param name="position-codes"
ml" />

When I run the transformation from the command line, the output document
is produced with no complaint.

My command line invocation is:

java net.sf.saxon.Transform  -o ./xml/20070823.d.xml
./xml/20070823.c.xml ./xslt/stage-1.xslt

I tried replacing the <xslt> task with a <java> task to see if the
problem was related to the code behind the <xslt> task, but so far I
haven't been able to get the java task to execute.

Java task:

<java classname="net.sf.saxon.Transform" fork="true">
  <arg value="o ./xml/20070823.d.xml" />
  <arg value="./xml/20070823.c.xml" />
  <arg value="./xslt/stage-1.xslt" />
tion.xml" />

The error I'm getting on the Java task is:

     [java] Bad param=value pair on command line: ./xslt/stage-1.xslt
     [java] Saxon 8.7.3J from Saxonica
     [java] Usage: java net.sf.saxon.Transform [options] source-doc
style-doc {param=value}...

A Google search on "ant java.lang.reflect.InvocationTargetException
xslt" has not yielded anything useful.

Something that suddenly stops working without an obvious explanation is
very troubling. Does anyone have an idea on this?

Charles Knell - email

To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message