Repository navigation
Improve ignore-not-found behavior - #132542
Conversation
|
Hi @gemmahou. 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 Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions 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. |
|
/assign @seans3 |
|
/ok-to-test |
|
/triage accepted |
seans3
left a comment
There was a problem hiding this comment.
This looks good, and thanks for the tests. But if I understood the conversation in this issue correctly, I believe there should also be a warning if the --ignore-not-found flag is set when not getting a specific resource. In other words, it doesn't make sense to set the flag unless also retrieving a specific resource. Please let me know what you think.
|
/hold |
Thanks @brianpursley for your review! I got some clarifications to your comments, and I agree that if the warning is confusing for us as developers, it will likely further confuse our users. I agree we should hold off on implementing the warning message for now, unless we can find a clearer way to present it to users. Regarding your 2nd option: Only print the warning when you are NOT attempting to get a specific resource by name, and the warning would basically be "warning: --ignore-not-found has no effect". I believe @seans3 suggested the same earlier and I replied in this comment why I did not implement that way, I appreciate your thoughts/comments on this. Update: I reverted the warning commit in this PR and cherry-picked it to draft PR: #132690 for visibility and further discussion. |
brianpursley
left a comment
There was a problem hiding this comment.
Looks good. Thanks!
/unhold
/lgtm
/approve
|
LGTM label has been added. DetailsGit tree hash: 3377cb6e49bd13ecfadd895f526bb02880bc9d28 |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: brianpursley, gemmahou, seans3 The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/label tide/merge-method-squash |
|
/retest |
* Improve ignore-not-found behavior * ignore lint errcheck
* Improve ignore-not-found behavior * ignore lint errcheck
What type of PR is this?
before:
after:
watchoperation as well; when it's set to true, ignore errors/kind bug
What this PR does / why we need it:
Which issue(s) this PR is related to:
kubernetes/kubectl#1596
Special notes for your reviewer:
Does this PR introduce a user-facing change?
Yes
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.: