#618 New rule type EmptyRule and new result called NoTestsRequired
Closed by vmaljulin. Opened by vmaljulin.
vmaljulin/greenwave RHELWF-2189  into  master

Download 618.patch

This fixes #603
JIRA: RHELWF-2189

@bgoncalv, @vcrhonek, @pingou I had discussion about this patch with @vmaljulin, but I need your opinion.

This patch would fix the issue #603 but packager would require to explicitly mention in their gating.yaml file that specific decision_context doesn't require any tests if they expect Greenwave to pass for it. Otherwise, if the gating.yaml file exists for given build but doesn't contain requested decision_context, Greenwave would still fail. This could help discover some typos in the file.

Does this sound OK? Or would it be better for Greenwave to assume that no tests are required (and pass) if it doesn't find given decision_context in gating.yaml?

@lholecek if I understood correct it seems fine to me :-)

It seems this won't affect existing gating.yaml format, like if decision context is missing it would fail gating, but just add a support to configure a decision context that wouldn't require any test.

This could affect the internal gating bot, as it just checks if gating.yaml exist to assume there are additional gating tests, but this would be an issue on the gating bot and not on greenwave.

@msrb @jkaluza what do you think?

As long as @bgoncalv agrees and there's no reaction from others, I think we can merge it. @lholecek @gnaponie what do you think?

Why not use rules: [] instead?

@bgoncalv, @vcrhonek, @pingou I had discussion about this patch with @vmaljulin, but I need your opinion.

This patch would fix the issue #603 but packager would require to explicitly mention in their gating.yaml file that specific decision_context doesn't require any tests if they expect Greenwave to pass for it. Otherwise, if the gating.yaml file exists for given build but doesn't contain requested decision_context, Greenwave would still fail. This could help discover some typos in the file.

Does this sound OK? Or would it be better for Greenwave to assume that no tests are required (and pass) if it doesn't find given decision_context in gating.yaml?

IIUC: pass if no decision_context is found is the current behavior, right?
If so, if we want to change this, we will need to communicate this loud and
clear (likely communityblog + emails to the devel-announce list on the Fedora
side and other lists internally).

My wonder is: is the gain worth the pain?
If the idea is to find out gating.yaml are valid or not, could we provide a
CLI tool that packagers can run on their machine or that we can automatically
run on a regular basis (say daily) and report the output to the maintainers?

Why not use rules: [] instead?

I've checked if this would work and found that it works as expected i.e. if there is a remote rule with the matching decision_context and rules: [] it returns no tests are required. I've created tests for such configuration in PR#621.

Pull-Request has been closed by vmaljulin

Metadata