Bug 1788357 - `oc version -o yaml` does not show the oc detailed version infomation
Summary: `oc version -o yaml` does not show the oc detailed version infomation
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: oc
Version: 4.4
Hardware: Unspecified
OS: Unspecified
urgent
urgent
Target Milestone: ---
: 4.4.0
Assignee: Maciej Szulik
QA Contact: zhou ying
URL:
Whiteboard:
Depends On:
Blocks: 1793267
TreeView+ depends on / blocked
 
Reported: 2020-01-07 02:36 UTC by zhou ying
Modified: 2020-05-04 11:23 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: No Doc Update
Doc Text:
Clone Of:
: 1793267 (view as bug list)
Environment:
Last Closed: 2020-05-04 11:23:07 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2020:0581 0 None None None 2020-05-04 11:23:40 UTC

Description zhou ying 2020-01-07 02:36:29 UTC
Description of problem:
Install the latest oc from the repo, use `oc version -o yaml` command to check version info, the buildDate/gitCommit/gitTreeState/gitVersion are all empty.

Version-Release number of selected component (if applicable):
4.4.0-202001061648.git.1.a1c3e4d.el7

How reproducible:
Always

Steps to Reproduce:
1. Install oc from repo: http://download.eng.bos.redhat.com/rcm-guest/puddles/RHAOS/AtomicOpenShift/4.4/latest/x86_64/os/
2. Check the oc version
    `oc version -o yaml`

Actual results:
2. [root@dhcp-140-138 ~]# oc version -o yaml 
clientVersion:
  buildDate: ""
  compiler: gc
  gitCommit: ""
  gitTreeState: ""
  gitVersion: unknown
  goVersion: go1.13.4
  major: ""
  minor: ""
  platform: linux/amd64

Expected results:
2. Show correct infomation of the oc version.

Additional info:

Comment 1 Maciej Szulik 2020-01-07 12:50:00 UTC

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

Comment 2 Xingxing Xia 2020-01-16 09:06:17 UTC
This bug is different symptom from bug 1780779. Even if same, that bug's Target Release is 4.2.z, but this bug is for 4.4, need separate bugs.

Comment 4 Maciej Szulik 2020-01-17 14:54:51 UTC
This might have been fixed in https://github.com/openshift/oc/pull/250

Comment 6 zhou ying 2020-01-19 01:14:31 UTC
Confirmed with oc extraced from payload: 4.4.0-0.nightly-2020-01-18-210238, the issue has fixed:

[root@localhost home]# ./oc version  --client -o yaml
clientVersion:
  buildDate: "2020-01-17T09:20:02Z"
  compiler: gc
  gitCommit: e17af88a81bab82a47aa161fb0db99f6e9424661
  gitTreeState: dirty
  gitVersion: openshift-clients-4.3.0-201910250623-168-ge17af88a
  goVersion: go1.13.4
  major: ""
  minor: ""
  platform: linux/amd64
releaseClientVersion: 4.4.0-0.nightly-2020-01-18-210238

Comment 8 errata-xmlrpc 2020-05-04 11:23:07 UTC
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-2020:0581


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