Skip to content

🌱 Simplify codegen usage and stop deleting generated clientsets#2206

Merged
k8s-ci-robot merged 2 commits intokubernetes-sigs:mainfrom
shiftstack:codegen
Oct 29, 2024
Merged

🌱 Simplify codegen usage and stop deleting generated clientsets#2206
k8s-ci-robot merged 2 commits intokubernetes-sigs:mainfrom
shiftstack:codegen

Conversation

@mdbooth
Copy link
Contributor

@mdbooth mdbooth commented Oct 24, 2024

This greatly simplifies the way we execute codegen, removing the hacks required prior to code-generate v0.31.1.

The codegen module is no longer required. codegen is now just 2 files:

  • hack/update-codegen.sh
  • cmd/models-schema/main.go

A side-effect of this change is that we no longer delete the clientset generated by codegen. This makes it easier to use the APIs as a library without the controller-runtime client. This is the source of almost all the added code.

This PR is based on the bump to v1.31.1, so we need to merge that first.

/hold

@k8s-ci-robot k8s-ci-robot added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Oct 24, 2024
@netlify
Copy link

netlify bot commented Oct 24, 2024

Deploy Preview for kubernetes-sigs-cluster-api-openstack ready!

Name Link
🔨 Latest commit d5d98d6
🔍 Latest deploy log https://app.netlify.com/sites/kubernetes-sigs-cluster-api-openstack/deploys/671f9e472ac6a10008bd8eaf
😎 Deploy Preview https://deploy-preview-2206--kubernetes-sigs-cluster-api-openstack.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@mdbooth mdbooth changed the title 🌱 Simplify codegen usage and stop deleting generate clientsets 🌱 Simplify codegen usage and stop deleting generated clientsets Oct 24, 2024
We no longer need a temporary 'core' symlink for generating clients for
a single group.

We no longer need to delete the generated clientsets, as we're now using
the same k8s version in the package as the generator, which is the
intended usage.
This module was a workaround because it required newer k8s deps than the
main module. This is no longer the case, so it's no longer required.
@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 28, 2024
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 28, 2024
@EmilienM
Copy link
Contributor

/approve
/lgtm
/hold cancel

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Oct 29, 2024
@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Oct 29, 2024
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: EmilienM

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 added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 29, 2024
@k8s-ci-robot k8s-ci-robot merged commit 5b66f35 into kubernetes-sigs:main Oct 29, 2024
@mdbooth mdbooth deleted the codegen branch October 29, 2024 19: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. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants