latest plexus packages breaks Maven

Bug #417164 reported by Alvin Thompson on 2009-08-21
146
This bug affects 26 people
Affects Status Importance Assigned to Milestone
maven2 (Debian)
Fix Released
Undecided
Unassigned
maven2 (Ubuntu)
Undecided
Unassigned
Nominated for Karmic by allnightlong
plexus-container-default (Ubuntu)
Undecided
Unassigned
Nominated for Karmic by allnightlong

Bug Description

after a recent update, Maven no longer works. running it produces this error:

$ mvn
Exception in thread "main" java.lang.NoClassDefFoundError: org/codehaus/plexus/component/repository/exception/ComponentLifecycleException
 at java.lang.Class.getDeclaredMethods0(Native Method)
 at java.lang.Class.privateGetDeclaredMethods(Class.java:2427)
 at java.lang.Class.privateGetPublicMethods(Class.java:2547)
 at java.lang.Class.getMethods(Class.java:1410)
 at org.codehaus.classworlds.Launcher.getEnhancedMainMethod(Launcher.java:195)
 at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:294)
 at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
 at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
 at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.lang.ClassNotFoundException: org.codehaus.plexus.component.repository.exception.ComponentLifecycleException
 at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
 at java.security.AccessController.doPrivileged(Native Method)
 at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
 at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
 at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
 at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
 at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
 ... 9 more

this may have to do with issue 412839 or issue 414561. completing issue 416312 (upgrade maven to 2.2.1) might be an easy way to fix this...

description: updated
affects: ubuntu → maven2 (Ubuntu)
Onestone (onestone) on 2009-08-23
Changed in maven2 (Ubuntu):
status: New → Confirmed
Onestone (onestone) wrote :

Downgrading libplexus-container-default-java (from 1.0-alpha-9-stable-1-4 to 1.0-alpha-9-stable-1-2) fixed this for me. The previous version can be found here:

http://launchpadlibrarian.net/10709632/libplexus-container-default-java_1.0-alpha-9-stable-1-2_all.deb

affects: maven2 (Ubuntu) → plexus-container-default (Ubuntu)
Onestone (onestone) on 2009-08-24
Changed in maven2 (Ubuntu):
status: New → Confirmed
Martin Garton (martingarton) wrote :

After reading a similar report in Debian ( http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=542550 ) It seems that upgrading to 2.2.x to match the version in Debian testing would fix this.

Also, maven is reportedly very picky about the versions it depend upon, so perhaps it should specify exact versions in future, to prevent this happening again?

Jorge Castro (jorge) on 2009-09-02
Changed in maven2 (Ubuntu):
status: Confirmed → Triaged
Changed in plexus-container-default (Ubuntu):
status: Confirmed → Triaged
Artur Rona (ari-tczew) wrote :

 maven2 (2.2.0-2) unstable; urgency=low

   * Upload to unstable.

 -- Torsten Werner <email address hidden> Fri, 14 Aug 2009 14:59:25 +0200
