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

🌱 Validate that unstructued objects don't require scheme registration #3138

Merged
merged 1 commit into from
Mar 8, 2025

Conversation

alvaroaleman
Copy link
Member

If someone is interacting with objects through unstructured, we generally do not expect that to require any sort of registration in the scheme. It look like we never had any tests for this, this change adds them.

If someone is interacting with objects through unstructured, we
generally do not expect that to require any sort of registration in the
scheme. It look like we never had any tests for this, this change adds
them.
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: alvaroaleman

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

@k8s-ci-robot k8s-ci-robot requested review from inteon and JoelSpeed March 3, 2025 20:40
@k8s-ci-robot k8s-ci-robot added 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. labels Mar 3, 2025
@alvaroaleman alvaroaleman requested a review from Copilot March 3, 2025 20:40
@k8s-ci-robot k8s-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Mar 3, 2025

Choose a reason for hiding this comment

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

PR Overview

This PR validates that unstructured objects can be handled without requiring scheme registration, by updating test cases to pass a freshly initialized scheme to client.New.

  • Updated multiple test cases to initialize the client with a new runtime scheme.
  • Added tests covering various subresources such as Scale, ServiceAccount tokens, Pod evictions, Pod bindings, and CSR approvals.

Reviewed Changes

File Description
pkg/client/client_test.go Updated client.New calls to explicitly pass runtime.NewScheme() in tests

Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.

@sbueringer
Copy link
Member

Generally seems fine, can we please hold until after #3136 is merged? Just to avoid rebase on 3136

@sbueringer
Copy link
Member

And wth is copilot doing? :)

@alvaroaleman
Copy link
Member Author

And wth is copilot doing? :)

It is a review functionality you can request by adding it as a reviewer

@alvaroaleman
Copy link
Member Author

Generally seems fine, can we please hold until after #3136 is merged? Just to avoid rebase on 3136

Sounds good, I just wanted proof that this actually works, there is no urgency in merging this

@sbueringer
Copy link
Member

sbueringer commented Mar 4, 2025

And wth is copilot doing? :)

It is a review functionality you can request by adding it as a reviewer

Interesting, nice. How do I do that? Looks like I can't assign copilot via the UI. (probably because I'm not paying? :))

@alvaroaleman
Copy link
Member Author

Interesting, nice. How do I do that? Looks like I can't assign copilot via the UI. (probably because I'm not paying? :))

I cliked on Reviewers and then selected Copilot. Do you not have that option available? I thought it would be enabled or not based on the repo, but maybe its based on the requesting user.

@sbueringer
Copy link
Member

sbueringer commented Mar 4, 2025

Interesting, nice. How do I do that? Looks like I can't assign copilot via the UI. (probably because I'm not paying? :))

I cliked on Reviewers and then selected Copilot. Do you not have that option available? I thought it would be enabled or not based on the repo, but maybe its based on the requesting user.

Copilot is not available there for me

If I click on the current PR on Copilot I get send to a page to signup for Copilot

@sbueringer
Copy link
Member

/lgtm

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

LGTM label has been added.

Git tree hash: bd1aef5244d9a25fe7a65fef06098a8b7424d7e9

@k8s-ci-robot k8s-ci-robot merged commit 4b686fa into kubernetes-sigs:main Mar 8, 2025
11 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. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants