arktekk / sbt-aether-deploy

Deploy SBT artifacts using Maven Artifact Resolver (formerly Eclipse Aether)
Other
84 stars 31 forks source link

missing indirect dependency on "org.codehaus.plexus" % "plexus-utils" #43

Closed NicolasRouquette closed 7 years ago

NicolasRouquette commented 7 years ago

Version 0.18 added an exclusion for "org.codehaus.plexus" % "plexus-utils". Can you explain the rationale for excluding this dependency?

This exclusion causes problems where, for unclear, publishing fails precisely because of a NoClassDefFoundError for a dependency on "org.codehaus.plexus" % "plexus-utils" from Aether.

See for example: https://travis-ci.org/JPL-IMCE/gov.nasa.jpl.imce.oml.resolver/builds/224214709#L453

Service of type interface org.eclipse.aether.impl.ArtifactDescriptorReader failed to be crated by impl type class org.apache.maven.repository.internal.DefaultArtifactDescriptorReader
java.lang.NoClassDefFoundError: org/codehaus/plexus/util/xml/pull/XmlPullParserException
    at org.apache.maven.model.building.DefaultModelBuilderFactory.newModelReader(DefaultModelBuilderFactory.java:94)
    at org.apache.maven.model.building.DefaultModelBuilderFactory.newModelProcessor(DefaultModelBuilderFactory.java:83)
    at org.apache.maven.model.building.DefaultModelBuilderFactory.newInstance(DefaultModelBuilderFactory.java:211)
    at org.apache.maven.repository.internal.DefaultArtifactDescriptorReader.initService(DefaultArtifactDescriptorReader.java:136)
    at org.eclipse.aether.impl.DefaultServiceLocator$Entry.newInstance(DefaultServiceLocator.java:171)
    at org.eclipse.aether.impl.DefaultServiceLocator$Entry.getInstances(DefaultServiceLocator.java:141)
    at org.eclipse.aether.impl.DefaultServiceLocator$Entry.getInstance(DefaultServiceLocator.java:127)
    at org.eclipse.aether.impl.DefaultServiceLocator.getService(DefaultServiceLocator.java:291)
    at org.eclipse.aether.internal.impl.DefaultRepositorySystem.initService(DefaultRepositorySystem.java:143)
    at org.eclipse.aether.impl.DefaultServiceLocator$Entry.newInstance(DefaultServiceLocator.java:171)
    at org.eclipse.aether.impl.DefaultServiceLocator$Entry.getInstances(DefaultServiceLocator.java:141)
    at org.eclipse.aether.impl.DefaultServiceLocator$Entry.getInstance(DefaultServiceLocator.java:127)
    at org.eclipse.aether.impl.DefaultServiceLocator.getService(DefaultServiceLocator.java:291)
    at aether.internal.Booter$.newRepositorySystem(Booter.scala:48)
    at aether.internal.Booter$.apply(Booter.scala:54)
    at aether.AetherPlugin$class.deployIt(Plugin.scala:123)
    at aether.AetherPlugin$.deployIt(Plugin.scala:27)
    at aether.AetherPlugin$$anonfun$deployTask$1.apply(Plugin.scala:74)
    at aether.AetherPlugin$$anonfun$deployTask$1.apply(Plugin.scala:72)
    at scala.Function1$$anonfun$compose$1.apply(Function1.scala:47)
    at sbt.$tilde$greater$$anonfun$$u2219$1.apply(TypeFunctions.scala:40)
    at sbt.std.Transform$$anon$4.work(System.scala:63)
    at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:228)
    at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:228)
    at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:17)
    at sbt.Execute.work(Execute.scala:237)
    at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:228)
    at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:228)
    at sbt.ConcurrentRestrictions$$anon$4$$anonfun$1.apply(ConcurrentRestrictions.scala:159)
    at sbt.CompletionService$$anon$2.call(CompletionService.scala:28)
    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745)

On a related project that uses the same SBT plugin versions as this one, published worked without problems: https://travis-ci.org/JPL-IMCE/gov.nasa.jpl.imce.oml.tables/builds/224211115

The difference between these two projects is that the successful project uses a crossProject configuration (it cross-builds for scala & scala-js) whereas this unsuccessful project uses a plain configuration.

Earlier builds that used version 0.17 worked fine, e.g: https://travis-ci.org/JPL-IMCE/gov.nasa.jpl.imce.oml.resolver/builds/220676138

I'm stumped at this error because a related project that u

hamnis commented 7 years ago

Maven depends on the world, and my tests works fine. Seems odd that this only sometimes happens.

I'll remove the exclusion and republish.

NicolasRouquette commented 7 years ago

Thanks, how soon do you plan to republish?

hamnis commented 7 years ago

https://oss.sonatype.org/content/repositories/noarktekk-1060/ See if this works for you using version 0.18.2 and I'll press the release button.

NicolasRouquette commented 7 years ago

testing....

NicolasRouquette commented 7 years ago

I used your version as instructed:

resolvers += Resolver.sonatypeRepo("noarktekk-1060")
addSbtPlugin("no.arktekk.sbt" % "aether-deploy" % "0.18.2")

publishSigned worked as usal.

Thanks for the quick turnaround!

hamnis commented 7 years ago

Cool. it has been released. Should be in maven central in a few hours.