Bug 1698235 - `oc describe` displays labels with invalid spacing and capitalization, fix is in upstream
Summary: `oc describe` displays labels with invalid spacing and capitalization, fix is...
Keywords:
Status: CLOSED DUPLICATE of bug 1656328
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Master
Version: 4.1.0
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: ---
: ---
Assignee: Michal Fojtik
QA Contact: Xingxing Xia
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-04-09 21:14 UTC by Kirsten Garrison
Modified: 2019-04-10 16:37 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-04-10 16:37:57 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Kirsten Garrison 2019-04-09 21:14:35 UTC
Description of problem:
This is from Bug 1696397, which is not an MCO bug but an `oc describe` bug that was fixed in upstream a few weeks ago:

oc describe on several machineconfig apis displays labels names with corrupting spacing and capitalization. 

For example (from `oc describe machineconfigpool worker`):
>>>>>
Spec:
  Machine Config Selector:
    Match Labels:
      Machineconfiguration . Openshift . Io / Role:  worker
  Machine Selector:
    Match Labels:
      Node - Role . Kubernetes . Io / Worker:  
<<<<<

Version-Release number of selected component (if applicable):
4.0.0-0.9

How reproducible:
100%

Steps to Reproduce:
1. oc describe machineconfigpool worker
2.
3.

Actual results:
Label names corrupted with spacing and capitalization..
 Machineconfiguration . Openshift . Io / Role:  worker

Expected results:
 machineconfiguration.openshift.io/role: worker

Additional details:
Other resources are also affected (e.g. machinesets)


Additional info:
This is related to kubectl's describe. The smartLabelFor() function is what is adding the capitalization and the spaces:
 : https://github.com/kubernetes/kubernetes/blob/fd98e7abf042251bb094a5535d67f53d36021246/pkg/kubectl/describe/versioned/describe.go#L306


However ~2 weeks ago, a PR was merged into the upstream that fixes this issue:
https://github.com/kubernetes/kubernetes/pull/75483

To fix this we'd have to update our oc which is using 1.13 currently.

According to the original issue filing upstream, the fix will be in v1.15:
https://github.com/kubernetes-sigs/cluster-api-provider-aws/issues/260#issuecomment-478585501

Was told that as of right now 1.15 (containing this fix) would be pulled into 4.3

Opening this in the proper proper BZ component to have this issue tracked for an eventual fix.

Comment 1 Xingxing Xia 2019-04-10 02:16:57 UTC
https://bugzilla.redhat.com/show_bug.cgi?id=1656328

Comment 2 Kirsten Garrison 2019-04-10 16:37:57 UTC

*** This bug has been marked as a duplicate of bug 1656328 ***


Note You need to log in before you can comment on or make changes to this bug.