]> arthur.barton.de Git - netdata.git/commitdiff
add new option to conf file; returned back if in chart.py
authorlgz <lgz@loled2>
Sat, 24 Dec 2016 19:06:59 +0000 (04:06 +0900)
committerlgz <lgz@loled2>
Sat, 24 Dec 2016 19:06:59 +0000 (04:06 +0900)
conf.d/python.d/hddtemp.conf
python.d/hddtemp.chart.py

index 0c78449b42eaecdc589a25f812d9a2fb013607c2..f74a09803aa2bb7e89d11611dab36cce14f863d6 100644 (file)
@@ -58,6 +58,7 @@
 #
 #     host: 'IP or HOSTNAME' # the host to connect to
 #     port: PORT             # the port to connect to
+#     fahrenheit: True/False # fahrenheit instead of celsius. Default is False
 #
 
 # By default this module will try to autodetect disks
 localhost:
   name: 'local'
   host: 'localhost'
+  fahrenheit: False
   port: 7634
 
 localipv4:
   name: 'local'
   host: '127.0.0.1'
+  fahrenheit: False
   port: 7634
 
 localipv6:
index 237666b3b540d5f402339aa4163ddd4b002f0ee0..8a98995be9e96db0dfae604d536e32fbf04775d7 100644 (file)
@@ -82,7 +82,7 @@ class Service(SocketService):
                 val = 0
             data[raw[i*5+1].replace("/dev/", "")] = val
 
-        if not data:
+        if len(data) == 0:
             self.error("received data doesn't have needed records")
             return None
         else: