Skip to content

setup-java@v4 doesn't detect versions for graalvm 17 #706

Description

@corneil

Description:

Specifying simple version 17 for GraalVM distribution results in error Error: Could not find GraalVM for SemVer 17

Task version:
v4

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Repro steps:

 steps:
- uses: actions/checkout@v3
- name: 'Configure: Install Java'
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: graalvm

Expected behavior:
The java jdk for latest version of GraalVM should be installed. Just like it does with any other distribution. When specifying distribution liberica the output is:

Run actions/setup-java@v4
with:
java-version: 17
distribution: liberica
java-package: jdk
check-latest: false
server-id: github
server-username: GITHUB_ACTOR
server-password: GITHUB_TOKEN
overwrite-settings: true
job-status: success
token: ***
env:
MAIN_PATH: build-dir
GH_TOKEN: ***
MAVEN_THREADS: false
Installed distributions
Trying to resolve the latest version from remote
Resolved latest version as 17.0.13+1[2](https://github.com/spring-cloud/stream-applications/actions/runs/11798726718/job/32865565910#step:6:2)
Trying to download...
Downloading Java 17.0.1[3](https://github.com/spring-cloud/stream-applications/actions/runs/11798726718/job/32865565910#step:6:3)+12 (Liberica) from https://github.com/bell-sw/Liberica/releases/download/17.0.13+12/bellsoft-jdk17.0.13+12-linux-amd6[4](https://github.com/spring-cloud/stream-applications/actions/runs/11798726718/job/32865565910#step:6:4).tar.gz ...
Extracting Java archive...
/usr/bin/tar xz --warning=no-unknown-keyword --overwrite -C /home/runner/work/_temp/2[5](https://github.com/spring-cloud/stream-applications/actions/runs/11798726718/job/32865565910#step:6:5)44a8ac-5e32-4236-9f0c-8e198e811abb -f /home/runner/work/_temp/ef929019-fb44-4aae-ba5[6](https://github.com/spring-cloud/stream-applications/actions/runs/11798726718/job/32865565910#step:6:6)-35366dbccfaa
Java 1[7](https://github.com/spring-cloud/stream-applications/actions/runs/11798726718/job/32865565910#step:6:7).0.13+12 was downloaded
Setting Java 17.0.13+12 as the default
Creating toolchains.xml for JDK version 17 from liberica
Writing to /home/runner/.m2/toolchains.xml
Java configuration:
Distribution: liberica
Version: 17.0.13+[12](https://github.com/spring-cloud/stream-applications/actions/runs/11798726718/job/32865565910#step:6:12)
Path: /opt/hostedtoolcache/Java_Liberica_jdk/17.0.[13](https://github.com/spring-cloud/stream-applications/actions/runs/11798726718/job/32865565910#step:6:13)-12/x64

When supplying 17.0.12 distribution graalvm does work as expected.
When supplying 21 distribution graalvm does work as expected.

Actual behavior:
Output on console:

Run actions/setup-java@v4
with:
java-version: 17
distribution: graalvm
java-package: jdk
check-latest: false
server-id: github
server-username: GITHUB_ACTOR
server-password: GITHUB_TOKEN
overwrite-settings: true
job-status: success
token: ***
env:
MAIN_PATH: build-dir
GH_TOKEN: ***
MAVEN_THREADS: false
Installed distributions
Trying to resolve the latest version from remote
Error: Could not find GraalVM for SemVer 1[7](https://github.com/spring-cloud/stream-applications/actions/runs/11798787633/job/32865780494#step:6:7)

Extract from log file:

2024-11-12T13:59:19.2107952Z ##[group]Run actions/setup-java@v4
2024-11-12T13:59:19.2108415Z with:
2024-11-12T13:59:19.2108707Z java-version: 17
2024-11-12T13:59:19.2109173Z distribution: graalvm
2024-11-12T13:59:19.2109555Z java-package: jdk
2024-11-12T13:59:19.2109883Z check-latest: false
2024-11-12T13:59:19.2110330Z server-id: github
2024-11-12T13:59:19.2110700Z server-username: GITHUB_ACTOR
2024-11-12T13:59:19.2111086Z server-password: GITHUB_TOKEN
2024-11-12T13:59:19.2111572Z overwrite-settings: true
2024-11-12T13:59:19.2111972Z job-status: success
2024-11-12T13:59:19.2112480Z token: ***
2024-11-12T13:59:19.2112837Z env:
2024-11-12T13:59:19.2113154Z MAIN_PATH: build-dir
2024-11-12T13:59:19.2113644Z GH_TOKEN: ***
2024-11-12T13:59:19.2114022Z MAVEN_THREADS: false
2024-11-12T13:59:19.2114377Z ##[endgroup]
2024-11-12T13:59:19.3886391Z ##[group]Installed distributions
2024-11-12T13:59:19.3909047Z Trying to resolve the latest version from remote
2024-11-12T13:59:19.9738496Z ##[error]Could not find GraalVM for SemVer 17

Metadata

Metadata

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions