import astral
import datetime
from homeassistant.const import SUN_EVENT_SUNRISE as SUN_EVENT_SUNRISE, SUN_EVENT_SUNSET as SUN_EVENT_SUNSET
from homeassistant.core import HomeAssistant as HomeAssistant, callback as callback
from homeassistant.loader import bind_hass as bind_hass
from typing import Any

DATA_LOCATION_CACHE: str
ELEVATION_AGNOSTIC_EVENTS: Any

def get_astral_location(hass: HomeAssistant) -> tuple[astral.location.Location, astral.Elevation]: ...
def get_astral_event_next(hass: HomeAssistant, event: str, utc_point_in_time: Union[datetime.datetime, None] = ..., offset: Union[datetime.timedelta, None] = ...) -> datetime.datetime: ...
def get_location_astral_event_next(location: astral.location.Location, elevation: astral.Elevation, event: str, utc_point_in_time: Union[datetime.datetime, None] = ..., offset: Union[datetime.timedelta, None] = ...) -> datetime.datetime: ...
def get_astral_event_date(hass: HomeAssistant, event: str, date: Union[datetime.date, datetime.datetime, None] = ...) -> Union[datetime.datetime, None]: ...
def is_up(hass: HomeAssistant, utc_point_in_time: Union[datetime.datetime, None] = ...) -> bool: ...
