You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Peter Sherwood (JIRA)" <ji...@codehaus.org> on 2011/12/09 10:49:39 UTC

[jira] Created: (MANTRUN-173) maven-antrun-plugin not forward compatible with maven 3.

maven-antrun-plugin not forward compatible with maven 3.
--------------------------------------------------------

                 Key: MANTRUN-173
                 URL: https://jira.codehaus.org/browse/MANTRUN-173
             Project: Maven 2.x Antrun Plugin
          Issue Type: Bug
    Affects Versions: 1.7
         Environment: Windows 7, Maven 3, Java 1.6
            Reporter: Peter Sherwood
            Priority: Critical
         Attachments: mavenerror.txt

In some environments we do not have a Nexus style repository and so to make an out of the box build cycle we use antrun to install a jar into a local repository. This works absolutely fine with no exceptions in Maven 2.2.1 in the same environment mentioned above. Moving directly to Maven 3 the build does not work and records the following exception:

Caused by: java.lang.NoSuchMethodError: org/apache/maven/settings/RuntimeInfo.<init>(Lorg/apache/maven/settings/Settings;)V
	at org.apache.maven.artifact.ant.AbstractArtifactTask.readSettings(AbstractArtifactTask.java:382)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.loadSettings(AbstractArtifactTask.java:311)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.initSettings(AbstractArtifactTask.java:278)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.getSettings(AbstractArtifactTask.java:223)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.getDefaultLocalRepository(AbstractArtifactTask.java:212)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.getLocalRepository(AbstractArtifactTask.java:700)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.createLocalArtifactRepository(AbstractArtifactTask.java:110)
	at org.apache.maven.artifact.ant.Pom.getMavenProject(Pom.java:272)
	at org.apache.maven.artifact.ant.Pom.setVersion(Pom.java:570)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
	at java.lang.reflect.Method.invoke(Method.java:611)
	at org.apache.tools.ant.IntrospectionHelper$AttributeSetter.setObject(IntrospectionHelper.java:1498)
	at org.apache.tools.ant.IntrospectionHelper.setAttribute(IntrospectionHelper.java:405)
	... 38 more

My POM is as follows and has been cut down to show the problem only.
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
         xmlns:artifact="antlib:org.apache.maven.artifact.ant">
    <modelVersion>4.0.0</modelVersion>

    <groupId>MavenAntTest</groupId>
    <artifactId>MavenAntTest</artifactId>
    <version>1.0</version>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-antrun-plugin</artifactId>
                <version>1.7</version>
                <executions>
                    <execution>
                        <phase>initialize</phase>
                        <configuration>

                            <target xmlns:artifact="antlib:org.apache.maven.artifact.ant">
                                <path id="maven-ant-tasks.classpath"
                                      path="${settings.localRepository}${file.separator}org${file.separator}apache${file.separator}maven${file.separator}maven-ant-tasks${file.separator}2.1.3${file.separator}maven-ant-tasks-2.1.3.jar" />
                                <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
                                         uri="antlib:org.apache.maven.artifact.ant" classpathref="maven-ant-tasks.classpath" />
                                <taskdef resource="net/sf/antcontrib/antcontrib.properties"
                                         classpathref="maven.plugin.classpath" />
                                <artifact:pom id="saxonInstall" groupId="net.sf.saxon" artifactId="saxon"
                                              version="9.3.0.5" name="Saxon XSLT Parser">
                                </artifact:pom>
                                <if>
                                    <available file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.jar" type="file" />
                                    <then>
                                        <echo message="Saxon jar already copied"/>
                                    </then>
                                    <else>
                                        <mkdir dir="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5"/>
                                        <artifact:writepom pomRefId="saxonInstall" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
                                        <artifact:pom id="netpom" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />

                                        <artifact:install file="${project.basedir}/src/main/resources/saxon-9.3.0.5.jar" pomRefId="netpom"/>
                                    </else>
                                </if>

                            </target>
                        </configuration>
                        <goals>
                            <goal>run</goal>
                        </goals>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>ant-contrib</groupId>
                        <artifactId>ant-contrib</artifactId>
                        <version>20020829</version>
                    </dependency>
                </dependencies>
            </plugin>
        </plugins>
    </build>


</project>

I attach the full maven output that shows the full problem report.
I also attach the working maven 2 output.
Please investigate for me.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] (MANTRUN-173) maven-antrun-plugin not forward compatible with maven 3.

