On 29 May 2013, at 10:49, Simone Tripodi wrote:

> Hi all mates,
> 
> I am updating a set of old Maven plugins using Mvn3+Aether APIs, but
> unfortunately I am no longer able to run Mvn tests due to
> org.sonatype.guice.bean.reflect.Logs class cannot be found in the
> classpath, follows below the (almost) complete stacktrace (what is
> missing is just the test class - it is not an OSS project).
> 
> All guice-bean* dependencies are included in the project, included the
> guice-bean-reflect-2.3.0 that contains the missing class.
> 
> Do you know why I get that error?

Maven3 never exposed those packages from the core and the individual 
guice-bean/plexus-* jars were never used in Maven3, only the final 
sisu-inject-bean/plexus aggregate jars.

If you've added your own dependencies to guice-bean/plexus-* jars then this is 
likely the cause of the conflict because they'll be implementing the same API 
as the aggregate jars.

Do you have a link to your test project? If you remove all guice-bean/plexus-* 
dependencies then you'll probably find it works.

In Eclipse/Sisu I've collapsed these interim jars because while they could 
technically be re-used individually it was actually simpler (and smaller) to 
keep them in the same bundle. 

> Any hint would be much more than appreciated!
> Many thanks in advance, all the best!
> -Simo
> 
> java.lang.NoClassDefFoundError: Could not initialize class
> org.sonatype.guice.bean.reflect.Logs
>       at 
> org.sonatype.guice.plexus.scanners.PlexusTypeRegistry.loadRole(PlexusTypeRegistry.java:194)
>       at 
> org.sonatype.guice.plexus.scanners.PlexusTypeRegistry.addComponent(PlexusTypeRegistry.java:110)
>       at 
> org.sonatype.guice.plexus.scanners.PlexusXmlScanner.parseComponent(PlexusXmlScanner.java:329)
>       at 
> org.sonatype.guice.plexus.scanners.PlexusXmlScanner.parseComponentsXml(PlexusXmlScanner.java:198)
>       at 
> org.sonatype.guice.plexus.scanners.PlexusXmlScanner.scan(PlexusXmlScanner.java:94)
>       at 
> org.sonatype.guice.plexus.binders.PlexusXmlBeanModule.configure(PlexusXmlBeanModule.java:89)
>       at 
> org.sonatype.guice.plexus.binders.PlexusBindingModule.configure(PlexusBindingModule.java:62)
>       at 
> com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:229)
>       at com.google.inject.spi.Elements.getElements(Elements.java:103)
>       at com.google.inject.spi.Elements.getElements(Elements.java:80)
>       at 
> org.sonatype.guice.bean.binders.MergedModule.configure(MergedModule.java:54)
>       at 
> com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:229)
>       at com.google.inject.spi.Elements.getElements(Elements.java:103)
>       at 
> com.google.inject.internal.InjectorShell$Builder.build(InjectorShell.java:136)
>       at 
> com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:104)
>       at com.google.inject.Guice.createInjector(Guice.java:94)
>       at com.google.inject.Guice.createInjector(Guice.java:71)
>       at com.google.inject.Guice.createInjector(Guice.java:61)
>       at 
> org.codehaus.plexus.DefaultPlexusContainer.addPlexusInjector(DefaultPlexusContainer.java:470)
>       at 
> org.codehaus.plexus.DefaultPlexusContainer.<init>(DefaultPlexusContainer.java:196)
>       at 
> org.codehaus.plexus.DefaultPlexusContainer.<init>(DefaultPlexusContainer.java:160)
>       at 
> org.apache.maven.plugin.testing.AbstractMojoTestCase.setupContainer(AbstractMojoTestCase.java:159)
>       at 
> org.apache.maven.plugin.testing.AbstractMojoTestCase.getContainer(AbstractMojoTestCase.java:179)
>       at 
> org.apache.maven.plugin.testing.AbstractMojoTestCase.setUp(AbstractMojoTestCase.java:107)
> 
> http://people.apache.org/~simonetripodi/
> http://twitter.com/simonetripodi
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org

Reply via email to