#Unsupported class file major version 65

1 messages · Page 1 of 1 (latest)

glossy swan
#

Hi, i am trying to compile a minecraft plugin and when i tried to setup shading/relocations, maven shade plugin just decided to flag of the class (which is empty btw, it will be used in the future) and i have no idea whats causing it. Ive found a thread, that it could be lombok, but i have no idea.

The error:

org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:3.2.4:shade (shade) on project LenRoot: Error creating shaded jar: Problem shading JAR /*path*/LenRoot/target/LenRoot-0.jar entry eu/lenithia/lenroot/database/DatabaseManager.class: java.lang.IllegalArgumentException: Unsupported class file major version 65

The class:

package eu.lenithia.lenroot.database;

public class DatabaseManager {
    
}
jovial briarBOT
#

<@&987246652869971988> please have a look, thanks.

glossy swan
#

The pom.xml:

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-shade-plugin</artifactId>
        <version>3.2.4</version>
        <executions>
              <execution>
                  <id>shade</id>
                  <phase>package</phase>
                  <goals>
                      <goal>shade</goal>
                  </goals>
              </execution>
        </executions>
        <configuration>
          <filters>
            <filter>
              <artifact>*:*</artifact>
              <excludes>
                <exclude>META-INF/*.MF</exclude>
              </excludes>
            </filter>
          </filters>
          <relocations>
            <relocation>
              <pattern>org.bstats</pattern>
              <shadedPattern>eu.lenithia.libs.bstats</shadedPattern>
           </relocation>
           <relocation>
             <pattern>de.tr7zw.changeme.nbtapi</pattern>
             <shadedPattern>eu.lenithia.libs.nbtapi</shadedPattern>
           </relocation>
           <relocation>
             <pattern>dev.dejvokep.boostedyaml</pattern>
             <shadedPattern>eu.lenithia.libs.boostedyaml</shadedPattern>
           </relocation>
          </relocations>
        </configuration>
      </plugin>
jovial briarBOT
warm pawn
#

Is the Java version of your project supported by your local JDK install?

glossy swan
warm pawn
#

Your maven-shade-plugin is too old it seems

glossy swan
warm pawn
glossy swan
warm pawn
#

I mean it's probably in your best interest to find out what's causing those warnings

glossy swan
glossy swan
#

shouldnt be bad right?

warm pawn
#

yeah those are fine probably