"Unsupported major.minor version 52.0" after updating to IntelliJ 2017.3
Answered
Hi,
After updating to IntelliJ 2017.3, I'm getting the following error when I try to run a Scala Console :
java.lang.UnsupportedClassVersionError: org/jetbrains/plugins/scala/compiler/rt/ConsoleRunner : Unsupported major.minor version 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:482)
Exception in thread "main"
Process finished with exit code 1
I have no problem running the code or generating the .jar.
My code is compiled in Java 1.7.
Any idea of what may be causing this ?
Please sign in to leave a comment.
This class was compiled with the higher Java version than you are using. Technically, it's a bug that should be reported at https://youtrack.jetbrains.com/issues/SCL so that Scala plug-in is updated with the RT classes compiled using the lowest possible language level.
Thanks, Serge. Added an issue at https://youtrack.jetbrains.com/issues/SCL: https://youtrack.jetbrains.com/issue/SCL-13068