From: paulfantom Date: Fri, 1 Jul 2016 11:40:58 +0000 (+0200) Subject: error messages X-Git-Tag: v1.3.0~97^2~4 X-Git-Url: https://arthur.barton.de/gitweb/?a=commitdiff_plain;h=0eeb6b81432fa037e98e0d17d853136f761d4716;p=netdata.git error messages --- diff --git a/python.d/python_modules/base.py b/python.d/python_modules/base.py index 0a52350c..6958eb8e 100644 --- a/python.d/python_modules/base.py +++ b/python.d/python_modules/base.py @@ -453,16 +453,14 @@ class LogService(SimpleService): return None def check(self): - if self.name is None or self.name == str(None): - self.error("Log service doesn't have name.") - return False + if self.name is not None or self.name != str(None): + self.name = "" else: self.name = str(self.name) try: self.log_path = str(self.configuration['path']) except (KeyError, TypeError): - self.error("Malformed path to log: '" + self.log_path + "'") - return False + self.error("No path to log specified. Using: '" + self.log_path + "'") # FIXME Remove preventing of frequent log parsing if self.update_every < 3: @@ -471,5 +469,5 @@ class LogService(SimpleService): if os.access(self.log_path, os.R_OK): return True else: - self.error("Cannot access file. No read permission.") + self.error("Cannot access file: '" + self.log_path + "'") return False