Sennevds / system_sensors

Logging of system sensor specific for the RPI and sending them to a MQTT broker
MIT License
362 stars 112 forks source link

Error on 2 Pi #86

Closed joeduck closed 2 years ago

joeduck commented 3 years ago

Hi,

i have a Raspi3 and a Raspi4 with actual Rasperrby PI OS running. On both i have these errors. Can you help? Many thanks in advance.

send config message Connected to broker Exception in thread Thread-1: Traceback (most recent call last): File "/usr/lib/python3.7/threading.py", line 917, in _bootstrap_inner self.run() File "src/system_sensors.py", line 66, in run self.execute(*self.args, **self.kwargs) File "src/system_sensors.py", line 124, in updateSensors payload_str + f', "disk_use_{drive.lower()}": {get_disk_usage(settings["external_drives"][drive])}' File "src/system_sensors.py", line 154, in get_disk_usage return str(psutil.disk_usage(path).percent) File "/usr/local/lib/python3.7/dist-packages/psutil/__init__.py", line 2120, in disk_usage return _psplatform.disk_usage(path) File "/usr/local/lib/python3.7/dist-packages/psutil/_psposix.py", line 125, in disk_usage st = os.statvfs(path) TypeError: statvfs: path should be string, bytes, os.PathLike or integer, not NoneType

Sensors on HA where created, but only the "Undervoltage" Sensor has an Value (OK).

Sennevds commented 3 years ago

Sorry for the late reply can you share your config?