From b3b046a58bb3a817aaaa4d354cea95d8273a5174 Mon Sep 17 00:00:00 2001 From: Michal Srb Date: Wed, 27 Nov 2024 16:29:01 +0100 Subject: [PATCH] Fix NVR detection for imported Konflux builds Signed-off-by: Michal Srb --- rpminspect_runner.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/rpminspect_runner.sh b/rpminspect_runner.sh index 91f0c2b..73a0f51 100755 --- a/rpminspect_runner.sh +++ b/rpminspect_runner.sh @@ -91,6 +91,10 @@ get_task_info() { local task_id=$1 task_info=$("$koji_bin" taskinfo -v -r "$task_id") build_nvr=$(basename "$(echo "$task_info" | grep "SRPM: " | head -1 | awk '{ print $2 }' | sed 's|\.src.rpm$||g')") + if [ -z "$build_nvr" ]; then + # Imported Konflux builds don't have SRPM tasks + build_nvr=$(echo "$task_info" | grep "Build: " | head -1 | awk '{ print $2 }') + fi is_scratch="no" is_scratch_output=$(echo "$task_info" | grep "scratch: True") if [ -n "$is_scratch_output" ]; then