Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Java 21 on Jitpack #7746

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

PimvanderLoos
Copy link

Description:

Updated the Java version used by JitPack from 17 to 21. The reason for this is:

  1. This fixes compilation on JitPack. The build fails while trying to compile towny-paper-provider due to class file has wrong version 65.0, should be 61.0. JitPack shows that the status is ok, but it only actually publishes artifacts for towny-folia-provider, towny-base-providers, and towny-parent. Crucially, no artifact for the towny module is published, as you can see in the logs for 0.101.1.1.
  2. This brings it in line with the version used by the Actions workflow to compile the project.

New Nodes/Commands/ConfigOptions:


Relevant Towny Issue ticket:


  • I have tested this pull request for defects on a server.

By making this pull request, I represent that I have the right to waive copyright and related rights to my contribution, and agree that all copyright and related rights in my contributions are waived, and I acknowledge that the TownyAdvanced organization has the copyright to use and modify my contribution under the Towny License for perpetuity.

@LlmDl
Copy link
Member

LlmDl commented Jan 27, 2025

Towny is currently set to use Java 17, in order to make things easier for servers still using MC 1.19.

I'm not sure what the correct move is here, whether to bump is just for jitpack or to leave it be.

@PimvanderLoos
Copy link
Author

Hey, thanks for taking a look at this PR!

You don't need to bump it for JitPack. It just needs a >21 JVM to compile it, as the paper module is compiled against class file 65 (Java 21) and thus needs to be able to read/parse/whatever-it's-called it.

Towny will still target Java 17; the files will be compiled to class file 61 (Java 17). I verified this with the jar compiled by JitPack from my branch: https://jitpack.io/com/github/PimvanderLoos/Towny/towny/master-fe30be79ec-1/towny-master-fe30be79ec-1.jar.
As such, this has no impact on compatibility and can still be used with Java 17 on MC 1.19.

@LlmDl
Copy link
Member

LlmDl commented Jan 27, 2025 via email

@LlmDl LlmDl added this to the 0.101.2.0 milestone Jan 27, 2025
@LlmDl LlmDl added the Label-CI/CD Relating to GitHub Actions or GitHub Packages label Jan 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Label-CI/CD Relating to GitHub Actions or GitHub Packages
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants