Build Config Running Twice

Hi!

Here’s the link to the travis build: https://travis-ci.org/OpenLiberty/guide-security-intro/builds/640875581

The build was passing for many days, but yesterday the build said it failed, even though the tests in the build passed.

I checked the Build Config section under the View Config tab, and for some reason the Build Config shows a build happening twice now:
https://travis-ci.org/OpenLiberty/guide-security-intro/jobs/640875582/config

Even though for many days before, the Build Config had only one build showing in the config, and looked like:
https://travis-ci.org/OpenLiberty/guide-security-intro/jobs/640416880/config

This has happened to many of our other repos as well.

Thanks!

What am I supposed to be looking at? This build https://travis-ci.org/OpenLiberty/guide-security-intro/builds/640875581 failed because it is trying to invoke ../scripts/travisTest.sh, which doesn’t exist. https://travis-ci.org/OpenLiberty/guide-security-intro/builds/640875581#L428-L430

In the command immediately preceding, you are running cd $logPath. https://travis-ci.org/OpenLiberty/guide-security-intro/builds/640875581#L404 Are you sure you are where you want to be?

cd $logPath is a part of the API payload, so whatever you did to generate this payload is probably to blame.

If you go to the View Config tab and compare the build config for the two travis tests that I sent,
The one which is working fine doesn’t have the red section:

There were no changes made to anything and suddenly that red section started appearing yesterday out of nowhere, which is causing the test cases to fail.

You can see that the first build execution is successful, and then the build ends up in the logs directory. However, because of the second build, which is appearing out of nowhere, it is trying to find the travisTest.sh in that logs directory (which is in a different location) and that’s why it’s failing. But we did not add this second build in the first place.

I understand now. Thanks for the explanation.

this description is misleading; the resulting configuration is concatenating script sections from the API payload and the counterpart in .travis.yml instead of overwriting it.

We’ll take a look.

Hi!

I was wondering if you were able to figure out the cause of this issue?

Thanks!

Sorry for the delay.

This is due to the currently undocumented change in processing the API payloads, which is part of the upcoming build configuration validation. We changed the default way of handling arrays in the API payload when there is existing data in the configuration.

While we wait for the documentation, you can try a couple of things:

  1. Turn off config validation https://travis-ci.org/OpenLiberty/guide-security-intro/settings
  2. change the merge mode https://docs.travis-ci.com/user/triggering-builds#customizing-the-build-configuration to merge.

To take advantage of the configuration validation, I personally recommend the latter.

Please test this, and let us know how you get on.

Thanks.

Hi! Changing merge_mode to merge appears to be working for now, thanks!

1 Like