-
Notifications
You must be signed in to change notification settings - Fork 109
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
app.NewCloudControllerManagerCommand additionalFlags not working as expected #62
Comments
Hi, If I spend my time looking to propose a fix to this issue, and assuming the code is good, would it be reviewed and merged? Thank in advance. |
It fixes kubernetes/cloud-provider#62 Signed-off-by: Sven Nebel <nebel.sven@gmail.com>
I have created kubernetes/kubernetes#112405 with a fix for this which is awaiting for review, feedback is welcomed. |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle rotten |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /close not-planned |
@k8s-triage-robot: Closing this issue, marking it as "Not Planned". In response to this:
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. |
Hi,
Poking around with
app.NewCloudControllerManagerCommand
I noticedadditionalFlags
argument does not seems to be working as I would expect, while the flag is parsed it is not show in the usage or help.When an additional flagSet is passed it is parsed, and can be used however it is not shown in the usage or help of the command.
To reproduce, use the following snippet of code:
The flag is not shown in the help with the existing cloud controller manager flags, the following command return no results.
$ go run cmd/test/main.go --help |grep abcd
While the flag has been really bound and parsed and can In fact be used.
It does feel either a bug or an unimplemented feature, while the additional flags are successfully bound in
cloud-provider/app/controllermanager.go
Line 123 in 9c22fcd
The problem seems to be in the the use
namedFlagSets
which does not contain the additional flags to print he usage and help sectionscloud-provider/app/controllermanager.go
Line 130 in 9c22fcd
cloud-provider/app/controllermanager.go
Line 135 in 9c22fcd
I wouldn't mind having a closer look and propose a fix if one would be accepted, I just wanted to share and get feedback first to ensure this make sense.
Cheers.
The text was updated successfully, but these errors were encountered: