mirror of
https://github.com/home-assistant/core.git
synced 2025-07-27 23:27:37 +00:00
Add diagnostics for screenlogic (#67368)
This commit is contained in:
parent
148762ce3f
commit
974296697e
@ -995,6 +995,7 @@ omit =
|
|||||||
homeassistant/components/screenlogic/__init__.py
|
homeassistant/components/screenlogic/__init__.py
|
||||||
homeassistant/components/screenlogic/binary_sensor.py
|
homeassistant/components/screenlogic/binary_sensor.py
|
||||||
homeassistant/components/screenlogic/climate.py
|
homeassistant/components/screenlogic/climate.py
|
||||||
|
homeassistant/components/screenlogic/diagnostics.py
|
||||||
homeassistant/components/screenlogic/light.py
|
homeassistant/components/screenlogic/light.py
|
||||||
homeassistant/components/screenlogic/number.py
|
homeassistant/components/screenlogic/number.py
|
||||||
homeassistant/components/screenlogic/sensor.py
|
homeassistant/components/screenlogic/sensor.py
|
||||||
|
21
homeassistant/components/screenlogic/diagnostics.py
Normal file
21
homeassistant/components/screenlogic/diagnostics.py
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
"""Diagnostics for Screenlogic."""
|
||||||
|
|
||||||
|
from homeassistant.config_entries import ConfigEntry
|
||||||
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
||||||
|
from . import ScreenlogicDataUpdateCoordinator
|
||||||
|
from .const import DOMAIN
|
||||||
|
|
||||||
|
|
||||||
|
async def async_get_config_entry_diagnostics(
|
||||||
|
hass: HomeAssistant, config_entry: ConfigEntry
|
||||||
|
) -> dict:
|
||||||
|
"""Return diagnostics for a config entry."""
|
||||||
|
coordinator: ScreenlogicDataUpdateCoordinator = hass.data[DOMAIN][
|
||||||
|
config_entry.entry_id
|
||||||
|
]
|
||||||
|
|
||||||
|
return {
|
||||||
|
"config_entry": config_entry.as_dict(),
|
||||||
|
"data": coordinator.data,
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user