Description of problem: Executing 'oc get --all-namespaces --output=json projectrequests' causes panic. The combination of 'projectrequests' type and -o to yaml or json seems to cause the problem. Version-Release number of selected component (if applicable): 3.5 3.6 (Customer logged bug with OCP 3.6.1 but I can reproduce using same command using OCP 3.5) How reproducible: Execute 'oc get --all-namespaces --output=json projectrequests' on the CLI Steps to Reproduce: 1. Log in to master 2. Execute 'oc get --all-namespaces --output=json projectrequests' 3. Actual results: $ oc get --all-namespaces --output=json projectrequests panic: interface conversion: runtime.Object is *unversioned.Status, not *runtime.Unstructured goroutine 1 [running]: panic(0x1fabce0, 0xc4209ac640) /usr/lib/golang/src/runtime/panic.go:500 +0x1a1 github.com/openshift/origin/vendor/k8s.io/kubernetes/pkg/kubectl/cmd.RunGet(0x362aae0, 0xc420a385a0, 0x35fcd80, 0xc420026010, 0x35fcd80, 0xc420026018, 0xc4202f2b40, 0xc4206f3710, 0x1, 0x3, ...) /builddir/build/BUILD/atomic-openshift-git-0.b6f55a2/_output/local/go/src/github.com/openshift/origin/vendor/k8s.io/kubernetes/pkg/kubectl/cmd/get.go:341 +0xcda github.com/openshift/origin/vendor/k8s.io/kubernetes/pkg/kubectl/cmd.NewCmdGet.func1(0xc4202f2b40, 0xc4206f3710, 0x1, 0x3) /builddir/build/BUILD/atomic-openshift-git-0.b6f55a2/_output/local/go/src/github.com/openshift/origin/vendor/k8s.io/kubernetes/pkg/kubectl/cmd/get.go:105 +0x95 github.com/openshift/origin/vendor/github.com/spf13/cobra.(*Command).execute(0xc4202f2b40, 0xc4206f3680, 0x3, 0x3, 0xc4202f2b40, 0xc4206f3680) /builddir/build/BUILD/atomic-openshift-git-0.b6f55a2/_output/local/go/src/github.com/openshift/origin/vendor/github.com/spf13/cobra/command.go:603 +0x439 github.com/openshift/origin/vendor/github.com/spf13/cobra.(*Command).ExecuteC(0xc420314240, 0xc420026008, 0xc420026018, 0xc420314240) /builddir/build/BUILD/atomic-openshift-git-0.b6f55a2/_output/local/go/src/github.com/openshift/origin/vendor/github.com/spf13/cobra/command.go:689 +0x367 github.com/openshift/origin/vendor/github.com/spf13/cobra.(*Command).Execute(0xc420314240, 0x2, 0xc420314240) /builddir/build/BUILD/atomic-openshift-git-0.b6f55a2/_output/local/go/src/github.com/openshift/origin/vendor/github.com/spf13/cobra/command.go:648 +0x2b main.main() /builddir/build/BUILD/atomic-openshift-git-0.b6f55a2/_output/local/go/src/github.com/openshift/origin/cmd/oc/oc.go:36 +0x196 Expected results: Don't panic Additional info:
Related github issue: https://github.com/openshift/origin/issues/16064
Upstream PR: https://github.com/kubernetes/kubernetes/pull/51727
Origin PR (patch available in latest master): https://github.com/openshift/origin/pull/16082
Checked this issue on oc v3.7.0-alpha.1+37bf502-282 version, it works well now. [hasha@mypc origin]$ git log --pretty="%h %an %cd - %s" 37bf502 | grep '#16082' 4c6b2eb OpenShift Merge Robot Fri Sep 8 22:03:25 2017 -0700 - Merge pull request #16082 from juanvallejo/jvallejo/ensure-unstructured-objects-before-composing [root@test ~]#oc get --all-namespaces --output=json projectrequests { "apiVersion": "v1", "items": [ { "apiVersion": "v1", "kind": "Status", "metadata": {}, "status": "Success" } ], "kind": "List", "metadata": { "resourceVersion": "", "selfLink": "" } } Changed status to verified
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/RHSA-2017:3188