From a4db9381da549c05002170af4b0148ae2fe81373 Mon Sep 17 00:00:00 2001 From: Matthew Staebler Date: Mon, 3 Aug 2026 11:21:42 -0400 Subject: [PATCH] TRT-2821: Preserve original prow job names in PG provider The PG data provider for component readiness was overwriting the ProwJob field on TestJobRunRows with the normalized name (X.X), while the BQ provider correctly preserved the original name. The normalized name is only needed as the map key for cross-release grouping; the ProwJob field is used for display and regression tracking and should retain the literal version number. Co-Authored-By: Claude Opus 4.6 --- .../componentreadiness/dataprovider/postgres/provider.go | 2 +- test/integration/component_readiness_test.go | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/pkg/api/componentreadiness/dataprovider/postgres/provider.go b/pkg/api/componentreadiness/dataprovider/postgres/provider.go index 392b54314..d805aed56 100644 --- a/pkg/api/componentreadiness/dataprovider/postgres/provider.go +++ b/pkg/api/componentreadiness/dataprovider/postgres/provider.go @@ -458,7 +458,7 @@ WHERE pj.release = ? TestKey: key, TestKeyStr: key.Encode(), TestName: row.TestName, - ProwJob: normalizedName, + ProwJob: row.ProwJobName, ProwJobRunID: row.ProwJobRunID, ProwJobURL: row.ProwJobURL, StartTime: row.ProwJobStart, diff --git a/test/integration/component_readiness_test.go b/test/integration/component_readiness_test.go index 46fc1d2bc..a48a1f219 100644 --- a/test/integration/component_readiness_test.go +++ b/test/integration/component_readiness_test.go @@ -2129,6 +2129,13 @@ func TestJobNameNormalizationMergesResults(t *testing.T) { rows, ok := result[normalizedKey] require.True(t, ok, "both job runs should merge under normalized name %q", normalizedKey) assert.Len(t, rows, 2, "both runs should appear under the normalized key") + + prowJobs := sets.New[string]() + for _, r := range rows { + prowJobs.Insert(r.ProwJob) + } + assert.True(t, prowJobs.Has("periodic-ci-4.16-e2e-aws"), "original job name 4.16 should be preserved") + assert.True(t, prowJobs.Has("periodic-ci-4.17-e2e-aws"), "original job name 4.17 should be preserved") } func TestTestExistsInBaseButNotSample(t *testing.T) {