Closed rhuss closed 8 years ago
The problem is actually in Maven's core ArtifactUtils
- it doesn't take type into account with it's versionlessKey
which it uses in building a map of artifacts for a project...:
public static String versionlessKey(Artifact artifact) {
return versionlessKey(artifact.getGroupId(), artifact.getArtifactId());
}
Will have to build our own map which does take type into account. Working on it now.
thx, @jimmidyson
sorry would have tried to fix it myself but my panic is growing slowly now when I think to my next week's presentation slides :)
It seems that if two deps are included, one with scope
compile
and one with scopetest
and typetest-jar
(which causes the tests to be deployed, too), then the plugin gets confused and included one of both deps randomly.The issue has been analysed in https://github.com/fabric8io/ipaas-quickstarts/issues/1157 and is probably due to this map lookup which doesn't honor the type.
would be good to add a unit test for this scenario, too (even if this would be the first test).