Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add logic to convert the status of a Build and BuildRun from Beta to Alpha #1499

Conversation

SaschaSchwarze0
Copy link
Member

Changes

When we delivered the Beta API in v0.12, we assumed that we do not require conversion logic for the status of Build and BuildRun from Beta to Alpha, because only the controller would ever set a status - and they run on alpha.

While this was true, you can still erase the status by running a command like this:

$ kubectl patch buildrun <BUILDRUN> --type merge -p '{"metadata":{"annotations":{"test":"value"}}}'

After running this for a completed BuildRun, its status is gone.

This PR takes the conversion logic that was planned to go out in this PR into a separate pull request and adds unit test cases.

Submitter Checklist

  • Includes tests if functionality changed/was added
  • Includes docs if changes are user-facing
  • Set a kind label on this PR
  • Release notes block has been filled in, or marked NONE

See the contributor guide
for details on coding conventions, github and prow interactions, and the code review process.

Release Notes

You can now patch a completed BuildRun on the Beta API without removing its status

@SaschaSchwarze0 SaschaSchwarze0 added the kind/bug Categorizes issue or PR as related to a bug. label Feb 19, 2024
@SaschaSchwarze0 SaschaSchwarze0 added this to the release-v0.13.0 milestone Feb 19, 2024
@pull-request-size pull-request-size bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Feb 19, 2024
@openshift-ci openshift-ci bot added the release-note Label for when a PR has specified a release note label Feb 19, 2024
@SaschaSchwarze0 SaschaSchwarze0 force-pushed the sascha-status-beta-alpha branch from 3a9290d to f318636 Compare February 19, 2024 16:40
Copy link
Contributor

@HeavyWombat HeavyWombat 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

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Feb 19, 2024
Copy link
Contributor

openshift-ci bot commented Feb 19, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: HeavyWombat

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

The pull request process is described here

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

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 19, 2024
@openshift-merge-bot openshift-merge-bot bot merged commit be16c0f into shipwright-io:main Feb 19, 2024
12 checks passed
@SaschaSchwarze0 SaschaSchwarze0 deleted the sascha-status-beta-alpha branch March 1, 2024 15:30
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. kind/bug Categorizes issue or PR as related to a bug. lgtm Indicates that a PR is ready to be merged. release-note Label for when a PR has specified a release note size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants