Re: Surefire and UnsupportedClassVersionError - more info
Hello Adam, can you try this pom.xml (obviously you'd need to change it for your modules) and btw, can you clear your m2 repository so that jars get downloaded from scratch again? project modelVersion4.0.0/modelVersion groupIdExpenseControl/groupId version1.0/version artifactIdproject/artifactId packagingpom/packaging nameproject/name pluginRepositories pluginRepository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url /pluginRepository /pluginRepositories repositories repository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url /repository /repositories modules moduleejbs/module moduleweb/module moduleear/module !-- modulesite/module-- /modules build pluginManagement plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-site-plugin/artifactId configuration unzipCommand/usr/bin/unzip -o err.txt/unzipCommand /configuration /plugin /plugins /pluginManagement /build dependencyManagement dependencies dependency groupIdgeronimo-spec/groupId artifactIdgeronimo-spec-j2ee/artifactId version1.4-rc4/version scopeprovided/scope /dependency dependency groupIdfop/groupId artifactIdfop/artifactId version0.20.5rc2/version /dependency dependency groupIdaxis/groupId artifactIdaxis-saaj/artifactId version1.3/version /dependency dependency groupIdaxis/groupId artifactIdaxis/artifactId version1.3/version /dependency dependency groupIdExpenseControl/groupId artifactIdejbs/artifactId version1.0/version /dependency /dependencies /dependencyManagement distributionManagement site idsite/id nameproject website/name urlscp://local.company.com/websites/project.company.com//url /site /distributionManagement /project hth marco
RE: Surefire and UnsupportedClassVersionError - more info
Hi Marco, I can't download the surefire plugin any of those repositories (see below). Could you email me the jar and the pom? Reason: Unable to download the artifact from any repository org.apache.maven.plugins:maven-surefire-plugin:pom:2.0-SNAPSHOT from the specified remote repositories: central (http://repo1.maven.org/maven2), apache.snapshots (http://cvs.apache.org/maven-snapshot-repository), apache.snapshots.plugins (http://cvs.apache.org/maven-snapshot-repository) Thanks! Adam -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 24 May 2006 09:24 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError - more info Hello Adam, can you try this pom.xml (obviously you'd need to change it for your modules) and btw, can you clear your m2 repository so that jars get downloaded from scratch again? project modelVersion4.0.0/modelVersion groupIdExpenseControl/groupId version1.0/version artifactIdproject/artifactId packagingpom/packaging nameproject/name pluginRepositories pluginRepository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url /pluginRepository /pluginRepositories repositories repository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url /repository /repositories modules moduleejbs/module moduleweb/module moduleear/module !-- modulesite/module-- /modules build pluginManagement plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-site-plugin/artifactId configuration unzipCommand/usr/bin/unzip -o err.txt/unzipCommand /configuration /plugin /plugins /pluginManagement /build dependencyManagement dependencies dependency groupIdgeronimo-spec/groupId artifactIdgeronimo-spec-j2ee/artifactId version1.4-rc4/version scopeprovided/scope /dependency dependency groupIdfop/groupId artifactIdfop/artifactId version0.20.5rc2/version /dependency dependency groupIdaxis/groupId artifactIdaxis-saaj/artifactId version1.3/version /dependency dependency groupIdaxis/groupId artifactIdaxis/artifactId version1.3/version /dependency dependency groupIdExpenseControl/groupId artifactIdejbs/artifactId version1.0/version /dependency /dependencies /dependencyManagement distributionManagement site idsite/id nameproject website/name urlscp://local.company.com/websites/project.company.com//url /site /distributionManagement /project hth marco - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Surefire and UnsupportedClassVersionError [RESOLVED]
I had an Oracle JRE 1.3 on the PATH which was causing the issue - Sherlock Holmes would have deduced that earlier, since I have the latest JDK but an UnsupportedClassVersionError means I was not using the latest, so there had to be another java on my path. Mea culpa. Thanks for the help, especially Marco. Adam -Original Message- From: Adam Hardy Sent: 24 May 2006 10:52 To: 'Maven Users List' Subject: RE: Surefire-2.2-SNAPSHOT and UnsupportedClassVersionError - more info When I run 'mvn test', I get a stacktrace from the surefire-booter saying UnsupportedClassVersionError as follows. This is a recap of my minimal project which I'm going to use as the base for a bug in jira. [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) at java.lang.ClassLoader.defineClass0(Native Method) at java.lang.ClassLoader.defineClass(Unknown Source) at java.security.SecureClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.access$100(Unknown Source) at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at org.apache.maven.surefire.booter.IsolatedClassLoader.loadClass(IsolatedC lassLoader.java:88) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.locateTestSet s(AbstractDirect... at org.apache.maven.surefire.Surefire.createSuiteFromDefinition(Surefire.ja va:147) at org.apache.maven.surefire.Surefire.run(Surefire.java:108) at java.lang.reflect.Method.invoke(Native Method) at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(Suref ireBooter.java:220) at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java :733) I have JDK1.5.0_06 as my JAVA_HOME and this is the compiler plugin config: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin I started with clean code base, checked for stray .class files, and the local repository is empty. I specified the following for my remote repositories: pluginRepositories pluginRepository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url /pluginRepository /pluginRepositories repositories repository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url /repository /repositories I specified the latest maven-surefire-plugin-2.2-SNAPSHOT plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId version2.2-SNAPSHOT/version /plugin And I can see the maven downloads the snapshots for maven-surefire-plugin-2.2 (version2.2-20060507.223157-4/version) and surefire-2.0. It is using version2.0-20060507.230910-3/version for surefire-booter, surefire-api, surefire-junit and surefire-providers. I have an associate (Marco) for whom this set-up works, so I assume that he has earlier versions of the jars. My next step is to try to run it with those versions, and if that doesn't work, to compile from source. Failing that, and if there is no more help available on the list or as a result of this new jira issue, I may have to contact the developers mentioned in the poms. Thanks Adam - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Surefire and UnsupportedClassVersionError
hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06 and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2 has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories pluginRepositories pluginRepository idMaven Snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2//url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /pluginRepository pluginRepository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /pluginRepository /pluginRepositories modules moduleback-end/module modulegui/module modulestandalone/module /modules build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId version2.2/version /plugin plugin groupIdorg.codehaus.mojo/groupId artifactIdcobertura-maven-plugin/artifactId executions execution goals goalclean/goal goalcheck/goal /goals /execution /executions /plugin /plugins /build reporting plugins plugin groupIdorg.codehaus.mojo/groupId artifactIdtaglist-maven-plugin/artifactId /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-javadoc-plugin/artifactId /plugin plugin groupIdorg.codehaus.mojo/groupId artifactIdjxr-maven-plugin/artifactId /plugin plugin !-- Code rules verification report -- groupIdorg.apache.maven.plugins/groupId artifactIdmaven-pmd-plugin/artifactId configuration targetjdk1.4/targetjdk !-- rulesets ruleset/rulesets/basic.xml/ruleset ruleset/rulesets/controversial.xml/ruleset /rulesets formatxml/format -- linkXreftrue/linkXref sourceEncodingutf-8/sourceEncoding minimumTokens100/minimumTokens /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactId maven-project-info-reports-plugin /artifactId /plugin plugin !-- if uses issue then requires scm setup -- groupIdorg.codehaus.mojo/groupId artifactIdchanges-maven-plugin/artifactId /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-checkstyle-plugin/artifactId /plugin plugin !-- created from the sandbox -- groupIdorg.codehaus.mojo/groupId artifactIdcobertura-maven-plugin/artifactId /plugin plugin !-- Similarity analysis report based upon the Simian tool -- groupIdorg.codehaus.mojo/groupId artifactIdsimian-report-maven-plugin/artifactId version1.0-SNAPSHOT/version
RE: Surefire and UnsupportedClassVersionError
Sorry, but could you help me sort this out first? I obviously have something wrong with my repository declarations. I cannot get mvn to download 2.2-SNAPSHOT. It prefers 2.0. Where is 2.2-SNAPSHOT meant to be online? Or should I download it and install it myself? I tried it with this repository config as well as with none: repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories The pluginRepositories node looks the same. -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 15:22 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06 and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2 has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories pluginRepositories pluginRepository idMaven Snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2//url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /pluginRepository pluginRepository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /pluginRepository /pluginRepositories modules moduleback-end/module modulegui/module modulestandalone/module /modules build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId version2.2/version /plugin plugin groupIdorg.codehaus.mojo/groupId artifactIdcobertura-maven-plugin/artifactId executions execution goals goalclean/goal goalcheck/goal /goals /execution /executions /plugin /plugins /build reporting plugins plugin groupIdorg.codehaus.mojo/groupId artifactIdtaglist-maven-plugin/artifactId /plugin plugin
Re: Surefire and UnsupportedClassVersionError
hello again, try to use this repositories repository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url snapshots enabledtrue/enabled /snapshots /repository /repositories pluginRepositories pluginRepository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url snapshots enabledtrue/enabled /snapshots /pluginRepository /pluginRepositories HTH marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: Sorry, but could you help me sort this out first? I obviously have something wrong with my repository declarations. I cannot get mvn to download 2.2-SNAPSHOT. It prefers 2.0. Where is 2.2-SNAPSHOT meant to be online? Or should I download it and install it myself? I tried it with this repository config as well as with none: repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories The pluginRepositories node looks the same. -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 15:22 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06 and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2 has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories pluginRepositories pluginRepository idMaven Snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2//url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /pluginRepository pluginRepository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /pluginRepository /pluginRepositories modules moduleback-end/module modulegui/module modulestandalone/module /modules build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration
RE: Surefire and UnsupportedClassVersionError
I must be missing something because surefire-booter et al. is 2.0 on http://cvs.apache.org/maven-snapshot-repository I had a root around but couldn't see 2.2. Maybe I'm confusing the issue here. Do I need 'surefire' or 'surefire-plugin'? Thanks Adam -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 16:16 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hello again, try to use this repositories repository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url snapshots enabledtrue/enabled /snapshots /repository /repositories pluginRepositories pluginRepository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url snapshots enabledtrue/enabled /snapshots /pluginRepository /pluginRepositories HTH marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: Sorry, but could you help me sort this out first? I obviously have something wrong with my repository declarations. I cannot get mvn to download 2.2-SNAPSHOT. It prefers 2.0. Where is 2.2-SNAPSHOT meant to be online? Or should I download it and install it myself? I tried it with this repository config as well as with none: repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories The pluginRepositories node looks the same. -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 15:22 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06 and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2 has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories pluginRepositories pluginRepository idMaven Snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2//url snapshots enabledtrue/enabled
Re: Surefire and UnsupportedClassVersionError
surefire plugin.. plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId version2.2-SNAPSHOT/version ... hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I must be missing something because surefire-booter et al. is 2.0 on http://cvs.apache.org/maven-snapshot-repository I had a root around but couldn't see 2.2. Maybe I'm confusing the issue here. Do I need 'surefire' or 'surefire-plugin'? Thanks Adam -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 16:16 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hello again, try to use this repositories repository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url snapshots enabledtrue/enabled /snapshots /repository /repositories pluginRepositories pluginRepository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url snapshots enabledtrue/enabled /snapshots /pluginRepository /pluginRepositories HTH marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: Sorry, but could you help me sort this out first? I obviously have something wrong with my repository declarations. I cannot get mvn to download 2.2-SNAPSHOT. It prefers 2.0. Where is 2.2-SNAPSHOT meant to be online? Or should I download it and install it myself? I tried it with this repository config as well as with none: repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories The pluginRepositories node looks the same. -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 15:22 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06 and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2 has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout
RE: Surefire and UnsupportedClassVersionError
Well, mvn has downloaded surefire-2.0-SNAPSHOT and maven-surefire-plugin-2.2-SNAPSHOT, but I still get the original error. BTW Marco, you say it works for you - are you targeting jdk 1.5? Thanks Adam -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 15:22 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06 and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2 has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories pluginRepositories pluginRepository idMaven Snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2//url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /pluginRepository pluginRepository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /pluginRepository /pluginRepositories modules moduleback-end/module modulegui/module modulestandalone/module /modules build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId version2.2/version /plugin plugin groupIdorg.codehaus.mojo/groupId artifactIdcobertura-maven-plugin/artifactId executions execution goals goalclean/goal goalcheck/goal /goals /execution /executions /plugin /plugins /build reporting plugins plugin groupIdorg.codehaus.mojo/groupId artifactIdtaglist-maven-plugin/artifactId /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-javadoc-plugin/artifactId /plugin plugin groupIdorg.codehaus.mojo/groupId artifactIdjxr-maven-plugin/artifactId /plugin plugin !-- Code rules verification report -- groupIdorg.apache.maven.plugins/groupId artifactIdmaven-pmd-plugin/artifactId configuration targetjdk1.4/targetjdk !-- rulesets ruleset/rulesets/basic.xml/ruleset ruleset/rulesets/controversial.xml/ruleset /rulesets formatxml/format -- linkXreftrue/linkXref sourceEncodingutf-8/sourceEncoding minimumTokens100/minimumTokens /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactId maven-project-info-reports-plugin /artifactId /plugin plugin
Re: Surefire and UnsupportedClassVersionError
yes in my main project. the project that users surefire is a 'child project' of the main project btw, what's your JDK version? i got 1.5.0_06. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: Well, mvn has downloaded surefire-2.0-SNAPSHOT and maven-surefire-plugin-2.2-SNAPSHOT, but I still get the original error. BTW Marco, you say it works for you - are you targeting jdk 1.5? Thanks Adam -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 15:22 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06 and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2 has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories pluginRepositories pluginRepository idMaven Snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2//url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /pluginRepository pluginRepository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /pluginRepository /pluginRepositories modules moduleback-end/module modulegui/module modulestandalone/module /modules build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId version2.2/version /plugin plugin groupIdorg.codehaus.mojo/groupId artifactIdcobertura-maven-plugin/artifactId executions execution goals goalclean/goal goalcheck/goal /goals /execution /executions /plugin /plugins /build reporting plugins plugin groupIdorg.codehaus.mojo/groupId artifactIdtaglist-maven-plugin/artifactId /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-javadoc-plugin/artifactId /plugin plugin groupIdorg.codehaus.mojo/groupId artifactIdjxr-maven-plugin/artifactId /plugin plugin !-- Code rules verification report -- groupIdorg.apache.maven.plugins/groupId artifactIdmaven-pmd-plugin/artifactId configuration targetjdk1.4/targetjdk !-- rulesets ruleset/rulesets/basic.xml/ruleset ruleset/rulesets/controversial.xml/ruleset /rulesets formatxml/format -- linkXreftrue/linkXref sourceEncodingutf-8
Re: Surefire and UnsupportedClassVersionError
If your project is not too big (and not too confidential) could you zip it at my gmail address, i can try it out.. and see if i get same error. rgds marco On 5/23/06, Marco Mistroni [EMAIL PROTECTED] wrote: yes in my main project. the project that users surefire is a 'child project' of the main project btw, what's your JDK version? i got 1.5.0_06. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: Well, mvn has downloaded surefire-2.0-SNAPSHOT and maven-surefire-plugin-2.2-SNAPSHOT, but I still get the original error. BTW Marco, you say it works for you - are you targeting jdk 1.5? Thanks Adam -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 15:22 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06 and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError : com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2 has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi= http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories pluginRepositories pluginRepository idMaven Snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/ /url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /pluginRepository pluginRepository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /pluginRepository /pluginRepositories modules moduleback-end/module modulegui/module modulestandalone/module /modules build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId version2.2/version /plugin plugin groupIdorg.codehaus.mojo/groupId artifactIdcobertura-maven-plugin/artifactId executions execution goals goalclean/goal goalcheck/goal /goals /execution /executions /plugin /plugins /build reporting plugins plugin groupId org.codehaus.mojo/groupId artifactIdtaglist-maven-plugin/artifactId /plugin plugin groupIdorg.apache.maven.plugins /groupId
Re: Surefire and UnsupportedClassVersionError
hi adam, here' smy repository/plugin declaration in my pom.xml.. it's 'shorter' than the one you have... pluginRepositories pluginRepository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url /pluginRepository /pluginRepositories repositories repository idapache.snapshots/id urlhttp://cvs.apache.org/maven-snapshot-repository/url /repository /repositories hth marco On 5/23/06, Marco Mistroni [EMAIL PROTECTED] wrote: If your project is not too big (and not too confidential) could you zip it at my gmail address, i can try it out.. and see if i get same error. rgds marco On 5/23/06, Marco Mistroni [EMAIL PROTECTED] wrote: yes in my main project. the project that users surefire is a 'child project' of the main project btw, what's your JDK version? i got 1.5.0_06. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: Well, mvn has downloaded surefire-2.0-SNAPSHOT and maven-surefire-plugin-2.2-SNAPSHOT, but I still get the original error. BTW Marco, you say it works for you - are you targeting jdk 1.5? Thanks Adam -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 15:22 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError : com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0 xmlns:xsi= http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id url http://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories pluginRepositories pluginRepository idMaven Snapshots/id url http://snapshots.maven.codehaus.org/maven2/ /url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /pluginRepository pluginRepository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2 /url /pluginRepository /pluginRepositories modules moduleback-end/module modulegui/module modulestandalone/module /modules build plugins plugin
RE: Surefire and UnsupportedClassVersionError
Same here. I think it must have something to do with surefire setting up its own classloader - although it seems impossible that it would have problems with the jdk - I only have 1.5 and none other. -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 17:01 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError yes in my main project. the project that users surefire is a 'child project' of the main project btw, what's your JDK version? i got 1.5.0_06. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: Well, mvn has downloaded surefire-2.0-SNAPSHOT and maven-surefire-plugin-2.2-SNAPSHOT, but I still get the original error. BTW Marco, you say it works for you - are you targeting jdk 1.5? Thanks Adam -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 15:22 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06 and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2 has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories pluginRepositories pluginRepository idMaven Snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2//url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /pluginRepository pluginRepository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /pluginRepository /pluginRepositories modules moduleback-end/module modulegui/module modulestandalone/module /modules build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId version2.2/version /plugin plugin groupIdorg.codehaus.mojo/groupId artifactIdcobertura-maven-plugin/artifactId executions execution goals goalclean/goal goalcheck/goal /goals /execution /executions /plugin /plugins /build reporting plugins plugin
RE: Surefire and UnsupportedClassVersionError - more info
I just moved my whole project over to my unix box and the same error occurred, which rules out some environmental factors. -Original Message- From: Adam Hardy [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 17:22 To: Maven Users List Subject: RE: Surefire and UnsupportedClassVersionError Same here. I think it must have something to do with surefire setting up its own classloader - although it seems impossible that it would have problems with the jdk - I only have 1.5 and none other. -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 17:01 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError yes in my main project. the project that users surefire is a 'child project' of the main project btw, what's your JDK version? i got 1.5.0_06. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: Well, mvn has downloaded surefire-2.0-SNAPSHOT and maven-surefire-plugin-2.2-SNAPSHOT, but I still get the original error. BTW Marco, you say it works for you - are you targeting jdk 1.5? Thanks Adam -Original Message- From: Marco Mistroni [mailto:[EMAIL PROTECTED] Sent: 23 May 2006 15:22 To: Maven Users List Subject: Re: Surefire and UnsupportedClassVersionError hi Adam, could you try 2.2-SNAPSHOT for surefire and see if that fixes it? frankly i have no ideaon why is failing, but the 2.2-s is working fine 4 me.. hth marco On 5/23/06, Adam Hardy [EMAIL PROTECTED] wrote: I have just set up Maven 2.0.4 on a new machine with JDK-1.5.0_06 and I am running 'mvn test' on a small pilot project with java 1.5 code. I have source and target = 1.5 in my POM (see below). mvn falls over on surefire with a UnsupportedClassVersionError [INFO] Surefire report directory: C:\Projects\cortex\back-end\target\surefire-reports org.apache.maven.surefire.booter.SurefireExecutionException: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0); nested except is java.lang.UnsupportedClassVersionError: com/cortex/base/domain/card/CardFinderTest (Unsupported major.minor version 49.0) After searching the list archives and googling on this, I still cannot find a solution. There was an announcement on the list 2006-05-14 that surefire 2.2 has been released but specifying version 2.2 in my POM doesn't help and I cannot find it on the repositories. It seems there is only 2.0. Perhaps 2.2 will help but I can't see how to get it. I saw another message on the list http://marc.theaimsgroup.com/?l=turbine-maven-userm=114831704529929w=2 where the exact same problem occurred but the original poster signed off saying they would wipe the surefire directory and see if that helps. However they did not report back. More significantly, I wiped my surefire jars and cleaned the whole project and have source and target specified as 1.5 but to no avail. What could the problem be? Thanks Adam project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdcom.foo.bar/groupId artifactIdfoo/artifactId packagingpom/packaging version1.0-SNAPSHOT/version nameThe whole of foo/name organization named/name urlhttp://www.foo.com/url /organization repositories repository idMaven snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2/url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /repository repository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /repository /repositories pluginRepositories pluginRepository idMaven Snapshots/id urlhttp://snapshots.maven.codehaus.org/maven2//url snapshots enabledtrue/enabled /snapshots releases enabledfalse/enabled /releases /pluginRepository pluginRepository releases enabledtrue/enabled /releases snapshots enabledfalse/enabled /snapshots idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url /pluginRepository /pluginRepositories modules moduleback-end/module modulegui/module modulestandalone/module /modules build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration source1.5/source target1.5/target /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-surefire-plugin/artifactId version2.2/version