-
Bug
-
Resolution: Done-Errata
-
None
-
False
-
-
False
-
NoActiveCustomerTickets
-
VERIFIED
-
---
-
---
-
-
-
Moderate
-
No
Description of problem:
Created a template without "parameters":
~~~
oc get template example -n default
NAME DESCRIPTION PARAMETERS OBJECTS
example VM template example 0 (all set) 1
~~~
Try creating a VM with this template.
Virtualization => Catalog => Select the template => Customize virtual machine
This fails with the error below:
~~~
Oh no! Something went wrong.
Stack trace:
TypeError: Cannot read properties of undefined (reading 'reduce')
at https://console-openshift-console.apps.ocp4.shiftvirt.com/api/plugins/kubevirt-plugin/exposed-TemplatesCatalog-chunk.js:1385:82
at jc (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:104246)
at t.unstable_runWithPriority (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:262:3768)
at Hi (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:44551)
at Ec (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:103709)
at https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:103620
at N (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:262:2828)
at C.port1.onmessage (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:262:1551)
~~~
Also, try templates => click on template => Parameters:
Fails with the error below:
~~~
Oh no! Something went wrong.
Stack trace:
TypeError: Cannot read properties of undefined (reading 'map')
at TemplateParametersPage (https://console-openshift-console.apps.ocp4.shiftvirt.com/api/plugins/kubevirt-plugin/exposed-TemplateNavPage-chunk.js:4092:28)
at na (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:58879)
at Hs (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:111315)
at wc (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:98327)
at Cc (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:98255)
at _c (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:98118)
at pc (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:95105)
at https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:44774
at t.unstable_runWithPriority (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:262:3768)
at Hi (https://console-openshift-console.apps.ocp4.shiftvirt.com/static/vendors~main-chunk-d016eb3bffbfe8cee1da.min.js:254:44551)
~~~
Version-Release number of selected component (if applicable):
OpenShift Virtualization 4.12.2
How reproducible:
100 %
Steps to Reproduce:
1. Create a template without parameters.
2. Navigate to,
Virtualization => Catalog => Select the template => Customize virtual machine
and
try templates => click on template => Parameters
The console fails with the above errors.
Actual results:
Console errors while using a template without "parameters"
Expected results:
The console shouldn't crash.
Additional info:
- external trackers
- links to
- mentioned on