subhra74 / snowflake

Graphical SFTP client and terminal emulator with helpful utilities
GNU General Public License v3.0
2.16k stars 231 forks source link

Java Runtime Version Error #90

Closed lxwulf closed 4 years ago

lxwulf commented 4 years ago

I got

Exception in thread "main" java.lang.UnsupportedClassVersionError: snowflake/App has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0

but i tried to update no newer version is there i have it already....

C:\Users\LxWulf\Downloads>java -version
java version "1.8.0_241"
Java(TM) SE Runtime Environment (build 1.8.0_241-b07)
Java HotSpot(TM) 64-Bit Server VM (build 25.241-b07, mixed mode)

cant start the java version of snowflake only msi one on windows

subhra74 commented 4 years ago

Are you getting the error while running the jar file only? In that case you need to install Java 11 or higher. What you have is Java 8

You can download Java from: https://www.azul.com/downloads/zulu-community/?&architecture=x86-64-bit&package=jdk#

siucdude commented 4 years ago

I get the same error on Ubuntu 20.04, installed using DEB file.

Error: A JNI error has occurred, please check your installation and try again Exception in thread "main" java.lang.UnsupportedClassVersionError: snowflake/App has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0 at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:763) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:468) at java.net.URLClassLoader.access$100(URLClassLoader.java:74) at java.net.URLClassLoader$1.run(URLClassLoader.java:369) at java.net.URLClassLoader$1.run(URLClassLoader.java:363) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:362) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:495)

user1@Galago-Pro ~ % java -version java version "1.8.0_201" Java(TM) SE Runtime Environment (build 1.8.0_201-b09) Java HotSpot(TM) 64-Bit Server VM (build 25.201-b09, mixed mode)

lxwulf commented 4 years ago

As @subhra74 already said, you need to install java 11 or higher. I have now java 14 installed and everything works. So you need at least this package here:

https://ubuntu.pkgs.org/20.04/ubuntu-main-amd64/openjdk-11-jre_11.0.7+10-3ubuntu1_amd64.deb.html

You can install it with your package manager which is apt afaik. 😊✌