action #165722
closedTrigger and monitor openQA test inside Github action does not work if the latest TW build is tagged as discarded
Description
Motivation¶
Our openQA inside Github integration does not correctly find the latest Tumbleweed published build if the last build is tagged (with anything but published). See https://github.com/os-autoinst/os-autoinst-distri-openQA/actions/runs/10522250013/job/29154508482?pr=200
For the latest published build we use the following
openqa-cli api --host ${OPENQA_HOST:-https://openqa.opensuse.org} job_groups/${OPENQA_GROUP_ID:-1}/build_results limit_builds=1 only_tagged=1 | jq -r '[ .build_results[] | select(.tag.description=="published") | .build ][]'
As of today, the latest build is already tagged, but the tag is discarded. That leads to the former call returning nothing. You can see the unfiltered api result here. The combination of only tagged and limit 1 yields wrong result.
$ openqa-cli api --host https://openqa.opensuse.org job_groups/1/build_results limit_builds=1 only_tagged=1 | jq'
{
"build_results": [
{
"all_passed": 0,
"build": "20240822",
"commented": 0,
"comments": 23,
"distris": {
"microos": 1,
"opensuse": 1
},
"escaped_build": "20240822",
"escaped_id": "Tumbleweed-20240822",
"escaped_version": "Tumbleweed",
"failed": 24,
"key": "Tumbleweed-20240822",
"labeled": 13,
"oldest": "2024-08-23T07:25:24",
"passed": 217,
"reviewed": 0,
"skipped": 7,
"softfailed": 15,
"tag": {
"build": "20240822",
"description": "openssh_issues",
"type": "discarded",
"version": null
},
"total": 343,
"unfinished": 80,
"version": "Tumbleweed",
"version_count": 1
}
],
"children": [],
"group": {
"id": 1,
"name": "openSUSE Tumbleweed"
},
"max_jobs": 343
}
Files
Updated by jbaier_cz about 2 months ago
Maybe something like https://github.com/os-autoinst/os-autoinst-distri-openQA/pull/201 should help in the initial case? We might want to look if there are other places to fix this (maybe other projects, documentation, ...).
Updated by jbaier_cz about 2 months ago
- Related to action #164210: Run a basic openQA test in osado is triggeded blindly even if nothing is published added
Updated by jbaier_cz about 2 months ago
There is already https://github.com/os-autoinst/os-autoinst-distri-opensuse/commit/25990294235f729d866d4a140aa21a8effebcc17 for osado.
Updated by jbaier_cz about 2 months ago
- Status changed from New to Feedback
- Priority changed from High to Low
Looks like distri-openQA was the last repo to not receive the patch, so we are in fact good here and nothing important is blocked.