https://kotlinlang.org logo
#github-workflows-kt
Title
# github-workflows-kt
p

Piotr Krzemiński

02/14/2023, 8:16 AM
@Vampire maybe you'll know as a Windows-man 🙂 I want to make this change to be able to use Gradle 8: https://github.com/krzema12/github-workflows-kt/pull/684 but I'm getting this on Windows:
Copy code
No compatible toolchains found for request specification: {languageVersion=11, vendor=any, implementation=vendor-specific} (auto-detect true, auto-download false).
it seems a bit weird, 11 is still pretty popular - why wouldn't it be available? I'm checking the included software and Java 11 is there 🤔
v

Vampire

02/14/2023, 8:22 AM
Don't insult me. :-( I'm just forced to use Window on my work laptop that I can also use privately. I'm a Linux guy. The toolchain lookup only looks at some defined places. I guess the GHA places are not where it looks (documentation tells where that is). And with Gradle 8 you don't get auto-provisioning anymore if you don't supply a provider like the foojay plugin. You could also instruct Gradle to look into those environment variables or use
setup-java
action before the Gradle run so that it is already running on Java 11.
p

Piotr Krzemiński

02/14/2023, 8:24 AM
sorry for the unintended insult! 😄 oh, I forgot to update the version in setup-java 🤦 https://github.com/krzema12/github-workflows-kt/blob/eaeba522d904c6b9f6b4f5f548b83f738a29636d/.github/workflows/_shared.main.kts#L13 thanks!
v

Vampire

02/14/2023, 8:26 AM
Your should also remove the Zulu there, then it can use a Java installer from the hosted tools cache. I don't think Zulus are in there, but I might be wrong
p

Piotr Krzemiński

02/14/2023, 8:27 AM
removing the vendor won’t hurt, I’m not sure why I specified it there
v

Vampire

02/14/2023, 8:29 AM
Probably for the same reason you had it in the toolchain spec
p

Piotr Krzemiński

02/14/2023, 8:29 AM
yes
for consistency
fun fact: the distribution is required in setup-java 🤷
not a big deal for now, it will take slightly longer to complete the workflow
v

Vampire

02/14/2023, 8:35 AM
Ah, right, had that "Problem" too, as I had to use 11 for the Gradle run now as two plugins I use need it in their latest versions.
19 Views