Add debug logger for cpu temp in System Monitor (#109627)

pull/109883/head
G Johansson 2024-02-04 14:11:28 -05:00 committed by Franck Nijhof
parent c0efec4a84
commit 7ca83a7648
No known key found for this signature in database
GPG Key ID: D62583BA8AB11CA3
1 changed files with 2 additions and 0 deletions

View File

@ -1,4 +1,5 @@
"""Utils for System Monitor."""
import logging
import os
@ -71,6 +72,7 @@ def read_cpu_temperature(temps: dict[str, list[shwtemp]] | None = None) -> float
temps = psutil.sensors_temperatures()
entry: shwtemp
_LOGGER.debug("CPU Temperatures: %s", temps)
for name, entries in temps.items():
for i, entry in enumerate(entries, start=1):
# In case the label is empty (e.g. on Raspberry PI 4),