Posted by "Darryl L. Miles (JIRA)" <ji...@codehaus.org>.
    [ https://jira.codehaus.org/browse/MANTRUN-173?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=307742#comment-307742 ] 

Darryl L. Miles edited comment on MANTRUN-173 at 9/4/12 6:24 PM:
-----------------------------------------------------------------

This is a patch for inclusion in MANTRUN for the 1.x (1.7/1.8) releases.

This should maintain existing compatibility (because a dead/unrequired extra dependency does not harm usage, even if not the most efficient).

Then for Maven 3.x users it will allow this plugin to just work without change.  However I am not at all sure how Maven 3.x manages to resolve org.apache.maven:maven-project:3.x since that does not exist.

USE THIS PATCH FIRST IN THIS 'MANTRUN' PROJECT
                
      was (Author: dlmiles):
    This is a patch for inclusion in MANTRUN for the 1.x (1.7/1.8) releases.

This should maintain existing compatibility (because a dead/unrequired extra dependency does not harm usage, even if not the most efficient).

The for Maven 3.x users it will allow this plugin to just work without change.

USE THIS PATCH FIRST IN THIS 'MANTRUN' PROJECT
                  
> maven-antrun-plugin not forward compatible with maven 3.
> --------------------------------------------------------
>
>                 Key: MANTRUN-173
>                 URL: https://jira.codehaus.org/browse/MANTRUN-173
>             Project: Maven 2.x Antrun Plugin
>          Issue Type: Bug
>    Affects Versions: 1.7
>         Environment: Windows 7, Maven 3, Java 1.6
>            Reporter: Peter Sherwood
>            Priority: Critical
>         Attachments: MANTRUN173b-o.a.m.p.mmap.patch, MANTRUN173-o.a.m.p.mmap.patch, mavenerror.txt
>
>
> In some environments we do not have a Nexus style repository and so to make an out of the box build cycle we use antrun to install a jar into a local repository. This works absolutely fine with no exceptions in Maven 2.2.1 in the same environment mentioned above. Moving directly to Maven 3 the build does not work and records the following exception:
> Caused by: java.lang.NoSuchMethodError: org/apache/maven/settings/RuntimeInfo.<init>(Lorg/apache/maven/settings/Settings;)V
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.readSettings(AbstractArtifactTask.java:382)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.loadSettings(AbstractArtifactTask.java:311)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.initSettings(AbstractArtifactTask.java:278)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getSettings(AbstractArtifactTask.java:223)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getDefaultLocalRepository(AbstractArtifactTask.java:212)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getLocalRepository(AbstractArtifactTask.java:700)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.createLocalArtifactRepository(AbstractArtifactTask.java:110)
> 	at org.apache.maven.artifact.ant.Pom.getMavenProject(Pom.java:272)
> 	at org.apache.maven.artifact.ant.Pom.setVersion(Pom.java:570)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
> 	at java.lang.reflect.Method.invoke(Method.java:611)
> 	at org.apache.tools.ant.IntrospectionHelper$AttributeSetter.setObject(IntrospectionHelper.java:1498)
> 	at org.apache.tools.ant.IntrospectionHelper.setAttribute(IntrospectionHelper.java:405)
> 	... 38 more
> My POM is as follows and has been cut down to show the problem only.
> <?xml version="1.0" encoding="UTF-8"?>
> <project xmlns="http://maven.apache.org/POM/4.0.0"
>          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>          xmlns:artifact="antlib:org.apache.maven.artifact.ant">
>     <modelVersion>4.0.0</modelVersion>
>     <groupId>MavenAntTest</groupId>
>     <artifactId>MavenAntTest</artifactId>
>     <version>1.0</version>
>     <build>
>         <plugins>
>             <plugin>
>                 <groupId>org.apache.maven.plugins</groupId>
>                 <artifactId>maven-antrun-plugin</artifactId>
>                 <version>1.7</version>
>                 <executions>
>                     <execution>
>                         <phase>initialize</phase>
>                         <configuration>
>                             <target xmlns:artifact="antlib:org.apache.maven.artifact.ant">
>                                 <path id="maven-ant-tasks.classpath"
>                                       path="${settings.localRepository}${file.separator}org${file.separator}apache${file.separator}maven${file.separator}maven-ant-tasks${file.separator}2.1.3${file.separator}maven-ant-tasks-2.1.3.jar" />
>                                 <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
>                                          uri="antlib:org.apache.maven.artifact.ant" classpathref="maven-ant-tasks.classpath" />
>                                 <taskdef resource="net/sf/antcontrib/antcontrib.properties"
>                                          classpathref="maven.plugin.classpath" />
>                                 <artifact:pom id="saxonInstall" groupId="net.sf.saxon" artifactId="saxon"
>                                               version="9.3.0.5" name="Saxon XSLT Parser">
>                                 </artifact:pom>
>                                 <if>
>                                     <available file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.jar" type="file" />
>                                     <then>
>                                         <echo message="Saxon jar already copied"/>
>                                     </then>
>                                     <else>
>                                         <mkdir dir="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5"/>
>                                         <artifact:writepom pomRefId="saxonInstall" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
>                                         <artifact:pom id="netpom" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
>                                         <artifact:install file="${project.basedir}/src/main/resources/saxon-9.3.0.5.jar" pomRefId="netpom"/>
>                                     </else>
>                                 </if>
>                             </target>
>                         </configuration>
>                         <goals>
>                             <goal>run</goal>
>                         </goals>
>                     </execution>
>                 </executions>
>                 <dependencies>
>                     <dependency>
>                         <groupId>ant-contrib</groupId>
>                         <artifactId>ant-contrib</artifactId>
>                         <version>20020829</version>
>                     </dependency>
>                 </dependencies>
>             </plugin>
>         </plugins>
>     </build>
> </project>
> I attach the full maven output that shows the full problem report.
> I also attach the working maven 2 output.
> Please investigate for me.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] (MANTRUN-173) maven-antrun-plugin not forward compatible with maven 3.

Posted by "Darryl L. Miles (JIRA)" <ji...@codehaus.org>.
    [ https://jira.codehaus.org/browse/MANTRUN-173?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=307740#comment-307740 ] 

Darryl L. Miles commented on MANTRUN-173:
-----------------------------------------

...\m2-repository\org\apache\maven\maven-settings\2.0.11\maven-settings-2.0.11.jar
 org.apache.maven.settings.RuntimeInfo.class
   public RuntimeInfo( Settings settings )

This ctor does exist in that version.  I think the issue for you is that you need to manually add the dependency for org.apache.maven:maven-core:3.x.x (fixup for your version of Maven runtime).  I can only think the classpath container is denying visibility.

As a workaround I think you can manually add this dependency to the pom.xml for the plugin.


The issue is that the module org.apache.maven:maven-project:3.x.x does not exist in Maven3.

Please find enclosed a patch for the pom.xml for the MANTRUN project's pom that allows it to build against Maven 3.


Then find a recommended patch for the current project that will both maintain compatibility with Maven 2 as well as be forward looking to allow the plugin to work on Maven3 (this is in theory).  This adds the reference to maven-core project which is need to provide such things as org.apache.maven.project.* namespace that is used by MANTRUN.

I am not sure what the release policy is for MANTRUN (I did not look it up).
                
> maven-antrun-plugin not forward compatible with maven 3.
> --------------------------------------------------------
>
>                 Key: MANTRUN-173
>                 URL: https://jira.codehaus.org/browse/MANTRUN-173
>             Project: Maven 2.x Antrun Plugin
>          Issue Type: Bug
>    Affects Versions: 1.7
>         Environment: Windows 7, Maven 3, Java 1.6
>            Reporter: Peter Sherwood
>            Priority: Critical
>         Attachments: mavenerror.txt
>
>
> In some environments we do not have a Nexus style repository and so to make an out of the box build cycle we use antrun to install a jar into a local repository. This works absolutely fine with no exceptions in Maven 2.2.1 in the same environment mentioned above. Moving directly to Maven 3 the build does not work and records the following exception:
> Caused by: java.lang.NoSuchMethodError: org/apache/maven/settings/RuntimeInfo.<init>(Lorg/apache/maven/settings/Settings;)V
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.readSettings(AbstractArtifactTask.java:382)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.loadSettings(AbstractArtifactTask.java:311)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.initSettings(AbstractArtifactTask.java:278)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getSettings(AbstractArtifactTask.java:223)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getDefaultLocalRepository(AbstractArtifactTask.java:212)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getLocalRepository(AbstractArtifactTask.java:700)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.createLocalArtifactRepository(AbstractArtifactTask.java:110)
> 	at org.apache.maven.artifact.ant.Pom.getMavenProject(Pom.java:272)
> 	at org.apache.maven.artifact.ant.Pom.setVersion(Pom.java:570)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
> 	at java.lang.reflect.Method.invoke(Method.java:611)
> 	at org.apache.tools.ant.IntrospectionHelper$AttributeSetter.setObject(IntrospectionHelper.java:1498)
> 	at org.apache.tools.ant.IntrospectionHelper.setAttribute(IntrospectionHelper.java:405)
> 	... 38 more
> My POM is as follows and has been cut down to show the problem only.
> <?xml version="1.0" encoding="UTF-8"?>
> <project xmlns="http://maven.apache.org/POM/4.0.0"
>          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>          xmlns:artifact="antlib:org.apache.maven.artifact.ant">
>     <modelVersion>4.0.0</modelVersion>
>     <groupId>MavenAntTest</groupId>
>     <artifactId>MavenAntTest</artifactId>
>     <version>1.0</version>
>     <build>
>         <plugins>
>             <plugin>
>                 <groupId>org.apache.maven.plugins</groupId>
>                 <artifactId>maven-antrun-plugin</artifactId>
>                 <version>1.7</version>
>                 <executions>
>                     <execution>
>                         <phase>initialize</phase>
>                         <configuration>
>                             <target xmlns:artifact="antlib:org.apache.maven.artifact.ant">
>                                 <path id="maven-ant-tasks.classpath"
>                                       path="${settings.localRepository}${file.separator}org${file.separator}apache${file.separator}maven${file.separator}maven-ant-tasks${file.separator}2.1.3${file.separator}maven-ant-tasks-2.1.3.jar" />
>                                 <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
>                                          uri="antlib:org.apache.maven.artifact.ant" classpathref="maven-ant-tasks.classpath" />
>                                 <taskdef resource="net/sf/antcontrib/antcontrib.properties"
>                                          classpathref="maven.plugin.classpath" />
>                                 <artifact:pom id="saxonInstall" groupId="net.sf.saxon" artifactId="saxon"
>                                               version="9.3.0.5" name="Saxon XSLT Parser">
>                                 </artifact:pom>
>                                 <if>
>                                     <available file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.jar" type="file" />
>                                     <then>
>                                         <echo message="Saxon jar already copied"/>
>                                     </then>
>                                     <else>
>                                         <mkdir dir="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5"/>
>                                         <artifact:writepom pomRefId="saxonInstall" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
>                                         <artifact:pom id="netpom" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
>                                         <artifact:install file="${project.basedir}/src/main/resources/saxon-9.3.0.5.jar" pomRefId="netpom"/>
>                                     </else>
>                                 </if>
>                             </target>
>                         </configuration>
>                         <goals>
>                             <goal>run</goal>
>                         </goals>
>                     </execution>
>                 </executions>
>                 <dependencies>
>                     <dependency>
>                         <groupId>ant-contrib</groupId>
>                         <artifactId>ant-contrib</artifactId>
>                         <version>20020829</version>
>                     </dependency>
>                 </dependencies>
>             </plugin>
>         </plugins>
>     </build>
> </project>
> I attach the full maven output that shows the full problem report.
> I also attach the working maven 2 output.
> Please investigate for me.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] (MANTRUN-173) maven-antrun-plugin not forward compatible with maven 3.

