java.lang.UnsupportedClassVersionError: Bad version number in .class file

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

,
via Google Groups by Marcus Haebler

Update "latest" to Java 8 on DockerHub.

,
Expert tip

This might be caused by and outdated version of Java, SonarQube now uses Java 8 as default. You might upgrade java or use an older version of SonarQube.

Solutions on the web

via Jenkins JIRA by Brian Hicks, 1 year ago
Bad version number in .class file
via Jenkins JIRA by Brian Hicks, 1 year ago
Bad version number in .class file
via Stack Overflow by alex
, 2 years ago
Bad version number in .class file
via gotoanswer.com by Unknown author, 2 years ago
via Stack Overflow by TyC
, 2 years ago
Bad version number in .class file
java.lang.UnsupportedClassVersionError: Bad version number in .class file
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:242)
at hudson.ExtensionFinder$Sezpoz.scout(ExtensionFinder.java:439)
at hudson.ClassicPluginStrategy.findComponents(ClassicPluginStrategy.java:283)
at hudson.ExtensionList.load(ExtensionList.java:258)
at hudson.ExtensionList.ensureLoaded(ExtensionList.java:229)
at hudson.ExtensionList.iterator(ExtensionList.java:136)
at hudson.ClassicPluginStrategy.findComponents(ClassicPluginStrategy.java:282)
at hudson.ExtensionList.load(ExtensionList.java:258)
at hudson.ExtensionList.ensureLoaded(ExtensionList.java:229)
at hudson.ExtensionList.getComponents(ExtensionList.java:147)
at hudson.DescriptorExtensionList.load(DescriptorExtensionList.java:181)
at hudson.ExtensionList.ensureLoaded(ExtensionList.java:229)
at hudson.ExtensionList.iterator(ExtensionList.java:136)
at org.jenkinsci.plugins.xunit.AliasInitializer.addAliases(AliasInitializer.java:23)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at hudson.init.InitializerFinder.invoke(InitializerFinder.java:114)
at hudson.init.InitializerFinder$TaskImpl.run(InitializerFinder.java:178)
at jenkins.model.Jenkins$5.runTask(Jenkins.java:798)
at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:187)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Thread.java:595)

Users with the same issue

Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 2 years ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
340 more bugmates

Know the solutions? Share your knowledge to help other developers to debug faster.