Skip to content

Conversation

aman4433
Copy link
Contributor

What type of PR is this?

What this PR does / why we need it:

This PR enhances the generate-flags.sh script to handle flags with multi-line descriptions, specifically to address the case of --feature-gates.

Previously, such flags were either incorrectly parsed or excluded from the generated flags.md documentation due to their multi-line nature. This led to incomplete CLI documentation, which can cause confusion for users, especially when dealing with important features like in-place updates that are behind feature gates.

With this update the script now properly captures and formats multi-line flag descriptions.

This ensures that all flags—including complex ones like --feature-gates—are accurately represented in the VPA component documentation.

Which issue(s) this PR fixes:

Fixes #8139

Special notes for your reviewer:

Does this PR introduce a user-facing change?


Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:


@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label May 19, 2025
@k8s-ci-robot
Copy link
Contributor

Welcome @aman4433!

It looks like this is your first PR to kubernetes/autoscaler 🎉. 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/autoscaler 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
Copy link
Contributor

Hi @aman4433. Thanks for your PR.

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

@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 May 19, 2025
@k8s-ci-robot k8s-ci-robot added area/vertical-pod-autoscaler size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels May 19, 2025
@omerap12
Copy link
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 May 20, 2025
@omerap12
Copy link
Member

Thanks for this, but I see some errors:

Building updater...
Generating flags documentation...
awk: cmd. line:6:         default = ""
awk: cmd. line:6:         ^ syntax error
awk: cmd. line:6:         default = ""
awk: cmd. line:6:         ^ syntax error
awk: cmd. line:6:         default = ""
awk: cmd. line:6:         ^ syntax error

@aman4433 aman4433 force-pushed the feature-gate-fix branch from f962725 to 960f4c2 Compare May 20, 2025 06:02
@aman4433
Copy link
Contributor Author

Thanks for this, but I see some errors:

Building updater...
Generating flags documentation...
awk: cmd. line:6:         default = ""
awk: cmd. line:6:         ^ syntax error
awk: cmd. line:6:         default = ""
awk: cmd. line:6:         ^ syntax error
awk: cmd. line:6:         default = ""
awk: cmd. line:6:         ^ syntax error

It's fixed now!

@aman4433 aman4433 force-pushed the feature-gate-fix branch from 960f4c2 to c03cdd4 Compare May 20, 2025 15:18
@omerap12
Copy link
Member

looks very good to me.
Thanks @aman4433
/assign @adrianmoisey

@omerap12
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 May 21, 2025
@adrianmoisey
Copy link
Member

/approve
/hold

We just want to get another older PR into master before this PR lands.
Once that PR is in, this one will need to be rebased with those changes, sorry about that!

@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. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels May 21, 2025
@aman4433
Copy link
Contributor Author

Sure @adrianmoisey, just let me know once the older PR is in, and I'll go ahead and rebase this one with those changes!

@omerap12
Copy link
Member

Sure @adrianmoisey, just let me know once the older PR is in, and I'll go ahead and rebase this one with those changes!

With this 7992 merged can you please rebase and re-run the flag generation script?

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label May 21, 2025
@aman4433 aman4433 force-pushed the feature-gate-fix branch from c03cdd4 to 0e2b7b0 Compare May 21, 2025 09:20
@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 May 21, 2025
@omerap12
Copy link
Member

This is a flake, can you make another empty commit just to trigger the tests again?

@aman4433 aman4433 force-pushed the feature-gate-fix branch from 0e2b7b0 to 83b370e Compare May 21, 2025 11:11
@omerap12
Copy link
Member

Great work @aman4433 , thanks!
/lgtm
/approve
/unhold

@k8s-ci-robot k8s-ci-robot added lgtm "Looks good to me", indicates that a PR is ready to be merged. and removed do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. labels May 21, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: adrianmoisey, aman4433, omerap12

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 merged commit 086fd44 into kubernetes:master May 21, 2025
6 of 7 checks passed
@aman4433
Copy link
Contributor Author

Thanks! Looking forward to more contributions.

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/vertical-pod-autoscaler 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/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add --feature-gates support to VPA flag generation script
4 participants