Skip to content

Fix version mismatch between staging and pushing artifacts#4310

Merged
k8s-ci-robot merged 1 commit intokubernetes:masterfrom
saschagrunert:fix-push-version-mismatch
Mar 5, 2026
Merged

Fix version mismatch between staging and pushing artifacts#4310
k8s-ci-robot merged 1 commit intokubernetes:masterfrom
saschagrunert:fix-push-version-mismatch

Conversation

@saschagrunert
Copy link
Member

@saschagrunert saschagrunert commented Mar 5, 2026

What type of PR is this?

/kind bug

What this PR does / why we need it:

  • Fix krel push failing when the version is auto-discovered (no --version flag) and --version-suffix is used
  • findLatestVersion() resolves the version and appends the suffix but never updates bi.opts.Version, causing StageLocalArtifacts() to stage to a path without the version while PushReleaseArtifacts() looks for it with the version

Which issue(s) this PR fixes:

None

Special notes for your reviewer:

This was discovered via kubernetes/perf-tests#3845 which broke the build-and-push-k8s-at-golang-tip job: https://testgrid.k8s.io/sig-scalability-golang#build-and-push-k8s-at-golang-tip

cc @rf232 @kubernetes/release-managers

Does this PR introduce a user-facing change?

Fixed a bug in krel push where auto-discovered versions with a version suffix caused a path mismatch between staging and pushing artifacts.

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. kind/bug Categorizes issue or PR as related to a bug. needs-priority labels Mar 5, 2026
@k8s-ci-robot k8s-ci-robot requested review from jimangel and jrsapi March 5, 2026 15:43
@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. area/release-eng Issues or PRs related to the Release Engineering subproject sig/release Categorizes an issue or PR as relevant to SIG Release. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Mar 5, 2026
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Mar 5, 2026
@saschagrunert saschagrunert force-pushed the fix-push-version-mismatch branch from 362d7f1 to 5dee51b Compare March 5, 2026 15:45
@k8s-ci-robot k8s-ci-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed release-note-none Denotes a PR that doesn't merit a release note. labels Mar 5, 2026
@saschagrunert saschagrunert changed the title Fix version mismatch between staging and pushing artifacts WIP: Fix version mismatch between staging and pushing artifacts Mar 5, 2026
@k8s-ci-robot k8s-ci-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Mar 5, 2026
When the version is auto-discovered (no --version flag),
findLatestVersion() resolves the version and appends the version
suffix, but never updates bi.opts.Version. This causes
StageLocalArtifacts() to use an empty version path while
PushReleaseArtifacts() uses the resolved version, resulting in
a "no such file or directory" error.

Signed-off-by: Sascha Grunert <sgrunert@redhat.com>
@saschagrunert saschagrunert force-pushed the fix-push-version-mismatch branch from 5dee51b to 2180bcc Compare March 5, 2026 15:47
@saschagrunert saschagrunert changed the title WIP: Fix version mismatch between staging and pushing artifacts Fix version mismatch between staging and pushing artifacts Mar 5, 2026
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Mar 5, 2026
@saschagrunert saschagrunert added the priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now. label Mar 5, 2026
Copy link
Member

@xmudrii xmudrii left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Mar 5, 2026
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: saschagrunert, xmudrii

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

The pull request process is described here

Details Needs approval from an approver in each of these files:

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

@k8s-ci-robot k8s-ci-robot merged commit 6418bb4 into kubernetes:master Mar 5, 2026
11 checks passed
@saschagrunert saschagrunert deleted the fix-push-version-mismatch branch March 5, 2026 17:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. area/release-eng Issues or PRs related to the Release Engineering subproject cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/bug Categorizes issue or PR as related to a bug. lgtm "Looks good to me", indicates that a PR is ready to be merged. priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now. release-note Denotes a PR that will be considered when it comes time to generate release notes. sig/release Categorizes an issue or PR as relevant to SIG Release. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants