Hello!


I was wondering if someone could help me - I'm trying to get my project building with maven, but seem to consistantly get a NumberFormatException whenever I give it the path to my source code.

This is a partial stack trace:

java.lang.NumberFormatException: For input string: "includes"
at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
at java.lang.Integer.parseInt(Integer.java:426)
at java.lang.Integer.valueOf(Integer.java:532)
at org.apache.commons.jexl.util.Coercion.coerceInteger(Coercion.java:95)
at org.apache.commons.jexl.parser.ASTArrayAccess.evaluateExpr(ASTArrayAccess.java:177)
at org.apache.commons.jexl.parser.ASTIdentifier.execute(ASTIdentifier.java:104)
at org.apache.commons.jexl.parser.ASTReference.execute(ASTReference.java:106)
at org.apache.commons.jexl.parser.ASTReference.value(ASTReference.java:88)
at org.apache.commons.jexl.parser.ASTNotNode.value(ASTNotNode.java:88)
at org.apache.commons.jexl.parser.ASTExpression.value(ASTExpression.java:85)
at org.apache.commons.jexl.ExpressionImpl.evaluate(ExpressionImpl.java:123)
at org.apache.commons.jelly.expression.jexl.JexlExpression.evaluate(JexlExpression.java:115)
at org.apache.commons.jelly.expression.jexl.JexlExpressionFactory$ExpressionSupportLocal.evaluate(JexlExpressionFactory.java:168)
at org.apache.commons.jelly.expression.ExpressionSupport.evaluateRecurse(ExpressionSupport.java:106)
at org.apache.commons.jelly.expression.ExpressionSupport.evaluateAsBoolean(ExpressionSupport.java:116)
at org.apache.commons.jelly.tags.core.WhenTag.doTag(WhenTag.java:90)
at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:279)
at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:135)
at org.apache.commons.jelly.TagSupport.invokeBody(TagSupport.java:233)
at org.apache.commons.jelly.tags.core.ChooseTag.doTag(ChooseTag.java:84)
at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:279)
at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:135)
at org.apache.commons.jelly.TagSupport.invokeBody(TagSupport.java:233)
at com.werken.werkz.jelly.ProjectTag.doTag(ProjectTag.java:112)
at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:279)
at org.apache.maven.jelly.JellyUtils.runScript(JellyUtils.java:112)
at org.apache.maven.jelly.JellyUtils.runScript(JellyUtils.java:139)
at org.apache.maven.plugin.PluginManager.loadPlugin(PluginManager.java:673)
at org.apache.maven.plugin.PluginManager.prepForGoal(PluginManager.java:475)
at org.apache.maven.MavenSession.prepForGoal(MavenSession.java:260)
....


I also get about 20 errors similar to the following:

2003-04-01 11:28:49,538 ERROR org.apache.commons.jelly.tags.ant.AntTag - Class org.apache.commons.jelly.tags.core.IfTag doesn't support the nested "available" element.
2003-04-01 11:28:49,548 ERROR org.apache.commons.jelly.tags.ant.AntTag - Class com.werken.werkz.jelly.ProjectTag doesn't support the nested "path" element.



I think the problem may be that I'm having difficulty getting my jars on the classpath during the build, but as everything I try seems to return these errors its difficult to work out what I'm doing wrong. This is the build part of my project.xml file: (there are no dependencies defined; my project builds fine using ant, so I don't think its a code problem)


<build>

   <nagEmailAddress>
     [EMAIL PROTECTED]
   </nagEmailAddress>

<sourceDirectory>myproject/src</sourceDirectory>

   <unitTestSourceDirectory></unitTestSourceDirectory>
   <integrationUnitTestSourceDirectory/>

<aspectSourceDirectory/>

   <unitTest>
   </unitTest>

   <!-- J A R  R E S O U R C E S -->
   <!-- Resources that are packaged up inside the JAR file -->
   <resources>
     <includes>
       <include>servlet.jar</include>
     </includes>
   </resources>

<integrationUnitTest/>

   <jars>
   </jars>

</build>

I get the same problem with no jars included (under resources), with the jars under the <jar> tag instead, and with the jars defined under dependencies (I'm not convinced I'm doing it right for any of them though). The exception doesn't occur if I replace the source directory to something like: <sourceDirectory>myproject/noneexistantdirectory/src</sourceDirectory>.

Has anyone encountered this before and could give me a hint? Or an example of how to properly include some jars on the classpath during the build from the 'myproject/lib directory' would be much appreciated!

Apologies if I'm just doing something stupid :)

Cheers,
Nick





_________________________________________________________________
Express yourself with cool emoticons http://www.msn.co.uk/messenger


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to