-
Notifications
You must be signed in to change notification settings - Fork 43
fix empty client in action config #226
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 empty client in action config #226
Conversation
/hold |
hold till #225 merges |
9f031a0
to
36c08db
Compare
@ankitathomas could you explain what the issue with the client is and how it can be reproduced? Can cfg If not and if the Can the |
what happened was that when
This would be ok if the actionConfig client is initialized beforehand, but that happens in the PersistentPreRunE for the root command and until that runs, actionConfig.client is nil. Since command registration happens before A workaround was to pass the entire actionConfig so by the time we end up using the client in |
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
@ankitathomas Can you please clarify why we need to wait for #225? |
/hold cancel |
@ankitathomas Looks like lint test is failing with below errors
|
36c08db
to
1b44365
Compare
1b44365
to
bb0242f
Compare
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
/lgtm cancel |
I was trying out a different solution. I tried moving the I didn't want this to be a potential bug in future so I switched the implementation back, it's now what it used to be. |
bb0242f
to
356172e
Compare
Also adding some nil value checks for printing clusterCatalogs and clusterExtensions. Signed-off-by: Ankita Thomas <[email protected]>
356172e
to
95f75bd
Compare
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
Fixing the panic because of the empty client in action config
Also adding some nil value checks for printing clusterCatalogs and clusterExtensions.