[checkmk-commits] Check_MK Git: check_mk: FIX event console view: fixed exception on rendering host tags for unknown hosts

Andreas Boesl ab at mathias-kettner.de
Thu Apr 17 15:06:40 CEST 2014


Module: check_mk
Branch: master
Commit: f2bd1dffc44596abd212de8b30ab6d0891f2e13e
URL:    http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=f2bd1dffc44596abd212de8b30ab6d0891f2e13e

Author: Andreas Boesl <ab at mathias-kettner.de>
Date:   Thu Apr 17 15:05:42 2014 +0200

FIX event console view: fixed exception on rendering host tags for unknown hosts

The event console was unable to render specific host tag columns
when the monitoring system had no knowledge of the host in question.

---

 .werks/902          |   10 ++++++++++
 ChangeLog           |    1 +
 web/htdocs/views.py |    2 +-
 3 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/.werks/902 b/.werks/902
new file mode 100644
index 0000000..adf8c9b
--- /dev/null
+++ b/.werks/902
@@ -0,0 +1,10 @@
+Title: event console view: fixed exception on rendering host tags for unknown hosts
+Level: 1
+Component: ec
+Class: fix
+State: unknown
+Version: 1.2.5i3
+Date: 1397739863
+
+The event console was unable to render specific host tag columns
+when the monitoring system had no knowledge of the host in question.
diff --git a/ChangeLog b/ChangeLog
index b4e41b8..b34156d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -66,6 +66,7 @@
 
     Event Console:
     * 0885 New option for writing all messages into a syslog-like logfile...
+    * 0902 FIX: event console view: fixed exception on rendering host tags for unknown hosts...
 
     Livestatus:
     * 0747 FIX: livestatus table hostsbygroup: fixed bug with group_authorization strict...
diff --git a/web/htdocs/views.py b/web/htdocs/views.py
index bcb8f5c..6029ff1 100644
--- a/web/htdocs/views.py
+++ b/web/htdocs/views.py
@@ -2735,7 +2735,7 @@ def get_painter_option(name):
     return opt.get("value", opt['valuespec'].default_value())
 
 def get_host_tags(row):
-    if "host_custom_variables" in row:
+    if type(row.get("host_custom_variables")) == dict:
         return row["host_custom_variables"].get("TAGS", "")
 
     for name, val in zip(row["host_custom_variable_names"],



More information about the checkmk-commits mailing list