You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "Magne Rasmussen (JIRA)" <ji...@codehaus.org> on 2005/06/20 15:11:53 UTC

[jira] Commented: (MAVEN-1630) Properties section in POM cannot be read

    [ http://jira.codehaus.org/browse/MAVEN-1630?page=comments#action_41699 ] 

Magne Rasmussen commented on MAVEN-1630:
----------------------------------------

It seems like the class org.apache.maven.artifact.PomRewriter.java (in the artifact plugin) has been compiled with an old version of the model, because the line d.setProperties( null ); in method getRewrittenModel( File file, JellyContext context ) fails with a method not found: Dependency.setProperties(java.util.List). The method that exists in Dependency is setProperties(Properties). Just compile the plugin with the correct model, and everything works again.

> Properties section in POM cannot be read
> ----------------------------------------
>
>          Key: MAVEN-1630
>          URL: http://jira.codehaus.org/browse/MAVEN-1630
>      Project: maven
>         Type: Bug
>     Versions: 1.1-beta-1
>  Environment: windows xp sp1, JVM 1.4.2_05
>     Reporter: Andreas Schönknecht
>      Fix For: 1.1-beta-2

>
>
> I just tried the Maven 1.1 beta. Unfortunately I get errors when my 
> POMs contains custom properties. Here is an example: At the end of the 
> POM I have a properties section:
> ...
>     </dependencies>
>     <properties>
>         <deputy isAssembly="false" >
>             <rules>
>                 <default value="LATEST RELEASE" />
>                 <enforcements>
>                     <enforcement>
>                         <groupId>tui-iris</groupId>
>                         <artifactId>tuiiris</artifactId>
>                         <version>1.0.2</version>
>                     </enforcement>
>                 </enforcements>
>                 <deprecations />
>                 <replacements />
>                 <removals />
>             </rules>
>         </deputy>
>     </properties>
> </project>
> As far as I understood it should be possible to have custom properties 
> in the POM. But when I execute any Maven goal I get:
> org.codehaus.plexus.util.xml.pull.XmlPullParserException: TEXT must be immediately followed by END_TAG and not START_TAG (position: START_TAG seen ...<deputy isAssembly="false" \r\n            <rules>... @185:20)
>         at org.codehaus.plexus.util.xml.pull.MXParser.nextText(MXParser.java:1059)
>         at org.apache.maven.project.io.xpp3.MavenXpp3Reader.parseModel(MavenXpp3Reader.java:834)
>         at org.apache.maven.project.io.xpp3.MavenXpp3Reader.read(MavenXpp3Reader.java:1621)
>         at org.apache.maven.project.Project.<init>(Project.java:120)
>         at org.apache.maven.MavenUtils.getNonJellyProject(MavenUtils.java:185)
>         at org.apache.maven.MavenUtils.getProject(MavenUtils.java:120)
>         at org.apache.maven.MavenUtils.getProject(MavenUtils.java:99)
>         at org.apache.maven.MavenSession.initializeRootProject(MavenSession.java:232)
>         at org.apache.maven.MavenSession.initialize(MavenSession.java:172)
>         at org.apache.maven.cli.App.doMain(App.java:498)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org