maven2 (2.2.0-1) experimental; urgency=low

   * New upstream version
   * Added myself to Uploaders.
   * Change section to java, bump Standards-Version to 3.8.1
   * Add a Build-Depends-Indep dependency on maven-repo-helper
   * Move ant to Build-Depends (needed for clean target)
   * Add dependency on java runtimes for the maven2 binary.
   * Change the dependency on java-gcj to default-jdk (Closes: #526295)
   * Update watch and added orig-tar.sh to download the sources,
     get-orig-source in rules now uses uscan
   * Use quilt to manage the patches, add a patch to use the upstream
     build.xml as the build file, disabling all dependency downloading from it
   * Split the package in 2 parts: maven2-core contains all libraries,
     this package contains only the uber jar and the scripts
   * Updated the build to use Maven and its plugins to bootstrap itself,
     based on a patched version of the build.xml boostrap script provided
     with Maven. In particular, it now generates properly the shaded uber-jar,
     this will avoid potential class versionning conflicts for the shared
     libraries used in the plugins.
   * Added Build-Depends-Indep on libmaven-clean-plugin-java,
     libmaven-compiler-plugin-java, libmaven-install-plugin-java,
     libmaven-jar-plugin-java, libmaven-resources-plugin-java,
     libmaven-shade-plugin-java and add a Recommends on those libraries.
   * Remove debian/META-INF as this information is now generated by the build.
   * Improve command line completion.

 -- Ludovic Claude <email address hidden> Mon, 02 Mar 2009 15:04:20 +0000

Changed in maven2 (Debian):
importance: Unknown → Undecided
status: Unknown → New
status: New → Fix Released
Zaki Manian (zmanian) wrote :

Looks like this has been fixed upstream. Any idea when the changes will be migrated to karmic?

Artur Rona (ari-tczew) wrote :

Yep, see bug #427539.

Martin Meyer (elreydetodo) wrote :

At the moment I can't use Maven at all on my Karmic systems. Is there any package I can downgrade to get things working again temporarily? This is kinda important for me...

Zaki Manian (zmanian) wrote :

What I did was

1.add the debian unstable repository to my sources.list :deb ftp://ftp.debian.org/debian unstable main contrib non-free
2. sudo apt-get update

3. Used Synaptic to upgrade just maven2 and its dependencies.

4. Removed debian unstable from repositories

WARNING!
Do not do a global upgrade on the debian unstable repos. You will seriously frag your system and probably have to do a fresh install.

This seems to have given me a function maven.

eitch (eitch) wrote :

I have the same problem (same stacktrace) with the current installation of karmic ony my amd64 system. Installing the deb package as suggested by Onestone solved the issue, yet after an upgrade the package is updated to latest again.

japi (eljapi) wrote :
Changed in maven2 (Ubuntu):
status: Triaged → Invalid

A duplicate of itself? :)

Changed in maven2 (Ubuntu):
status: Invalid → Confirmed

I guess that is a bug in launchpad - having 2 bugs with the same ID...

With the package advised by Onestone, things are better but not quite...

java.lang.ClassNotFoundException: org.codehaus.plexus.interpolation.ValueSource

Yes, the duplicate bug is very strange …

And you're right, the version 1.0-alpha-9-stable-1-2 doesn't work anymore.
Now, I'm a java developper without maven :-( For instance I've moved my working env to a NX server with correct maven environment, but this bug is very annoying for java professionals (Yes, I repeat !).
I hope, we'll find a solution …

Another package must be downgraded. I am using libplexus-interpolation-java_1.7-2_all.deb now (from jaunty). That way, maven still works. But I guess maintainers here should really do something about the degrading quality...

According to bug #427539, they aren't going to fix this for Karmic and will likely just drop the Maven package entirely. I hope they warn people who are considering upgrading...

That's a shame for ubuntu. Many java developers will go to other distros.

Kurt Huwig (k-huwig) wrote :

I tried the solution with adding Debian unstable, but it wanted to add to many packages for me to feel comfortable. If Maven gets removed from Karmic, than we will skip Karmic as we need Maven for our development and I don't want to do the manual install thing.

Kurt Huwig (k-huwig) wrote :

I tried the workaround of using Debian unstable, but this will install a too many additional packages on my system. Right now, I think our company will skip Karmic as we need Maven for all our projects and I don't want to add (and later remove) manual packages.

Kurt Huwig (k-huwig) wrote :

As my already updated system is broken, I installed Maven from the projects homepage. Relevant are these 9 files:

apache-maven-2.2.1/lib/maven-2.2.1-uber.jar
apache-maven-2.2.1/NOTICE.txt
apache-maven-2.2.1/README.txt
apache-maven-2.2.1/LICENSE.txt
apache-maven-2.2.1/bin/mvnDebug
apache-maven-2.2.1/bin/m2.conf
apache-maven-2.2.1/bin/mvn
apache-maven-2.2.1/conf/settings.xml
apache-maven-2.2.1/boot/classworlds-1.1.jar

