Skip to content

Generate native k8s clients#233

Merged
k8s-ci-robot merged 2 commits into
kubernetes-sigs:mainfrom
mastersingh24:client-gen
Mar 5, 2026
Merged

Generate native k8s clients#233
k8s-ci-robot merged 2 commits into
kubernetes-sigs:mainfrom
mastersingh24:client-gen

Conversation

@mastersingh24

@mastersingh24 mastersingh24 commented Jan 4, 2026

Copy link
Copy Markdown
Contributor

Generate native Kubernetes clients for Sandbox and Extensions APIs. This includes configuration and scripts for agents.x-k8s.io and extensions.agents.x-k8s.io.

Changes include:

  • Added dev/hack/update-codegen.sh to invoke client-gen, listers-gen, and informer-gen.
  • Added //go:generate directive to codegen.go for easy regeneration.
  • Configured api/v1alpha1 and extensions/api/v1alpha1 with doc.go and groupversion_info.go helpers (SchemeGroupVersion, Resource).
  • Annotated API types with +genclient.
  • Committed generated client code in clients/k8s.
@netlify

netlify Bot commented Jan 4, 2026

Copy link
Copy Markdown

Deploy Preview for agent-sandbox canceled.

Name Link
🔨 Latest commit f1e1e74
🔍 Latest deploy log https://app.netlify.com/projects/agent-sandbox/deploys/69a95e200fb25f0008ebc2ab
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Jan 4, 2026
@k8s-ci-robot

Copy link
Copy Markdown
Contributor

Welcome @mastersingh24!

It looks like this is your first PR to kubernetes-sigs/agent-sandbox 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes-sigs/agent-sandbox has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Jan 4, 2026
@k8s-ci-robot

Copy link
Copy Markdown
Contributor

Hi @mastersingh24. Thanks for your PR.

I'm waiting for a github.com member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Jan 4, 2026
@mastersingh24

Copy link
Copy Markdown
Contributor Author

Let me know if we should add an example of how to use this or a quick e2e smoke test

@brandonroyal

Copy link
Copy Markdown
Contributor

thx for submitting this @mastersingh24 . Can you provide an example of how you'd use this?

@janetkuo

janetkuo commented Jan 7, 2026

Copy link
Copy Markdown
Member

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jan 7, 2026
@mastersingh24 mastersingh24 force-pushed the client-gen branch 2 times, most recently from bf17028 to 48b5f05 Compare January 7, 2026 23:10
@mastersingh24

Copy link
Copy Markdown
Contributor Author

/retest

@mastersingh24

Copy link
Copy Markdown
Contributor Author

@janetkuo @soltysh anything else needed on this PR?

@mastersingh24

Copy link
Copy Markdown
Contributor Author

@justinsb - could you take a look at this one?

@janetkuo janetkuo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks for the PR! To make this easier to review and keep our history clean, could you please split this into two commits? One for the manual setup (scripts and manual additions) and a second for the generated code.

Comment thread dev/hack/boilerplate.go.txt Outdated
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Feb 22, 2026
@k8s-ci-robot k8s-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Feb 22, 2026
@mastersingh24 mastersingh24 force-pushed the client-gen branch 3 times, most recently from 93c01ff to 118125f Compare February 22, 2026 12:25
@mastersingh24

Copy link
Copy Markdown
Contributor Author

Thanks for the PR! To make this easier to review and keep our history clean, could you please split this into two commits? One for the manual setup (scripts and manual additions) and a second for the generated code.

Done!

@yongruilin yongruilin left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think the commit message needs to be align with the change (boilerplate.go.txt is gone).

Anything else that is blocking from merging this PR? It would be quite useful for other project to do agent-sandbox integration with this change.

@janetkuo janetkuo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks, this looks good.
Just need to fix the year and update commit message as @yongruilin suggested.

/approve

Comment thread api/v1alpha1/doc.go Outdated
@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 5, 2026
Add script to generate native Kubernetes clients for Sandbox and Extensions APIs. This includes configuration and scripts for agents.x-k8s.io and extensions.agents.x-k8s.io.

Changes include:
- Added dev/tools/client-gen-go.sh to invoke client-gen, listers-gen, and informer-gen.
- Added //go:generate directive to codegen.go for easy regeneration.
- Configured api/v1alpha1 and extensions/api/v1alpha1 with doc.go and groupversion_info.go helpers (SchemeGroupVersion, Resource).
- Annotated API types with +genclient.
Generate and add the native Go client

a
@mastersingh24

Copy link
Copy Markdown
Contributor Author

I think the commit message needs to be align with the change (boilerplate.go.txt is gone).

Anything else that is blocking from merging this PR? It would be quite useful for other project to do agent-sandbox integration with this change.

Done! Good find!

@janetkuo janetkuo self-assigned this Mar 5, 2026

@janetkuo janetkuo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

/lgtm

Thanks a lot for the change!

@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
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: janetkuo, mastersingh24

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 1a0aaf2 into kubernetes-sigs:main Mar 5, 2026
10 checks passed
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. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

5 participants