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

Fix conformance test flags are exported to other libraries that use the conformance test suite #2843

Merged
merged 8 commits into from
Apr 17, 2024

Conversation

hanxiaop
Copy link
Contributor

@hanxiaop hanxiaop commented Mar 5, 2024

What type of PR is this?

What this PR does / why we need it:

/kind bug
/area conformance

Which issue(s) this PR fixes:

Fixes #2841.

Currently when implementing GEP-2162, the features need to be imported. However, in the test suite, this import results in the variation of flags within our production code. The goal is to allow the importation of features without modifying the product code.

Does this PR introduce a user-facing change?:


@k8s-ci-robot k8s-ci-robot added kind/bug Categorizes issue or PR as related to a bug. do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. area/conformance cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Mar 5, 2024
@k8s-ci-robot
Copy link
Contributor

Welcome @hanxiaop!

It looks like this is your first PR to kubernetes-sigs/gateway-api 🎉. 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/gateway-api 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 needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Mar 5, 2024
@k8s-ci-robot
Copy link
Contributor

Hi @hanxiaop. Thanks for your PR.

I'm waiting for a kubernetes-sigs 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.

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/test-infra repository.

@hanxiaop hanxiaop marked this pull request as draft March 13, 2024 02:43
@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. do-not-merge/invalid-commit-message Indicates that a PR should not merge because it has an invalid commit message. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. area/gwctl size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Mar 13, 2024
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed do-not-merge/invalid-commit-message Indicates that a PR should not merge because it has an invalid commit message. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Mar 13, 2024
@hanxiaop hanxiaop marked this pull request as ready for review March 13, 2024 03:24
@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 13, 2024
@hanxiaop
Copy link
Contributor Author

Also cc @LiorLieberman to take a look, the feature was introducted in istio/istio#48770.

@LiorLieberman
Copy link
Member

Thanks @hanxiaop!
Can you elaborate on the problem? I am not sure I understand

@hanxiaop
Copy link
Contributor Author

Thanks @hanxiaop! Can you elaborate on the problem? I am not sure I understand

@LiorLieberman So basically, in that PR, you imported the test suite code into the product code:

https://github.com/istio/istio/blob/42572fab5be79af8de284953ec72cbf439631da8/pilot/pkg/config/kube/gateway/supported_features.go#L24,

and after https://github.com/kubernetes-sigs/gateway-api/pull/2801/files#diff-3532d0dde2d46785ab138cfe0fa7bddc5c1901dde4fe4079880451c010ea8254R34, the flag package was also imported into the suite. After that, our command-line tool was filled with gateway conformance test flags alongside our own pflags, since the test flags were imported in the dependency and thus in the flag set. This PR moves the features file out of the suite, so that we can directly import the features instead of the entire suite package and avoid issues like flags being altered.

@k8s-ci-robot k8s-ci-robot removed lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Apr 14, 2024
@hanxiaop
Copy link
Contributor Author

@howardjohn PTAL again, thanks!

Copy link
Contributor

@howardjohn howardjohn left a comment

Choose a reason for hiding this comment

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

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 15, 2024
@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 16, 2024
@hanxiaop
Copy link
Contributor Author

@robscott PTAL, thanks!

@howardjohn
Copy link
Contributor

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 16, 2024
@robscott
Copy link
Member

Thanks @hanxiaop!

/approve

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hanxiaop, howardjohn, robscott

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 added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 16, 2024
@robscott
Copy link
Member

/ok-to-test
/release-note-none

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Apr 16, 2024
@robscott
Copy link
Member

@hanxiaop if you'd prefer we can use #2980 which copied this PR and made some modifications to pass presubmits.

@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 17, 2024
@hanxiaop
Copy link
Contributor Author

@hanxiaop if you'd prefer we can use #2980 which copied this PR and made some modifications to pass presubmits.

@robscott Thanks! I think it should be good now. New tests are continually being added to the folder, so I need to do a rebase again. If it doesn't work I think we can use that PR.

@hanxiaop
Copy link
Contributor Author

@howardjohn just rebased and can you LGTM again? Thanks!

@howardjohn
Copy link
Contributor

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 17, 2024
@k8s-ci-robot k8s-ci-robot merged commit bbbb51b into kubernetes-sigs:main Apr 17, 2024
8 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. area/conformance area/gwctl 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. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. release-note-none Denotes a PR that doesn't merit a release note. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Istioctl has unexpected gateway conformance test pflags after bumping dependency
7 participants