Posted by "Darryl L. Miles (JIRA)" <ji...@codehaus.org>.
     [ https://jira.codehaus.org/browse/MANTRUN-173?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Darryl L. Miles updated MANTRUN-173:
------------------------------------

    Attachment: MANTRUN173b-o.a.m.p.mmap.patch

This is a patch for inclusion in MANTRUN for the 1.x (1.7/1.8) releases.

This should maintain existing compatibility (because a dead/unrequired extra dependency does not harm usage, even if not the most efficient).

The for Maven 3.x users it will allow this plugin to just work without change.

USE THIS PATCH FIRST IN THIS 'MANTRUN' PROJECT
                
> maven-antrun-plugin not forward compatible with maven 3.
> --------------------------------------------------------
>
>                 Key: MANTRUN-173
>                 URL: https://jira.codehaus.org/browse/MANTRUN-173
>             Project: Maven 2.x Antrun Plugin
>          Issue Type: Bug
>    Affects Versions: 1.7
>         Environment: Windows 7, Maven 3, Java 1.6
>            Reporter: Peter Sherwood
>            Priority: Critical
>         Attachments: MANTRUN173b-o.a.m.p.mmap.patch, MANTRUN173-o.a.m.p.mmap.patch, mavenerror.txt
>
>
> In some environments we do not have a Nexus style repository and so to make an out of the box build cycle we use antrun to install a jar into a local repository. This works absolutely fine with no exceptions in Maven 2.2.1 in the same environment mentioned above. Moving directly to Maven 3 the build does not work and records the following exception:
> Caused by: java.lang.NoSuchMethodError: org/apache/maven/settings/RuntimeInfo.<init>(Lorg/apache/maven/settings/Settings;)V
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.readSettings(AbstractArtifactTask.java:382)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.loadSettings(AbstractArtifactTask.java:311)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.initSettings(AbstractArtifactTask.java:278)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getSettings(AbstractArtifactTask.java:223)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getDefaultLocalRepository(AbstractArtifactTask.java:212)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getLocalRepository(AbstractArtifactTask.java:700)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.createLocalArtifactRepository(AbstractArtifactTask.java:110)
> 	at org.apache.maven.artifact.ant.Pom.getMavenProject(Pom.java:272)
> 	at org.apache.maven.artifact.ant.Pom.setVersion(Pom.java:570)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
> 	at java.lang.reflect.Method.invoke(Method.java:611)
> 	at org.apache.tools.ant.IntrospectionHelper$AttributeSetter.setObject(IntrospectionHelper.java:1498)
> 	at org.apache.tools.ant.IntrospectionHelper.setAttribute(IntrospectionHelper.java:405)
> 	... 38 more
> My POM is as follows and has been cut down to show the problem only.
> <?xml version="1.0" encoding="UTF-8"?>
> <project xmlns="http://maven.apache.org/POM/4.0.0"
>          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>          xmlns:artifact="antlib:org.apache.maven.artifact.ant">
>     <modelVersion>4.0.0</modelVersion>
>     <groupId>MavenAntTest</groupId>
>     <artifactId>MavenAntTest</artifactId>
>     <version>1.0</version>
>     <build>
>         <plugins>
>             <plugin>
>                 <groupId>org.apache.maven.plugins</groupId>
>                 <artifactId>maven-antrun-plugin</artifactId>
>                 <version>1.7</version>
>                 <executions>
>                     <execution>
>                         <phase>initialize</phase>
>                         <configuration>
>                             <target xmlns:artifact="antlib:org.apache.maven.artifact.ant">
>                                 <path id="maven-ant-tasks.classpath"
>                                       path="${settings.localRepository}${file.separator}org${file.separator}apache${file.separator}maven${file.separator}maven-ant-tasks${file.separator}2.1.3${file.separator}maven-ant-tasks-2.1.3.jar" />
>                                 <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
>                                          uri="antlib:org.apache.maven.artifact.ant" classpathref="maven-ant-tasks.classpath" />
>                                 <taskdef resource="net/sf/antcontrib/antcontrib.properties"
>                                          classpathref="maven.plugin.classpath" />
>                                 <artifact:pom id="saxonInstall" groupId="net.sf.saxon" artifactId="saxon"
>                                               version="9.3.0.5" name="Saxon XSLT Parser">
>                                 </artifact:pom>
>                                 <if>
>                                     <available file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.jar" type="file" />
>                                     <then>
>                                         <echo message="Saxon jar already copied"/>
>                                     </then>
>                                     <else>
>                                         <mkdir dir="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5"/>
>                                         <artifact:writepom pomRefId="saxonInstall" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
>                                         <artifact:pom id="netpom" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
>                                         <artifact:install file="${project.basedir}/src/main/resources/saxon-9.3.0.5.jar" pomRefId="netpom"/>
>                                     </else>
>                                 </if>
>                             </target>
>                         </configuration>
>                         <goals>
>                             <goal>run</goal>
>                         </goals>
>                     </execution>
>                 </executions>
>                 <dependencies>
>                     <dependency>
>                         <groupId>ant-contrib</groupId>
>                         <artifactId>ant-contrib</artifactId>
>                         <version>20020829</version>
>                     </dependency>
>                 </dependencies>
>             </plugin>
>         </plugins>
>     </build>
> </project>
> I attach the full maven output that shows the full problem report.
> I also attach the working maven 2 output.
> Please investigate for me.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] (MANTRUN-173) maven-antrun-plugin not forward compatible with maven 3.

Posted by "Darryl L. Miles (JIRA)" <ji...@codehaus.org>.
     [ https://jira.codehaus.org/browse/MANTRUN-173?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Darryl L. Miles updated MANTRUN-173:
------------------------------------

    Attachment: MANTRUN173-o.a.m.p.mmap.patch

This is a patch showing a port of MANTRUN from Maven 2.x to Maven 3.x seems straight forward.

Maybe this could form a new release of MANTRUN for version 2.x of the plugin (or maybe just skip 2.x and go to 3.x to track the version of Maven).  Whatever.
                
> maven-antrun-plugin not forward compatible with maven 3.
> --------------------------------------------------------
>
>                 Key: MANTRUN-173
>                 URL: https://jira.codehaus.org/browse/MANTRUN-173
>             Project: Maven 2.x Antrun Plugin
>          Issue Type: Bug
>    Affects Versions: 1.7
>         Environment: Windows 7, Maven 3, Java 1.6
>            Reporter: Peter Sherwood
>            Priority: Critical
>         Attachments: MANTRUN173-o.a.m.p.mmap.patch, mavenerror.txt
>
>
> In some environments we do not have a Nexus style repository and so to make an out of the box build cycle we use antrun to install a jar into a local repository. This works absolutely fine with no exceptions in Maven 2.2.1 in the same environment mentioned above. Moving directly to Maven 3 the build does not work and records the following exception:
> Caused by: java.lang.NoSuchMethodError: org/apache/maven/settings/RuntimeInfo.<init>(Lorg/apache/maven/settings/Settings;)V
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.readSettings(AbstractArtifactTask.java:382)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.loadSettings(AbstractArtifactTask.java:311)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.initSettings(AbstractArtifactTask.java:278)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getSettings(AbstractArtifactTask.java:223)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getDefaultLocalRepository(AbstractArtifactTask.java:212)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getLocalRepository(AbstractArtifactTask.java:700)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.createLocalArtifactRepository(AbstractArtifactTask.java:110)
> 	at org.apache.maven.artifact.ant.Pom.getMavenProject(Pom.java:272)
> 	at org.apache.maven.artifact.ant.Pom.setVersion(Pom.java:570)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
> 	at java.lang.reflect.Method.invoke(Method.java:611)
> 	at org.apache.tools.ant.IntrospectionHelper$AttributeSetter.setObject(IntrospectionHelper.java:1498)
> 	at org.apache.tools.ant.IntrospectionHelper.setAttribute(IntrospectionHelper.java:405)
> 	... 38 more
> My POM is as follows and has been cut down to show the problem only.
> <?xml version="1.0" encoding="UTF-8"?>
> <project xmlns="http://maven.apache.org/POM/4.0.0"
>          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>          xmlns:artifact="antlib:org.apache.maven.artifact.ant">
>     <modelVersion>4.0.0</modelVersion>
>     <groupId>MavenAntTest</groupId>
>     <artifactId>MavenAntTest</artifactId>
>     <version>1.0</version>
>     <build>
>         <plugins>
>             <plugin>
>                 <groupId>org.apache.maven.plugins</groupId>
>                 <artifactId>maven-antrun-plugin</artifactId>
>                 <version>1.7</version>
>                 <executions>
>                     <execution>
>                         <phase>initialize</phase>
>                         <configuration>
>                             <target xmlns:artifact="antlib:org.apache.maven.artifact.ant">
>                                 <path id="maven-ant-tasks.classpath"
>                                       path="${settings.localRepository}${file.separator}org${file.separator}apache${file.separator}maven${file.separator}maven-ant-tasks${file.separator}2.1.3${file.separator}maven-ant-tasks-2.1.3.jar" />
>                                 <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
>                                          uri="antlib:org.apache.maven.artifact.ant" classpathref="maven-ant-tasks.classpath" />
>                                 <taskdef resource="net/sf/antcontrib/antcontrib.properties"
>                                          classpathref="maven.plugin.classpath" />
>                                 <artifact:pom id="saxonInstall" groupId="net.sf.saxon" artifactId="saxon"
>                                               version="9.3.0.5" name="Saxon XSLT Parser">
>                                 </artifact:pom>
>                                 <if>
>                                     <available file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.jar" type="file" />
>                                     <then>
>                                         <echo message="Saxon jar already copied"/>
>                                     </then>
>                                     <else>
>                                         <mkdir dir="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5"/>
>                                         <artifact:writepom pomRefId="saxonInstall" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
>                                         <artifact:pom id="netpom" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
>                                         <artifact:install file="${project.basedir}/src/main/resources/saxon-9.3.0.5.jar" pomRefId="netpom"/>
>                                     </else>
>                                 </if>
>                             </target>
>                         </configuration>
>                         <goals>
>                             <goal>run</goal>
>                         </goals>
>                     </execution>
>                 </executions>
>                 <dependencies>
>                     <dependency>
>                         <groupId>ant-contrib</groupId>
>                         <artifactId>ant-contrib</artifactId>
>                         <version>20020829</version>
>                     </dependency>
>                 </dependencies>
>             </plugin>
>         </plugins>
>     </build>
> </project>
> I attach the full maven output that shows the full problem report.
> I also attach the working maven 2 output.
> Please investigate for me.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] (MANTRUN-173) maven-antrun-plugin not forward compatible with maven 3.

Posted by "Robert Scholte (JIRA)" <ji...@codehaus.org>.
     [ https://jira.codehaus.org/browse/MANTRUN-173?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Robert Scholte updated MANTRUN-173:
-----------------------------------

    Description: 
In some environments we do not have a Nexus style repository and so to make an out of the box build cycle we use antrun to install a jar into a local repository. This works absolutely fine with no exceptions in Maven 2.2.1 in the same environment mentioned above. Moving directly to Maven 3 the build does not work and records the following exception:
{noformat}
Caused by: java.lang.NoSuchMethodError: org/apache/maven/settings/RuntimeInfo.<init>(Lorg/apache/maven/settings/Settings;)V
	at org.apache.maven.artifact.ant.AbstractArtifactTask.readSettings(AbstractArtifactTask.java:382)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.loadSettings(AbstractArtifactTask.java:311)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.initSettings(AbstractArtifactTask.java:278)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.getSettings(AbstractArtifactTask.java:223)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.getDefaultLocalRepository(AbstractArtifactTask.java:212)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.getLocalRepository(AbstractArtifactTask.java:700)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.createLocalArtifactRepository(AbstractArtifactTask.java:110)
	at org.apache.maven.artifact.ant.Pom.getMavenProject(Pom.java:272)
	at org.apache.maven.artifact.ant.Pom.setVersion(Pom.java:570)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
	at java.lang.reflect.Method.invoke(Method.java:611)
	at org.apache.tools.ant.IntrospectionHelper$AttributeSetter.setObject(IntrospectionHelper.java:1498)
	at org.apache.tools.ant.IntrospectionHelper.setAttribute(IntrospectionHelper.java:405)
	... 38 more
{noformat}

My POM is as follows and has been cut down to show the problem only.
{code:xml}
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
         xmlns:artifact="antlib:org.apache.maven.artifact.ant">
    <modelVersion>4.0.0</modelVersion>

    <groupId>MavenAntTest</groupId>
    <artifactId>MavenAntTest</artifactId>
    <version>1.0</version>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-antrun-plugin</artifactId>
                <version>1.7</version>
                <executions>
                    <execution>
                        <phase>initialize</phase>
                        <configuration>

                            <target xmlns:artifact="antlib:org.apache.maven.artifact.ant">
                                <path id="maven-ant-tasks.classpath"
                                      path="${settings.localRepository}${file.separator}org${file.separator}apache${file.separator}maven${file.separator}maven-ant-tasks${file.separator}2.1.3${file.separator}maven-ant-tasks-2.1.3.jar" />
                                <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
                                         uri="antlib:org.apache.maven.artifact.ant" classpathref="maven-ant-tasks.classpath" />
                                <taskdef resource="net/sf/antcontrib/antcontrib.properties"
                                         classpathref="maven.plugin.classpath" />
                                <artifact:pom id="saxonInstall" groupId="net.sf.saxon" artifactId="saxon"
                                              version="9.3.0.5" name="Saxon XSLT Parser">
                                </artifact:pom>
                                <if>
                                    <available file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.jar" type="file" />
                                    <then>
                                        <echo message="Saxon jar already copied"/>
                                    </then>
                                    <else>
                                        <mkdir dir="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5"/>
                                        <artifact:writepom pomRefId="saxonInstall" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
                                        <artifact:pom id="netpom" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />

                                        <artifact:install file="${project.basedir}/src/main/resources/saxon-9.3.0.5.jar" pomRefId="netpom"/>
                                    </else>
                                </if>

                            </target>
                        </configuration>
                        <goals>
                            <goal>run</goal>
                        </goals>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>ant-contrib</groupId>
                        <artifactId>ant-contrib</artifactId>
                        <version>20020829</version>
                    </dependency>
                </dependencies>
            </plugin>
        </plugins>
    </build>


</project>
{code}

I attach the full maven output that shows the full problem report.
I also attach the working maven 2 output.
Please investigate for me.

  was:
In some environments we do not have a Nexus style repository and so to make an out of the box build cycle we use antrun to install a jar into a local repository. This works absolutely fine with no exceptions in Maven 2.2.1 in the same environment mentioned above. Moving directly to Maven 3 the build does not work and records the following exception:

Caused by: java.lang.NoSuchMethodError: org/apache/maven/settings/RuntimeInfo.<init>(Lorg/apache/maven/settings/Settings;)V
	at org.apache.maven.artifact.ant.AbstractArtifactTask.readSettings(AbstractArtifactTask.java:382)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.loadSettings(AbstractArtifactTask.java:311)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.initSettings(AbstractArtifactTask.java:278)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.getSettings(AbstractArtifactTask.java:223)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.getDefaultLocalRepository(AbstractArtifactTask.java:212)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.getLocalRepository(AbstractArtifactTask.java:700)
	at org.apache.maven.artifact.ant.AbstractArtifactTask.createLocalArtifactRepository(AbstractArtifactTask.java:110)
	at org.apache.maven.artifact.ant.Pom.getMavenProject(Pom.java:272)
	at org.apache.maven.artifact.ant.Pom.setVersion(Pom.java:570)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
	at java.lang.reflect.Method.invoke(Method.java:611)
	at org.apache.tools.ant.IntrospectionHelper$AttributeSetter.setObject(IntrospectionHelper.java:1498)
	at org.apache.tools.ant.IntrospectionHelper.setAttribute(IntrospectionHelper.java:405)
	... 38 more

My POM is as follows and has been cut down to show the problem only.
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
         xmlns:artifact="antlib:org.apache.maven.artifact.ant">
    <modelVersion>4.0.0</modelVersion>

    <groupId>MavenAntTest</groupId>
    <artifactId>MavenAntTest</artifactId>
    <version>1.0</version>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-antrun-plugin</artifactId>
                <version>1.7</version>
                <executions>
                    <execution>
                        <phase>initialize</phase>
                        <configuration>

                            <target xmlns:artifact="antlib:org.apache.maven.artifact.ant">
                                <path id="maven-ant-tasks.classpath"
                                      path="${settings.localRepository}${file.separator}org${file.separator}apache${file.separator}maven${file.separator}maven-ant-tasks${file.separator}2.1.3${file.separator}maven-ant-tasks-2.1.3.jar" />
                                <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
                                         uri="antlib:org.apache.maven.artifact.ant" classpathref="maven-ant-tasks.classpath" />
                                <taskdef resource="net/sf/antcontrib/antcontrib.properties"
                                         classpathref="maven.plugin.classpath" />
                                <artifact:pom id="saxonInstall" groupId="net.sf.saxon" artifactId="saxon"
                                              version="9.3.0.5" name="Saxon XSLT Parser">
                                </artifact:pom>
                                <if>
                                    <available file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.jar" type="file" />
                                    <then>
                                        <echo message="Saxon jar already copied"/>
                                    </then>
                                    <else>
                                        <mkdir dir="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5"/>
                                        <artifact:writepom pomRefId="saxonInstall" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
                                        <artifact:pom id="netpom" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />

                                        <artifact:install file="${project.basedir}/src/main/resources/saxon-9.3.0.5.jar" pomRefId="netpom"/>
                                    </else>
                                </if>

                            </target>
                        </configuration>
                        <goals>
                            <goal>run</goal>
                        </goals>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>ant-contrib</groupId>
                        <artifactId>ant-contrib</artifactId>
                        <version>20020829</version>
                    </dependency>
                </dependencies>
            </plugin>
        </plugins>
    </build>


</project>

I attach the full maven output that shows the full problem report.
I also attach the working maven 2 output.
Please investigate for me.

    
> maven-antrun-plugin not forward compatible with maven 3.
> --------------------------------------------------------
>
>                 Key: MANTRUN-173
>                 URL: https://jira.codehaus.org/browse/MANTRUN-173
>             Project: Maven 2.x Antrun Plugin
>          Issue Type: Bug
>    Affects Versions: 1.7
>         Environment: Windows 7, Maven 3, Java 1.6
>            Reporter: Peter Sherwood
>            Priority: Critical
>         Attachments: MANTRUN173b-o.a.m.p.mmap.patch, MANTRUN173-o.a.m.p.mmap.patch, mavenerror.txt
>
>
> In some environments we do not have a Nexus style repository and so to make an out of the box build cycle we use antrun to install a jar into a local repository. This works absolutely fine with no exceptions in Maven 2.2.1 in the same environment mentioned above. Moving directly to Maven 3 the build does not work and records the following exception:
> {noformat}
> Caused by: java.lang.NoSuchMethodError: org/apache/maven/settings/RuntimeInfo.<init>(Lorg/apache/maven/settings/Settings;)V
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.readSettings(AbstractArtifactTask.java:382)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.loadSettings(AbstractArtifactTask.java:311)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.initSettings(AbstractArtifactTask.java:278)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getSettings(AbstractArtifactTask.java:223)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getDefaultLocalRepository(AbstractArtifactTask.java:212)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.getLocalRepository(AbstractArtifactTask.java:700)
> 	at org.apache.maven.artifact.ant.AbstractArtifactTask.createLocalArtifactRepository(AbstractArtifactTask.java:110)
> 	at org.apache.maven.artifact.ant.Pom.getMavenProject(Pom.java:272)
> 	at org.apache.maven.artifact.ant.Pom.setVersion(Pom.java:570)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
> 	at java.lang.reflect.Method.invoke(Method.java:611)
> 	at org.apache.tools.ant.IntrospectionHelper$AttributeSetter.setObject(IntrospectionHelper.java:1498)
> 	at org.apache.tools.ant.IntrospectionHelper.setAttribute(IntrospectionHelper.java:405)
> 	... 38 more
> {noformat}
> My POM is as follows and has been cut down to show the problem only.
> {code:xml}
> <?xml version="1.0" encoding="UTF-8"?>
> <project xmlns="http://maven.apache.org/POM/4.0.0"
>          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>          xmlns:artifact="antlib:org.apache.maven.artifact.ant">
>     <modelVersion>4.0.0</modelVersion>
>     <groupId>MavenAntTest</groupId>
>     <artifactId>MavenAntTest</artifactId>
>     <version>1.0</version>
>     <build>
>         <plugins>
>             <plugin>
>                 <groupId>org.apache.maven.plugins</groupId>
>                 <artifactId>maven-antrun-plugin</artifactId>
>                 <version>1.7</version>
>                 <executions>
>                     <execution>
>                         <phase>initialize</phase>
>                         <configuration>
>                             <target xmlns:artifact="antlib:org.apache.maven.artifact.ant">
>                                 <path id="maven-ant-tasks.classpath"
>                                       path="${settings.localRepository}${file.separator}org${file.separator}apache${file.separator}maven${file.separator}maven-ant-tasks${file.separator}2.1.3${file.separator}maven-ant-tasks-2.1.3.jar" />
>                                 <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
>                                          uri="antlib:org.apache.maven.artifact.ant" classpathref="maven-ant-tasks.classpath" />
>                                 <taskdef resource="net/sf/antcontrib/antcontrib.properties"
>                                          classpathref="maven.plugin.classpath" />
>                                 <artifact:pom id="saxonInstall" groupId="net.sf.saxon" artifactId="saxon"
>                                               version="9.3.0.5" name="Saxon XSLT Parser">
>                                 </artifact:pom>
>                                 <if>
>                                     <available file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.jar" type="file" />
>                                     <then>
>                                         <echo message="Saxon jar already copied"/>
>                                     </then>
>                                     <else>
>                                         <mkdir dir="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5"/>
>                                         <artifact:writepom pomRefId="saxonInstall" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
>                                         <artifact:pom id="netpom" file="${settings.localRepository}${file.separator}net${file.separator}sf${file.separator}saxon${file.separator}saxon${file.separator}9.3.0.5${file.separator}saxon-9.3.0.5.pom" />
>                                         <artifact:install file="${project.basedir}/src/main/resources/saxon-9.3.0.5.jar" pomRefId="netpom"/>
>                                     </else>
>                                 </if>
>                             </target>
>                         </configuration>
>                         <goals>
>                             <goal>run</goal>
>                         </goals>
>                     </execution>
>                 </executions>
>                 <dependencies>
>                     <dependency>
>                         <groupId>ant-contrib</groupId>
>                         <artifactId>ant-contrib</artifactId>
>                         <version>20020829</version>
>                     </dependency>
>                 </dependencies>
>             </plugin>
>         </plugins>
>     </build>
> </project>
> {code}
> I attach the full maven output that shows the full problem report.
> I also attach the working maven 2 output.
> Please investigate for me.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira