ci-tools icon indicating copy to clipboard operation
ci-tools copied to clipboard

[DPTP-4313] Respecting always_run from config file

Open hector-vido opened this issue 11 months ago • 4 comments

The field always_run is auto-generated based in the following condition:

AlwaysRun: opts.runIfChanged == "" && opts.skipIfOnlyChanged == "" && !opts.defaultDisable && opts.pipelineRunIfChanged == "",

But it is only updated if and only if there is no reference to an older configuration, if there is a valid reference, the old value is used and the new one is ignored:

if oldJob, existed := oldJobs[newJobName]; existed {
    mergedJobs = append(mergedJobs, mergePresubmits(&oldJob, &newJob))
} else {
    mergedJobs = append(mergedJobs, newJob)
}

I simply removed the property overriding of AlwaysRun, allowing it to use the logic that already exists and is battle tested.

In addition, some other small changes have been made to improve readability.

This modification can affect a lot of jobs.

hector-vido avatar Mar 18 '25 22:03 hector-vido

/test unit

hector-vido avatar Mar 24 '25 13:03 hector-vido

/hold

Evaluation is needed if the function that assigns old values makes sense

jmguzik avatar Mar 24 '25 20:03 jmguzik

/unhold

hector-vido avatar Apr 14 '25 16:04 hector-vido

/test e2e

hector-vido avatar Apr 25 '25 03:04 hector-vido

/test images

hector-vido avatar Apr 25 '25 03:04 hector-vido

/test e2e

hector-vido avatar Apr 25 '25 12:04 hector-vido

/test e2e

hector-vido avatar Apr 25 '25 13:04 hector-vido

/test e2e

hector-vido avatar Apr 25 '25 16:04 hector-vido

/test e2e

hector-vido avatar Apr 29 '25 17:04 hector-vido

/hold

hector-vido avatar May 07 '25 02:05 hector-vido

/unhold

hector-vido avatar May 07 '25 02:05 hector-vido

/hold

hector-vido avatar May 07 '25 03:05 hector-vido

/override ci/prow/breaking-changes

hector-vido avatar May 07 '25 04:05 hector-vido

@hector-vido: Overrode contexts on behalf of hector-vido: ci/prow/breaking-changes

In response to this:

/override ci/prow/breaking-changes

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

openshift-ci[bot] avatar May 07 '25 04:05 openshift-ci[bot]

/test remaining-required

openshift-ci-robot avatar May 07 '25 10:05 openshift-ci-robot

/unhold

hector-vido avatar May 07 '25 12:05 hector-vido

/hold

jmguzik avatar May 07 '25 13:05 jmguzik

/test e2e

hector-vido avatar Jul 03 '25 19:07 hector-vido

/test e2e

hector-vido avatar Jul 03 '25 19:07 hector-vido

/test e2e

hector-vido avatar Jul 12 '25 04:07 hector-vido

/retest

hector-vido avatar Jul 15 '25 13:07 hector-vido

/test remaining-required

openshift-ci-robot avatar Jul 15 '25 14:07 openshift-ci-robot

/test e2e

hector-vido avatar Jul 15 '25 20:07 hector-vido

/test e2e

hector-vido avatar Jul 15 '25 21:07 hector-vido

/retest

hector-vido avatar Jul 16 '25 15:07 hector-vido

/override ci/prow/breaking-changes

hector-vido avatar Jul 16 '25 16:07 hector-vido

@hector-vido: Overrode contexts on behalf of hector-vido: ci/prow/breaking-changes

In response to this:

/override ci/prow/breaking-changes

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

openshift-ci[bot] avatar Jul 16 '25 16:07 openshift-ci[bot]

/test remaining-required

openshift-ci-robot avatar Jul 17 '25 12:07 openshift-ci-robot

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hector-vido, jmguzik

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • ~~OWNERS~~ [hector-vido,jmguzik]

Approvers can indicate their approval by writing /approve in a comment Approvers can cancel approval by writing /approve cancel in a comment

openshift-ci[bot] avatar Jul 17 '25 12:07 openshift-ci[bot]

/retest-required

Remaining retests: 0 against base HEAD 0fb2c1abc94a5705b494ec0c21b6916dc8374025 and 2 for PR HEAD 3ce85910d9405b5f53ff8d59fe96678ecb40be3b in total

openshift-ci-robot avatar Jul 17 '25 15:07 openshift-ci-robot