-
Notifications
You must be signed in to change notification settings - Fork 81
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: Bind kube client configuration flags before instantiating a kube client #42
fix: Bind kube client configuration flags before instantiating a kube client #42
Conversation
Codecov Report
@@ Coverage Diff @@
## master #42 +/- ##
=========================================
- Coverage 75.38% 74.8% -0.59%
=========================================
Files 5 5
Lines 390 381 -9
=========================================
- Hits 294 285 -9
Misses 84 84
Partials 12 12
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if this is more complicated than it needs to be? But I could well be wrong...
pkg/cmd/list.go
Outdated
}) | ||
configFlags.AddFlags(cmd.Flags()) | ||
o.configFlags.AddFlags(cmd.Flags()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if a simpler fix would have just been to move the lines that were at lines 124-152 to be after these flags have been set up? I don't love the extra complexity of having the separate whoCanOptions
struct just to hold the configFlags
(but am I missing something?)
… client Resolves: #41
You were right @lizrice It can be done simpler. Thanks for pointing this out. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, thanks!
Resolves: #41