Skip to content

chore: upgrade Gradle wrapper to 9.8.2 - #439

Open
katerina20 wants to merge 5 commits into
masterfrom
fix/gradle-9
Open

katerina20 wants to merge 5 commits into
masterfrom
fix/gradle-9

Conversation

@katerina20

@katerina20 katerina20 commented Nov 13, 2026 •

Copy link
Copy Markdown
Collaborator

Replaces Dependabot PR #428, which fails because Gradle 9 needs JDK 17+ to run and drops APIs this build used.

Gradle 9.8.2 now runs on JDK 17. The published library still targets Java 8.

Changes

  • Wrapper: Gradle 7.6.4 → 9.8.2 (Dependabot's commit from chore: bump gradle-wrapper from 7.6.4 to 9.8.2 #428, unchanged).
  • JDK 17 for builds: the Tests, Docs and Dependency Submission workflows use JDK 17, and jitpack.yml pins JitPack to JDK 17. JitPack already used 17, so this only makes it explicit.
  • Java 8 target: the library compiles with options.release = 8, so it's checked against the Java 8 API, not just built as Java 8 bytecode. Javadoc runs with -source 8 so JDK 17's javadoc accepts lombok.var.
  • Gradle 9 API migration: replaced the project-level sourceCompatibility and the old JaCoCo report settings, which Gradle 9 removed.
  • JaCoCo 0.8.5 → 0.8.16. 0.8.5 can't instrument code running on Java 17.
  • Java 8 smoke test: the new java8SmokeTest task runs the built jar on a real Java 8 runtime against a local stub server on 127.0.0.1. It makes a real HTTP request and checks project and error deserialization. CI installs JDK 8 for this step only. It isn't part of build, so local builds don't need a JDK 8.
  • Docs: CONTRIBUTING.md and AGENTS.md now say that building needs JDK 17+ and the bundled ./gradlew, while the published library still runs on Java 8. Both document the smoke test. This also closes an unclosed code block in CONTRIBUTING.md that made the rest of the page render as code.

No production code changed.

Testing

Run on version 1.38.1, Gradle 9.8.2 on JDK 17:

  • ./gradlew clean build, test, jacocoTestReport and javadoc pass, and all 899 tests pass.
  • ./gradlew java8SmokeTest passes on Java 8 (1.8.0_392 locally, 1.8.0_512 in CI). I checked that it catches a regression: with release = 8 removed, a List.of() call compiles fine on JDK 17 but makes the smoke test fail on Java 8 with NoSuchMethodError.
  • Every class in the jar is Java 8 bytecode (class file version 52).
  • JitPack builds this branch with Gradle 9.8.2 and JDK 17. The published .module still declares org.gradle.jvm.version: 8, with the same dependencies as before.

Notes

  • version '1.38.1' uses Groovy syntax that Gradle 10 will remove. It's left as is because .release-it.json matches that exact form when bumping the version.
  • The broken Docs workflow (setup-gradle no longer supports arguments:) was fixed separately in ci: fix Docs workflow and drop duplicate Gradle cache #440, which is already merged.
  • 4 AdvisorsApiTest tests from master fail when the machine's time zone isn't UTC. That's unrelated to this PR, and CI runs in UTC. It will be fixed in a separate PR.

🤖 Generated with Claude Code

@katerina20
katerina20 marked this pull request as draft November 13, 2026 07:14
@katerina20
katerina20 marked this pull request as ready for review November 17, 2026 07:23
dependabot Bot and others added 5 commits November 16, 2026 23:25
Bumps [gradle-wrapper](https://github.com/gradle/gradle) from 7.6.4 to 9.8.2.
- [Release notes](https://github.com/gradle/gradle/releases)
- [Commits](gradle/gradle@v7.6.4...v9.8.2)

---
updated-dependencies:
- dependency-name: gradle-wrapper
  dependency-version: 9.8.2
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Gradle 9 requires JDK 17+ to run and removes several APIs this build used.

- CI, docs, dependency submission and JitPack now run Gradle on JDK 17
- library still compiles with --release 8, so the published jar keeps
  Java 8 bytecode and API
- javadoc runs with -source 8 so lombok.var is accepted on JDK 17
- migrate project-level sourceCompatibility and JaCoCo report settings
  to their Gradle 9 replacements
- bump JaCoCo 0.8.5 -> 0.8.16 (0.8.5 cannot instrument Java 17 runtimes)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Gradle and the unit tests now run on JDK 17, so nothing in CI ran the
library on Java 8 anymore. java8SmokeTest runs the built jar on a Java 8
toolchain against a local stub server: it constructs a Client, performs a
real HTTP round trip, deserializes a polymorphic Project with an enum, and
parses an error response.

It catches Java 9+ API calls or dependencies that only fail at runtime on
Java 8. CI installs JDK 8 next to JDK 17 for this step only; Gradle still
runs on 17. The task is not part of `check`, so local builds do not need a
JDK 8.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
InetAddress.getLoopbackAddress() returns ::1 when IPv6 is preferred,
while the client always connected to 127.0.0.1, so the smoke test failed
with "Connection refused". The server and the client now share one IPv4
literal.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Building needs JDK 17+ and the bundled wrapper, while the published
library still runs on Java 8. Also documents java8SmokeTest and closes
the setup code block, which left the rest of the page rendered as code.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@katerina20
katerina20 marked this pull request as draft November 17, 2026 07:45
@katerina20
katerina20 marked this pull request as ready for review November 17, 2026 08:03

This branch has not been deployed

No deployments
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.

1 participant