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

Fix: The template workflows fail to run due to incorrect Java version #538

Closed
ryan-conway opened this issue Oct 6, 2023 · 1 comment · Fixed by #540
Closed

Fix: The template workflows fail to run due to incorrect Java version #538

ryan-conway opened this issue Oct 6, 2023 · 1 comment · Fixed by #540

Comments

@ryan-conway
Copy link
Collaborator

Issue

After updating to Gradle 8, we need to use Java 17 instead of Java 11. We have updated the workflows inside .github/workflows/ but haven't updated the template workflows in .cicdtemplate/.github/workflows/ 🙈

FAILURE: Build failed with an exception.

4 actionable tasks: 4 executed
* Where:
Build file '/home/runner/work/test-bump-version/test-bump-version/app/build.gradle.kts' line: 3

* What went wrong:
An exception occurred applying plugin request [id: 'com.android.application']
> Failed to apply plugin 'com.android.internal.application'.
   > Android Gradle plugin requires Java 17 to run. You are currently using Java 11.
      Your current JDK is located in /usr/lib/jvm/temurin-11-jdk-amd64
      You can try some of the following options:
       - changing the IDE settings.
       - changing the JAVA_HOME environment variable.
       - changing `org.gradle.java.home` in `gradle.properties`.

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.

* Get more help at https://help.gradle.org/

BUILD FAILED in 1m [50](https://github.com/ryan-conway/test-bump-version/actions/runs/6429079443/job/17457455354#step:5:51)s
Error: Process completed with exit code 1.

Expected

Template workflows should run to completion

Steps to reproduce

  1. Clone the workflows from .cicdtemplate/github/workflows/ to a working Android project repository
  2. Trigger a workflow run
@luongvo
Copy link
Member

luongvo commented Oct 6, 2023

Yes, please upgrade all workflows to use JDK 17 🙏

@ryan-conway ryan-conway added this to the 3.25.0 milestone Oct 6, 2023
@ryan-conway ryan-conway self-assigned this Oct 9, 2023
ryan-conway added a commit that referenced this issue Oct 11, 2023
…ows-fail-to-run-due-to-incorrect-java-version

[#538] Update all workflows to use Java 17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants