Stepan Hrbacek created MANTTASKS-238:
----------------------------------------

             Summary: False warnings on invalid POM
                 Key: MANTTASKS-238
                 URL: https://jira.codehaus.org/browse/MANTTASKS-238
             Project: Maven 2.x Ant Tasks
          Issue Type: Bug
          Components: mvn task
    Affects Versions: 2.1.3
         Environment: Windows 7
            Reporter: Stepan Hrbacek
            Priority: Minor


In my pom.xml I have a compile dependency:
                <dependency>
                        <groupId>org.osgi</groupId>
                        <artifactId>org.osgi.core</artifactId>
                        <version>5.0.0</version>
                </dependency>

I then invoke following target in Ant build.xml:
        <target name="compile-source" depends="clean" description="Invokes 
Maven build">
                <artifact:mvn pom="pom.xml" failonerror="true">
                        <arg value="-s"/>
                        <arg value="${product.basedir}/settings.xml"/>
                        <arg value="compile"/>
                        <arg value="package"/>
                        <arg value="install"/>
                </artifact:mvn>
        </target>

The build complains about wrong version of the org.osgi.core POM, but runs 
through:
   [WARNING] POM for 'org.osgi:org.osgi.core:pom:5.0.0:compile' is invalid. It 
will be ignored for artifact resolution.

I have removed the component from local Maven repository and run the build 
again, but the result is the same. I don't know if this is something I should 
worry about... When invoking Maven 3.0.5 from command line, I don't get these 
warnings...

The complete output is:
---
compile-source:
[artifact:mvn] [INFO] Scanning for projects...
[artifact:mvn] [INFO] Reactor build order: 
[artifact:mvn] [INFO]   DirX Access Common Incubator
[artifact:mvn] [INFO]   DirX Access Common
[artifact:mvn] [INFO] 
------------------------------------------------------------------------
[artifact:mvn] [INFO] Building DirX Access Common Incubator
[artifact:mvn] [INFO]    task-segment: [compile, package, install]
[artifact:mvn] [INFO] 
------------------------------------------------------------------------
[artifact:mvn] [INFO] [resources:resources]
[artifact:mvn] [WARNING] Using platform encoding (Cp1252 actually) to copy 
filtered resources, i.e. build is platform dependent!
[artifact:mvn] [INFO] skip non existing resourceDirectory 
C:\Data\Pracovni\Projects\DirX-Access\svn\src\trunk\product\common\dirx.access.incubator.common\src\main\resources
[artifact:mvn] [WARNING] POM for 'org.osgi:org.osgi.core:pom:5.0.0:compile' is 
invalid. It will be ignored for artifact resolution. Reason: Not a v4.0.0 POM. 
for project org.osgi:org.osgi.core at 
C:\Users\cz2b10e4\.m2\repository\org\osgi\org.osgi.core\5.0.0\org.osgi.core-5.0.0.pom
[artifact:mvn] [WARNING] POM for 'org.osgi:org.osgi.core:pom:5.0.0:compile' is 
invalid. It will be ignored for artifact resolution. Reason: Not a v4.0.0 POM. 
for project org.osgi:org.osgi.core at 
C:\Users\cz2b10e4\.m2\repository\org\osgi\org.osgi.core\5.0.0\org.osgi.core-5.0.0.pom
[artifact:mvn] [INFO] [compiler:compile]
[artifact:mvn] [INFO] Compiling 47 source files to 
C:\Data\Pracovni\Projects\DirX-Access\svn\src\trunk\product\common\dirx.access.incubator.common\target\classes
---

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

Reply via email to