feat: define shared constants in const.py (#2)

This commit was merged in pull request #2.
This commit is contained in:
2026-09-11 16:39:41 -04:00
parent 5c354c1ff5
commit 8d04c95314
4 changed files with 129 additions and 3 deletions
+2 -3
View File
@@ -1,15 +1,14 @@
"""The NestQuest integration."""
from __future__ import annotations
import logging
from typing import Any
from homeassistant.config_entries import ConfigEntry
from homeassistant.core import HomeAssistant
from .const import DOMAIN
from .const import DOMAIN, LOGGER
_LOGGER = logging.getLogger(__name__)
_LOGGER = LOGGER
async def async_setup(hass: HomeAssistant, config: dict[str, Any]) -> bool:
+20
View File
@@ -1,2 +1,22 @@
"""Constants for the NestQuest integration."""
from __future__ import annotations
import logging
DOMAIN = "nestquest"
LOGGER_NAME = "custom_components.nestquest"
LOGGER = logging.getLogger(LOGGER_NAME)
PLATFORMS: list[str] = []
SQLITE_DB_FILENAME = "nestquest.db"
# Configuration keys and default values
CONF_HORIZON_DAYS = "horizon_days"
DEFAULT_HORIZON_DAYS = 14
CONF_DAY_ROLLOVER_TIME = "day_rollover_time"
DEFAULT_DAY_ROLLOVER_TIME = "00:00"
CONF_PANEL_IDLE_TIMEOUT = "panel_idle_timeout"
DEFAULT_PANEL_IDLE_TIMEOUT = 300