MaxiHuHe04/iTunes-Backup-Explorer

Java Exception

Closed this issue · 4 comments

`java -jar "C:\Users\Ryzen\Downloads\itunes-backup-explorer-1.4.jar"

Exception in thread "main" java.lang.UnsupportedClassVersionError: me/maxih/itunes_backup_explorer/ITunesBackupExplorerLauncher 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(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.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 sun.launcher.LauncherHelper.checkAndLoadMain(Unknown Source)

Already installed Java JDK latest and set java environment.

Hey @youbrey,
iTunes Backup Explorer needs Java 11 at least. It seems that you tried to start it with Java 8.
If you already installed a newer version, make sure that only the right one is in the PATH environment variable or uninstall Java 8.
You can confirm this by typing in java -version.

i have JDK 20 installed but still got error.

Untitled

Just wanted to say thank you for this software. It's insane that apple makes it so difficult to have access to data that is paid for. Fuck corporations, long live open source.
I had the same error, and it was java 8 like you said.
The thing is, when you search to install java, it defaults to 8 because it's the recommended.

this is where I found the latest versions of java : https://www.oracle.com/java/technologies/downloads/
it's working for me w j20.
Thank you again for this amazing app.

@youbrey Java 8 was probably still selected as the program to open the jar file with. Try to type in the command java -jar "C:\Users\Ryzen\Downloads\itunes-backup-explorer-1.4.jar" again like you did last time.
If that works, change the associated program for .jar files:

  • Right-click on itunes-backup-explorer-1.4.jar
  • "Properties"
  • "Change" besides Open with
  • "More Apps", then scroll down
  • "Look for another app on the PC"
  • Now, navigate to the installation directory of JDK 20 -> bin and choose javaw.exe
    Finally, you should be able to open the program by double-clicking it.

@LuckDragon666 I'm glad I could help. And yes, the situation with Java is a bit unfortunate. There is already a note in the README, but I will change the link to Adoptium that the page doesn't recommend Java 8 anymore.