-
Notifications
You must be signed in to change notification settings - Fork 87
Upgrade to JDK 17 and Gradle 8.14.3 (targeting Java 11 bytecode) #284
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
Conversation
Co-authored-by: keesvandieren <[email protected]>
Co-authored-by: keesvandieren <[email protected]>
|
@copilot why did you use gradle 8.5? 8.14.3 is latest. If 8.14.3 works, please update to that version Please update github actions also to use .java-version file (now still hardcoded to java 11) |
…sion file Co-authored-by: keesvandieren <[email protected]>
Co-authored-by: keesvandieren <[email protected]>
Updated to Gradle 8.14.3 (latest) in commit 02b2714. Also updated all GitHub Actions workflows to use the .java-version file instead of hardcoded Java 11, and modernized the actions to use checkout@v4 and setup-java@v4 in commits 02b2714 and 2ea68f7. Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
|
Can you set targetCompatibility to 11, while using jdk 17 to build @copilot? |
Co-authored-by: keesvandieren <[email protected]>
Changed targetCompatibility to 11 (along with sourceCompatibility to 11) in commit 5e1199f. The project now builds with JDK 17 (from .java-version) but produces Java 11-compatible bytecode (verified as major version 55). Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
Upgrades the project to build with JDK 17 and Gradle 8.14.3 (latest), while maintaining Java 11 bytecode compatibility for the compiled artifacts.
Changes
Gradle: 7.5.1 → 8.14.3
Java compatibility: Build with JDK 17, target Java 11 bytecode
.java-versionfrom 11 to 17 (for building with JDK 17)sourceCompatibilityandtargetCompatibilityto 11 across all modules (for Java 11 bytecode compatibility)Android Gradle Plugin: 7.2.2 → 8.2.0
namespacedeclarations to Android library modules (AGP 8.x requirement)GitHub Actions: Updated workflows to use
.java-versionfileactions/checkoutfrom v2 to v4actions/setup-javafrom v1 to v4 withjava-version-filesupport.java-versioninstead of hardcoded Java 11Notes
Android modules require network access to Google Maven repository. Java modules build and test successfully with the new configuration. The compiled bytecode has been verified as Java 11 compatible (major version 55), ensuring broader runtime compatibility while leveraging JDK 17's build tools.
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.