Bug 1609179
Summary: | oc patch returns return code 1 if resource does not need patching | ||
---|---|---|---|
Product: | OpenShift Container Platform | Reporter: | Ger-Jan te Dorsthorst <gtedorst> |
Component: | oc | Assignee: | Juan Vallejo <jvallejo> |
Status: | CLOSED ERRATA | QA Contact: | Xingxing Xia <xxia> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | 3.9.0 | CC: | aos-bugs, jokerman, mmccomas |
Target Milestone: | --- | ||
Target Release: | 3.11.0 | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2018-10-11 07:22:24 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Ger-Jan te Dorsthorst
2018-07-27 08:32:53 UTC
The issue comes from the fix for https://bugzilla.redhat.com/show_bug.cgi?id=1311786 It seems the patch code would need to differentiate between multiple conditions leading to a 'not patched' result [1]. 1. nothing was patched because resource did not need patching -> exit code 0 2. nothing was patched because the patch wasn't valid, or because of some other error -> exit code 1 [1] https://access.redhat.com/solutions/3345621 Upstream PR: https://github.com/kubernetes/kubernetes/pull/66725 This patch slightly alters the behavior of the "patch" command to reflect the following scenarios: 1. nothing was patched because the resource did not need patching -> "<object> not patched" and "exit code 0" 2. nothing was patched because the patch was invalid or due to an unexpected error -> "<object> not patched" and "exit code 1" 3. any other case -> "<object> patched" and "exit code 0" https://github.com/openshift/origin/pull/20456 has merged. Moving to MODIFIED Verified in v3.11.0-0.22.0, the result is same as comment 4 Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2018:2652 |