Error installing 'oraclejdk8': "Expected feature release number in range of 9 to 14, but got: 8"

Hi folks.

I have a build that used to work 0, but is now broken 1. It seems to be related to installing oraclejdk8:

$ ~/bin/install-jdk.sh --target “/home/travis/oraclejdk8” --workspace “/home/travis/.cache/install-jdk” --feature “8” --license “BCL”
install-jdk.sh 2019-05-02
Expected feature release number in range of 9 to 14, but got: 8
The command “~/bin/install-jdk.sh --target “/home/travis/oraclejdk8” --workspace “/home/travis/.cache/install-jdk” --feature “8” --license “BCL”” failed and exited with 3 during .

I haven’t changed the travis.yml since creating this project. Builds have never failed before installing oracle jdk 8, and now they are, yet I haven’t changed anything.

Furthermore, I have many other projects (e.g. 2, 3) that also use oraclejdk8 and build without error.

Can anyone offer insight as to what is going on? For example, why is it the project at 0 the only one to be affected (as far as I can tell)? Why is the build breaking even though I haven’t made changes to the build environment?

Many thanks,
Elliot

6 Likes

Hi,

I can confirm Elliot - I’ve the same issue with one of my many projects.
What is going on and how to solve this issue?

Thx in advance
Marten

1 Like

This is the same as OracleJDK 7 not supported on Precise?

I’m not sure Marten! This is all very confusing. How could Travis break my Java 8 builds without providing some kind of notice or additional information?

It looks like my last successful build (0) was using ‘Build dist: trusty’, and the failing build (1) is using ‘Build dist: xenial’.

As a workaround we used openjdk8 for our builds.

2 Likes

I’ve met the same problem those days, after tens of trials I found that this error is caused by the Ubuntu distribution used by task. For the one you stated as “working”, it’s running on trusty, and the errored one was running on xenial.

TO FIX THIS, add the following code to your .travis.yml file,

dist: trusty

To manually appoint the Ubuntu distribution version.

trusty is trusty for real

2 Likes

See Install-jdk.sh failing for openjdk9 and 10 for context.

thanks!!!

Thanks for this information.

Thanks for all the replies, adding “dist: trusty” fixed my issue.

the question is: why did my build environment change under my feet? Kind of defeats the purpose if your build environment changes underneath of you without you knowing.

I have many many repositories that use Oracle JDK 8, and only a handful have been affected by this issue: as if some of my environments have been migrated to Xenial, while some have not.

3 Likes

Hi everyone, similar error for me here (starting from today, previous builds were working), I tried with both oraclejdk8 and openjdk8:

https://travis-ci.org/pgp/XFiles/builds/575788859

https://travis-ci.org/pgp/XFiles/builds/575851496

It seems to me something has been modified in the install-jdk.sh script…

Imprint