Module: check_mk
Branch: master
Commit: d761c2336bdc162aba5c1464d6a725671eed33e0
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=d761c2336bdc16…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Jul 10 09:09:30 2017 +0200
WATO: Fixed "check_table referenced before assignment" error on analyze services
page
Change-Id: I9c80c8a7191f864452c150dbd194af151b4e6138
---
cmk_base/automation.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/cmk_base/automation.py b/cmk_base/automation.py
index a4559e3..20cc6de 100644
--- a/cmk_base/automation.py
+++ b/cmk_base/automation.py
@@ -296,7 +296,7 @@ def _automation_analyse_service(args):
# 4. active checks
# Compute effective check table, in order to remove SNMP duplicates
- check_table = check_table.get_check_table(hostname, remove_duplicates = True)
+ table = check_table.get_check_table(hostname, remove_duplicates = True)
# 1. Manual checks
for nr, (checkgroup, entries) in enumerate(config.static_checks.items()):
@@ -343,7 +343,7 @@ def _automation_analyse_service(args):
ct, item, params = entry # new format without host name
hn = hostname
- if (ct, item) not in check_table:
+ if (ct, item) not in table:
continue # this is a removed duplicate or clustered service
descr = config.service_description(hn, ct, item)
if hn == hostname and descr == servicedesc: