DS18B20 crash
Saw the following crash on my RPi:
May 06 19:14:53 hallmonitor-pi python3[25286]: Exception in thread Plugin-0-DS18B20:
May 06 19:14:53 hallmonitor-pi python3[25286]: Traceback (most recent call last):
May 06 19:14:53 hallmonitor-pi python3[25286]: File "/usr/lib/python3.7/threading.py", line 917, in _bootstrap_inner
May 06 19:14:53 hallmonitor-pi python3[25286]: self.run()
May 06 19:14:53 hallmonitor-pi python3[25286]: File "/home/pi/mqtt4hass/mqtt4hass.py", line 145, in run
May 06 19:14:53 hallmonitor-pi python3[25286]: self.loop()
May 06 19:14:53 hallmonitor-pi python3[25286]: File "/home/pi/mqtt4hass/plugins/ds18b20/__init__.py", line 22, in loop
May 06 19:14:53 hallmonitor-pi python3[25286]: temp_c = DS18B20.read_temp(device_folder)
May 06 19:14:53 hallmonitor-pi python3[25286]: File "/home/pi/mqtt4hass/plugins/ds18b20/__init__.py", line 67, in read_temp
May 06 19:14:53 hallmonitor-pi python3[25286]: while lines[0].strip()[-3:] != "YES":
May 06 19:14:53 hallmonitor-pi python3[25286]: IndexError: list index out of range
It looks like if there is an error reading the sensor, the plugin just crashes. It probably should log an error and try again on the next scheduled interval.