mirror of
https://github.com/Electric-Special/ha-core.git
synced 2026-03-21 03:03:17 +01:00
Use default time zone for boot time (#161605)
This commit is contained in:
@@ -221,7 +221,9 @@ class SystemMonitorCoordinator(TimestampDataUpdateCoordinator[SensorData]):
|
||||
|
||||
if self._initial_update:
|
||||
# Boot time only needs to refresh on first pass
|
||||
self.boot_time = dt_util.utc_from_timestamp(self._psutil.boot_time())
|
||||
self.boot_time = dt_util.utc_from_timestamp(
|
||||
self._psutil.boot_time(), tz=dt_util.get_default_time_zone()
|
||||
)
|
||||
_LOGGER.debug("boot time: %s", self.boot_time)
|
||||
|
||||
selected_processes: list[Process] = []
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
'vethxyzxyz': "[snicaddr(family=<AddressFamily.AF_INET: 2>, address='172.16.10.1', netmask='255.255.255.0', broadcast='255.255.255.255', ptp=None)]",
|
||||
}),
|
||||
'battery': 'sbattery(percent=93, secsleft=16628, power_plugged=False)',
|
||||
'boot_time': '2024-02-24 15:00:00+00:00',
|
||||
'boot_time': '2024-02-24 07:00:00-08:00',
|
||||
'cpu_percent': '10.0',
|
||||
'disk_usage': dict({
|
||||
'/': 'sdiskusage(total=536870912000, used=322122547200, free=214748364800, percent=60.0)',
|
||||
@@ -79,7 +79,7 @@
|
||||
'data': dict({
|
||||
'addresses': None,
|
||||
'battery': 'sbattery(percent=93, secsleft=16628, power_plugged=False)',
|
||||
'boot_time': '2024-02-24 15:00:00+00:00',
|
||||
'boot_time': '2024-02-24 07:00:00-08:00',
|
||||
'cpu_percent': '10.0',
|
||||
'disk_usage': dict({
|
||||
'/': 'sdiskusage(total=536870912000, used=322122547200, free=214748364800, percent=60.0)',
|
||||
|
||||
Reference in New Issue
Block a user