Bug 1827568

Summary: operand creation page turned to be blank when the alm-examples of csv contains illegal field on console
Product: OpenShift Container Platform Reporter: shahan <hasha>
Component: Management ConsoleAssignee: Zac Herman <zherman>
Status: CLOSED ERRATA QA Contact: Yadan Pei <yapei>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 4.5CC: aos-bugs, jokerman, zherman
Target Milestone: ---   
Target Release: 4.5.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-07-13 17:31:14 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 shahan 2020-04-24 08:39:50 UTC
Description of problem:
operand creation page turned to be blank when csv contains illegal field on console

Version-Release number of selected component (if applicable):
4.5.0-0.nightly-2020-04-21-103613

How reproducible:
Always

Steps to Reproduce:
1. Intall operator and goto it's operand creation page. here such as logging operator.
2. goto csv yaml editor, update any field under alm-examples to illegal. for example: remove quotes for "apiVersion": "logging.openshift.io/v1"
3. goto ClusterLoggings tab to create operand, click the create button 

Actual results:
3. the console turned to be blank 
SyntaxError: Unexpected token n in JSON at position 837
    at JSON.parse (<anonymous>)
    at create-operand-chunk-cb7a03841f29cefc075d.min.js:1
    at Object.useMemo (vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893)
    at Object.useMemo (vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166858)
    at N (create-operand-chunk-cb7a03841f29cefc075d.min.js:1)
    at Ni (vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893)
    at ha (vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893)
    at Ku (vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893)
    at Bu (vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893)
    at Lu (vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893)
Da @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Ha.n.callback @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Lo @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
No @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
(anonymous) @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
t.unstable_runWithPriority @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:167187
co @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Wu @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Du @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
(anonymous) @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
t.unstable_runWithPriority @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:167187
co @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
ho @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
po @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Mu @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
notify @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:35325
t.notifyNestedSubs @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:35325
n.notifySubscribers @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:90059
t.handleChangeWrapper @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:35325
v @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:4755
(anonymous) @ main-chunk-0cbf2210f61cb831c370.min.js:1
dispatch @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:4755
(anonymous) @ main-chunk-0cbf2210f61cb831c370.min.js:1
Promise.then (async)
u @ main-chunk-0cbf2210f61cb831c370.min.js:1
(anonymous) @ main-chunk-0cbf2210f61cb831c370.min.js:1
(anonymous) @ main-chunk-0cbf2210f61cb831c370.min.js:1
(anonymous) @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:4755
(anonymous) @ main-chunk-0cbf2210f61cb831c370.min.js:1
t.start @ main-chunk-0cbf2210f61cb831c370.min.js:1
t.UNSAFE_componentWillMount @ main-chunk-0cbf2210f61cb831c370.min.js:1
qo @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
ma @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Ku @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Bu @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Lu @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Du @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
(anonymous) @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
t.unstable_runWithPriority @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:167187
co @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
ho @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
po @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Tu @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
enqueueSetState @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
_.setState @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166858
(anonymous) @ main-chunk-0cbf2210f61cb831c370.min.js:1
Promise.then (async)
t.loadComponent @ main-chunk-0cbf2210f61cb831c370.min.js:1
t.componentDidMount @ main-chunk-0cbf2210f61cb831c370.min.js:1
(anonymous) @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
t.unstable_runWithPriority @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:167187
co @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Wu @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Du @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
(anonymous) @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
t.unstable_runWithPriority @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:167187
co @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
ho @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
po @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
Ru @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893
(anonymous) @ vendors~main-chunk-e7f5e48676eb71b092b6.min.js:166893

Expected results:
3.The page should not blank even though the example yaml is invalid.

Additional info:

Comment 1 shahan 2020-04-24 11:14:04 UTC
Also, if input unsupported field under the "alm-examples" will occur this issue as well

Comment 4 shahan 2020-05-07 06:42:38 UTC
update "alm-examples" to invalid, the console would not turn to be blank anymore
4.5.0-0.nightly-2020-05-06-003431

Comment 5 errata-xmlrpc 2020-07-13 17:31:14 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:2409