import json
from homeassistant.core import Event as Event, State as State
from homeassistant.exceptions import HomeAssistantError as HomeAssistantError
from typing import Any, Callable

_LOGGER: Any

class SerializationError(HomeAssistantError): ...
class WriteError(HomeAssistantError): ...

def load_json(filename: str, default: Union[list, dict, None] = ...) -> Union[list, dict]: ...
def save_json(filename: str, data: Union[list, dict], private: bool = ..., *, encoder: Union[type[json.JSONEncoder], None] = ...) -> None: ...
def format_unserializable_data(data: dict[str, Any]) -> str: ...
def find_paths_unserializable_data(bad_data: Any, *, dump: Callable[[Any], str] = ...) -> dict[str, Any]: ...
