Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

The POM for <name> is invalid, transitive dependencies (if any) will not be available

Tags:

java

maven

This question is outdated and no longer relevant. I have since moved to Gradle for my project build and can no longer verify that answers do or do not work.

I've run into a few issues with Maven. Let me first describe my project setup:

Framework |  -- Apache Commons Math 3.0 |  -- Bouncy Castle 1.5 |  -- etc.. (lots more) |________ |        Client |        | -- GUI libraries |        | -- etc. | |________          Server          | -- Server Libraries          | -- etc. 

So essentially I have a framework that contains most dependancies and then two projects, "Server" and "Client" that contain their own BUT also the framework as a dependancy (being a module of Framework.). I installed the Framework project into my local repository and both my projects can see the Framework-Native code (aka my own logic). HOWEVER they don't seem to be able to use any of the dependancies of the Framework Project. When trying to build either of the "child"-projects I get this:

Invalid POM for de.r2soft.empires.framework:Framework:jar:Alpha-1.2,  transitive dependencies (if any) will not be available,  enable debug logging for more details  

I've tried to find the reason behind this (or better yet a solution) but haven't found anything that fixed my issues. Hope someone here can help. My maven version seems to be 3.2.1 (that's what -version tells me anyways)

Here are my framework-pom.xml and the client-pom.xml on pastebin:

Framework: http://pastebin.com/cceZECaT

Client: http://pastebin.com/1Cuxve5F

Help is appreciated.

like image 383
AreusAstarte Avatar asked May 10 '14 12:05

AreusAstarte


2 Answers

One reason for this is when you rely on a project for which the parent pom is outdated. This often happens if you are updating the parent pom without installing/deploying it.

To see if this is the case, just run with mvn dependency:tree -X and search for the exact error. It will mention it misses things you know are in the parent pom, not in the artifact you depend on (e.g. a jar version).

The fix is pretty simple: install the parent pom using mvn install -N and re-try

like image 92
Omri Spector Avatar answered Oct 03 '22 08:10

Omri Spector


I had a similar error, In my case remove all related artifacts from the local repository was the workaround...

like image 28
LCoelho Avatar answered Oct 03 '22 09:10

LCoelho