mirror of
https://github.com/home-assistant/core.git
synced 2026-05-16 05:21:35 +01:00
bf92db6fd5
* Add diagnotics to eheimdigital * Diagnostics are now with data in tests
20 lines
567 B
Python
20 lines
567 B
Python
"""Diagnostics for the EHEIM Digital integration."""
|
|
|
|
from typing import Any
|
|
|
|
from homeassistant.components.diagnostics import async_redact_data
|
|
from homeassistant.core import HomeAssistant
|
|
|
|
from .coordinator import EheimDigitalConfigEntry
|
|
|
|
TO_REDACT = {"emailAddr", "usrName"}
|
|
|
|
|
|
async def async_get_config_entry_diagnostics(
|
|
hass: HomeAssistant, entry: EheimDigitalConfigEntry
|
|
) -> dict[str, Any]:
|
|
"""Return diagnostics for a config entry."""
|
|
return async_redact_data(
|
|
{"entry": entry.as_dict(), "data": entry.runtime_data.data}, TO_REDACT
|
|
)
|