Bug 1849556 - console hit runtime error when all receivers are deleted
Summary: console hit runtime error when all receivers are deleted
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Management Console
Version: 4.5
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: 4.6.0
Assignee: Yadan Pei
QA Contact: Yadan Pei
URL:
Whiteboard:
Depends On:
Blocks: 1849739 1851088
TreeView+ depends on / blocked
 
Reported: 2020-06-22 08:28 UTC by shahan
Modified: 2020-10-27 16:09 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Cause: console hit runtime error when all receivers are deleted Consequence: user presented with blank/white screen Fix: added null checks in code Result: user presented with 'No Receivers' empty state screen
Clone Of:
: 1849739 (view as bug list)
Environment:
Last Closed: 2020-10-27 16:08:40 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
No Receivers Found (188.82 KB, image/png)
2020-07-02 03:01 UTC, Yadan Pei
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github openshift console pull 5798 0 None closed Bug 1849556: console hit runtime error when all receivers are deleted 2020-08-07 17:37:03 UTC
Red Hat Product Errata RHBA-2020:4196 0 None None None 2020-10-27 16:09:01 UTC

Description shahan 2020-06-22 08:28:49 UTC
Description of problem:
console hit runtime error when all receivers are deleted

Version-Release number of selected component (if applicable):
4.5.0-0.nightly-2020-06-20-194346

How reproducible:
Always

Steps to Reproduce:
1. goto monitoring/alertmanageryaml page, and delete all receivers including Critical, Default and Watchdog
2. refresh the page
3.

Actual results:
2. got the blank and hit runtime error:
Uncaught TypeError: Cannot read property 'filter' of undefined
    at main-chunk-b5f4dd3fa1772b07e0e5.min.js:1
    at W (main-chunk-b5f4dd3fa1772b07e0e5.min.js:1)
    at Fo (vendors~main-chunk-d1f09bab0102d8143c16.min.js:136)
    at Ks (vendors~main-chunk-d1f09bab0102d8143c16.min.js:136)
    at Bs (vendors~main-chunk-d1f09bab0102d8143c16.min.js:136)
    at Ns (vendors~main-chunk-d1f09bab0102d8143c16.min.js:136)
    at Ds (vendors~main-chunk-d1f09bab0102d8143c16.min.js:136)
    at vendors~main-chunk-d1f09bab0102d8143c16.min.js:136
    at t.unstable_runWithPriority (vendors~main-chunk-d1f09bab0102d8143c16.min.js:144)
    at li (vendors~main-chunk-d1f09bab0102d8143c16.min.js:136)

Expected results:
should not get the blank page

Additional info:

Comment 5 Yadan Pei 2020-07-02 03:01:29 UTC
Created attachment 1699588 [details]
No Receivers Found

1. admin user delete Critical and Watchdog receiver on /monitoring/alertmanagerconfig page, then remove Default receiver by editing YAML
global:
  resolve_timeout: 5m
inhibit_rules:
  - equal:
      - namespace
      - alertname
    source_match:
      severity: critical
    target_match_re:
      severity: warning|info
  - equal:
      - namespace
      - alertname
    source_match:
      severity: warning
    target_match_re:
      severity: info
receivers:               // remove this line from YAML
  - name: Default        // remove this line from YAML
route:
  group_by:
    - namespace
  group_interval: 5m
  group_wait: 30s
  receiver: Default
  repeat_interval: 12h
  routes: []
2. visit /monitoring/alertmanagerconfig page again, it will not crash, will show 'No Receivers Found' and help message


verified on 4.6.0-0.nightly-2020-06-30-020342

Comment 7 errata-xmlrpc 2020-10-27 16:08:40 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 (OpenShift Container Platform 4.6 GA Images), 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:4196


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