so IMHO, it should be easy to create a DEB containing these files so that Karmic ships with a working Maven instead of a broken or not at all.

Ludovic Claude (ludovicc) wrote :

For people who have Maven2 broken, please install it from my PPA.
https://launchpad.net/~ludovicc/+ppa-packages

To make a long story short, I did the packaging of Maven 2.2.1 - more than 100 updated packages, put it first in Debian, then I had no time to update Ubuntu.
Sorry for the mess, but if there are more people who can help to package Java software for Debian and Ubuntu (it's easy!), let me know, I will teach you and the next release will shine. There is a Ubuntu Java team (https://launchpad.net/~ubuntu-java) and a Debian Java Packaging team (http://java.debian.net/), please consider joining them.

Ludovic

Id love to learn how to package stuff for Debian. Any Website where i could
learn or some pointers you can give me?

On Tue, Oct 20, 2009 at 12:33 PM, Ludovic Claude <<email address hidden>
> wrote:

> For people who have Maven2 broken, please install it from my PPA.
> https://launchpad.net/~ludovicc/+ppa-packages
>
> To make a long story short, I did the packaging of Maven 2.2.1 - more than
> 100 updated packages, put it first in Debian, then I had no time to update
> Ubuntu.
> Sorry for the mess, but if there are more people who can help to package
> Java software for Debian and Ubuntu (it's easy!), let me know, I will teach
> you and the next release will shine. There is a Ubuntu Java team (
> https://launchpad.net/~ubuntu-java) and a Debian Java Packaging team (
> http://java.debian.net/), please consider joining them.
>
> Ludovic
>
> --
> latest plexus packages breaks Maven
> https://bugs.launchpad.net/bugs/417164
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in “maven2” package in Ubuntu: Confirmed
> Status in “plexus-container-default” package in Ubuntu: Triaged
> Status in “maven2” package in Debian: Fix Released
>
> Bug description:
> after a recent update, Maven no longer works. running it produces this
> error:
>
> $ mvn
> Exception in thread "main" java.lang.NoClassDefFoundError:
> org/codehaus/plexus/component/repository/exception/ComponentLifecycleException
> at java.lang.Class.getDeclaredMethods0(Native Method)
> at java.lang.Class.privateGetDeclaredMethods(Class.java:2427)
> at java.lang.Class.privateGetPublicMethods(Class.java:2547)
> at java.lang.Class.getMethods(Class.java:1410)
> at
> org.codehaus.classworlds.Launcher.getEnhancedMainMethod(Launcher.java:195)
> at
> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:294)
> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> at
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: java.lang.ClassNotFoundException:
> org.codehaus.plexus.component.repository.exception.ComponentLifecycleException
> at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> at
> org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
> at
> org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
> at
> org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
> at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
> ... 9 more
>
> this may have to do with issue 412839 or issue 414561. completing issue
> 416312 (upgrade maven to 2.2.1) might be an easy way to fix this...
>

Oleksiy Lukin (alukin) wrote :

Well, it is quite annoying bug and I honestly surpised that it's urgency marked as low.
Must go back to Fedora because Ubuntu is a nightmare for developer. Developers are not humans I suppose.

hey the bug is fixed *happy* - no nightmare for developers any more ;) :p

Artur Rona (ari-tczew) wrote :

Have you got full tested maven and plexus? Are you sure, that is is working good in 100%?

Is a 100%-garanty possible, that software works good? ;) ... as far as i tested it, it works fine - no errors on missing plexus-librarys.

Artur Rona (ari-tczew) wrote :

See comment #25.

Changed in maven2 (Ubuntu):
status: Confirmed → Fix Released
Changed in plexus-container-default (Ubuntu):
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.