Skip to content

Upgrade toolchain, Paper API 26.2 and Java 25 (2.0.0) - #2

Merged
MrPippi merged 9 commits into
mainfrom
cc/charming-keller-a0vyen
Oct 9, 2026
Merged

MrPippi merged 9 commits into
mainfrom
cc/charming-keller-a0vyen

Conversation

@MrPippi

@MrPippi MrPippi commented Oct 9, 2026 •

Copy link
Copy Markdown
Owner

Summary

This carries out the upgrade plan one step per commit, lowest risk first. Every step was checked locally against the 73 characterization tests from #1.

# Commit Verified
1 Stop tracking target/ (19 build files were committed despite .gitignore) git ls-files target is empty
2 PlaceholderAPI repo repo.extendedclip.com → repo.helpch.at/releases/ (the old host only 301-redirects) build passes
3 GitHub Actions: ./mvnw -B verify, jar uploaded as artifact first run is on this PR
4 Add mvnw / mvnw.cmd, pin Maven 3.9.16; *.cmd gets CRLF via .gitattributes ./mvnw -v reports 3.9.16
5 JUnit 5.10.2 → 5.14.4, Mockito 5.11.0 → 5.24.0 (test scope) 73/73; jar unchanged
6 compiler 3.16.0, enforcer 3.6.3, surefire 3.6.0; one maven.compiler.release property jar listing unchanged, class major 65
7 PlaceholderAPI (compile-only, not shaded) 2.11.6 → 2.11.7 build passes
8 Paper API 1.21.1 → 1.21.11 (Adventure 4.26.1) no deprecation warnings in main code; 73/73
9 Java 25 + Paper API 26.2.build.132-stable (Adventure 5.2.0), api-version: '26.2', version 2.0.0 73/73 on JDK 25, class major 69; enforcer rejects JDK 21

Changes from the plan

  • The test dependencies went before the plugin bump. With surefire 3.6.0, Mockito can no longer self-attach to the forked JVM, so it is now loaded with -javaagent (Mockito's documented setup for Java 21+). Mockito 5.11 cannot run as an agent, so Mockito had to be upgraded first.
  • Step 9 needed no main-code changes.

Breaking changes

  • 2.0.0 does not load on Java 21 or Paper 1.21.x servers. Consider tagging the current main as v1.0.0 for users who stay on 1.21.x.
  • README now recommends PlaceholderAPI 2.12.3+ on Paper 26.2.

Not verified here

  • PlaceholderAPI 2.11.7 resolving from repo.helpch.at. That host is blocked in the environment used to build this, so the CI run on this PR is the first real check.
  • In-game behaviour on a Paper 26.2 server: toggle, overflow, GUI, /ap reload, PAPI, and VeinMiner (which is detected via reflection).
  • The api-version: '26.2' format. Check the server startup log for warnings.

Test plan

  • ./mvnw clean verify on JDK 21 after steps 1–8, and on JDK 25 after step 9: 73 tests, 0 failures
  • CI green on this PR
  • Manual smoke test on a Paper 26.2 server

🤖 Generated with Claude Code

https://claude.ai/code/session_018syaxkhsW9ioZChSmth9Xx


Generated by Claude Code

claude added 9 commits October 9, 2026 01:51
target/ is already listed in .gitignore but 19 build files (including a
stale jar) were committed, so every build dirtied the working tree.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018syaxkhsW9ioZChSmth9Xx
repo.extendedclip.com now only 301-redirects to repo.helpch.at/releases,
so builds behind host allow-lists fail. Same artifacts, new host.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018syaxkhsW9ioZChSmth9Xx
The repo had no CI; the upgrade steps that follow need an automatic gate.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018syaxkhsW9ioZChSmth9Xx
.mvn/wrapper/ existed but mvnw/mvnw.cmd were missing, so the wrapper
could not be used, and the pom (3.9.6) and properties (3.9.12) disagreed
on the Maven version. Regenerated with wrapper:wrapper -Dmaven=3.9.16.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018syaxkhsW9ioZChSmth9Xx
Test scope only; the built jar is unchanged. Newer Mockito ships a
Premain-Class so it can be loaded as a Java agent, which the surefire
upgrade and the later move to Java 25 need. Staying on JUnit 5 for now.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018syaxkhsW9ioZChSmth9Xx
compiler 3.11.0 -> 3.16.0, enforcer 3.4.1 -> 3.6.3, surefire 3.2.5 -> 3.6.0.
Java level now comes from a single maven.compiler.release property
instead of duplicated source/target/release settings.

Under surefire 3.6.0 Mockito can no longer self-attach to the forked
test JVM, so it is loaded as a -javaagent (Mockito's documented setup
for Java 21+), with maven-dependency-plugin:properties resolving its jar.

Built jar contents and class version (65) are unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018syaxkhsW9ioZChSmth9Xx
PAPI is not shaded; servers provide it at runtime. This only changes
the API we compile against.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018syaxkhsW9ioZChSmth9Xx
No main-code changes; compiles with no deprecation warnings and all 73
characterization tests pass. Adventure moves 4.17 -> 4.26.1 with it.

TestRegistryAccess must still implement getRegistry(Class), which is now
deprecated for removal; the warning is suppressed there.

README: note the build API version and the Maven wrapper.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018syaxkhsW9ioZChSmth9Xx
- Paper API 1.21.11 -> 26.2.build.132-stable (Adventure 4.26 -> 5.2)
- Java release 21 -> 25; enforcer now requires [25,26); CI on JDK 25
- plugin.yml api-version '1.21' -> '26.2'
- Version 1.0.0 -> 2.0.0: the jar no longer loads on Java 21 / 1.21.x
  servers, so this is a breaking release (README points 1.21.x users
  at AutoPickup 1.x)

No main-code changes were needed: it compiles against 26.2 with no
deprecation warnings and all 73 characterization tests pass on JDK 25.
README recommends PlaceholderAPI 2.12.3+ on Paper 26.2.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018syaxkhsW9ioZChSmth9Xx
@MrPippi
MrPippi marked this pull request as ready for review October 9, 2026 02:04
@MrPippi
MrPippi merged commit c1bb24d into main Oct 9, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants