Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions CODEOWNERS

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ rules:
status: done
comment: |
The coordinator handles this.
parallel-updates: todo
parallel-updates: done
reauthentication-flow:
status: exempt
comment: |
Expand Down
2 changes: 2 additions & 0 deletions homeassistant/components/analytics_insights/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
from .const import DOMAIN
from .coordinator import AnalyticsData, HomeassistantAnalyticsDataUpdateCoordinator

PARALLEL_UPDATES = 0


@dataclass(frozen=True, kw_only=True)
class AnalyticsSensorEntityDescription(SensorEntityDescription):
Expand Down
11 changes: 7 additions & 4 deletions homeassistant/components/bsblan/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,10 +257,6 @@ async def async_setup_entry(hass: HomeAssistant, entry: BSBLanConfigEntry) -> bo
# Perform first refresh of fast coordinator (required for entities)
await fast_coordinator.async_config_entry_first_refresh()

# Refresh slow coordinator - don't fail if DHW is not available
# This allows the integration to work even if the device doesn't support DHW
await slow_coordinator.async_refresh()

entry.runtime_data = BSBLanData(
client=bsblan,
fast_coordinator=fast_coordinator,
Expand All @@ -271,6 +267,13 @@ async def async_setup_entry(hass: HomeAssistant, entry: BSBLanConfigEntry) -> bo
available_circuits=circuits,
)

# Fetch slow data in the background so it does not block startup.
entry.async_create_background_task(
hass,
slow_coordinator.async_refresh(),
name=f"{DOMAIN}_slow_data_fetch_{entry.entry_id}",
)

# Register main device before forwarding platforms, so sub-devices
# (heating circuits, water heater) can reference it via via_device
device_registry = dr.async_get(hass)
Expand Down
41 changes: 29 additions & 12 deletions homeassistant/components/bsblan/water_heater.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,32 +80,49 @@ def __init__(self, data: BSBLanData) -> None:
# Initialize available attribute to resolve multiple inheritance conflict
self._attr_available = True

# Set temperature limits based on device capabilities from slow coordinator
@property
@override
def min_temp(self) -> float:
"""Return the minimum temperature.

Derived from the slow-coordinator DHW config, which may still be
pending when the platform is set up. Falls back to the default until
the config becomes available.
"""
dhw_config = (
data.slow_coordinator.data.dhw_config
if data.slow_coordinator.data
self.slow_coordinator.data.dhw_config
if self.slow_coordinator.data
else None
)

# For min_temp: Use reduced_setpoint from config data (slow polling)
if (
dhw_config is not None
and dhw_config.reduced_setpoint is not None
and dhw_config.reduced_setpoint.value is not None
):
self._attr_min_temp = dhw_config.reduced_setpoint.value
else:
self._attr_min_temp = 10.0 # Default minimum
return dhw_config.reduced_setpoint.value
return 10.0 # Default minimum

@property
@override
def max_temp(self) -> float:
"""Return the maximum temperature.

# For max_temp: Use nominal_setpoint_max from config data (slow polling)
Derived from the slow-coordinator DHW config, which may still be
pending when the platform is set up. Falls back to the default until
the config becomes available.
"""
dhw_config = (
self.slow_coordinator.data.dhw_config
if self.slow_coordinator.data
else None
)
if (
dhw_config is not None
and dhw_config.nominal_setpoint_max is not None
and dhw_config.nominal_setpoint_max.value is not None
):
self._attr_max_temp = dhw_config.nominal_setpoint_max.value
else:
self._attr_max_temp = 65.0 # Default maximum
return dhw_config.nominal_setpoint_max.value
return 65.0 # Default maximum

@property
def _dhw(self) -> HotWaterState:
Expand Down
2 changes: 1 addition & 1 deletion homeassistant/components/cloud/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@
"integration_type": "system",
"iot_class": "cloud_push",
"loggers": ["acme", "hass_nabucasa", "snitun"],
"requirements": ["hass-nabucasa==2.2.0", "openai==2.21.0"],
"requirements": ["hass-nabucasa==2.2.0", "openai==2.45.0"],
"single_config_entry": true
}
7 changes: 6 additions & 1 deletion homeassistant/components/lamarzocco/config_flow.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

from aiohttp import ClientSession
from pylamarzocco import LaMarzoccoCloudClient
from pylamarzocco.const import DeviceType
from pylamarzocco.exceptions import AuthFail, RequestNotSuccessful
from pylamarzocco.models import Thing
from pylamarzocco.util import InstallationKey, generate_installation_key
Expand Down Expand Up @@ -105,7 +106,11 @@ async def async_step_user(
_LOGGER.error("Error connecting to server: %s", exc)
errors["base"] = "cannot_connect"
else:
self._things = {thing.serial_number: thing for thing in things}
self._things = {
thing.serial_number: thing
for thing in things
if thing.type is DeviceType.MACHINE
}
if not self._things:
errors["base"] = "no_machines"

Expand Down
2 changes: 1 addition & 1 deletion homeassistant/components/llama_cpp/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
"integration_type": "service",
"iot_class": "local_polling",
"quality_scale": "bronze",
"requirements": ["openai==2.21.0"]
"requirements": ["openai==2.45.0"]
}
2 changes: 1 addition & 1 deletion homeassistant/components/music_assistant/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@
"iot_class": "local_push",
"loggers": ["music_assistant"],
"quality_scale": "bronze",
"requirements": ["music-assistant-client==1.3.6"],
"requirements": ["music-assistant-client==1.4.3"],
"zeroconf": ["_mass._tcp.local."]
}
2 changes: 1 addition & 1 deletion homeassistant/components/open_router/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
"integration_type": "service",
"iot_class": "cloud_polling",
"quality_scale": "bronze",
"requirements": ["openai==2.21.0", "python-open-router==0.3.3"]
"requirements": ["openai==2.45.0", "python-open-router==0.3.3"]
}
2 changes: 1 addition & 1 deletion homeassistant/components/openai_conversation/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
"integration_type": "service",
"iot_class": "cloud_polling",
"quality_scale": "bronze",
"requirements": ["openai==2.21.0"]
"requirements": ["openai==2.45.0"]
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
"integration_type": "service",
"iot_class": "cloud_polling",
"quality_scale": "silver",
"requirements": ["openai==2.21.0"]
"requirements": ["openai==2.45.0"]
}
78 changes: 28 additions & 50 deletions homeassistant/components/permobil/__init__.py
Original file line number Diff line number Diff line change
@@ -1,59 +1,37 @@
"""The MyPermobil integration."""

import logging

from mypermobil import MyPermobil, MyPermobilClientException

from homeassistant.const import (
CONF_CODE,
CONF_EMAIL,
CONF_REGION,
CONF_TOKEN,
CONF_TTL,
Platform,
)
from homeassistant.config_entries import ConfigEntry
from homeassistant.core import HomeAssistant
from homeassistant.exceptions import ConfigEntryAuthFailed
from homeassistant.helpers.aiohttp_client import async_get_clientsession

from .const import APPLICATION
from .coordinator import MyPermobilCoordinator, PermobilConfigEntry

PLATFORMS: list[Platform] = [Platform.BINARY_SENSOR, Platform.SENSOR]

_LOGGER = logging.getLogger(__name__)


async def async_setup_entry(hass: HomeAssistant, entry: PermobilConfigEntry) -> bool:
"""Set up MyPermobil from a config entry."""

# create the API object from the config and save it in hass
session = async_get_clientsession(hass)
p_api = MyPermobil(
application=APPLICATION,
session=session,
email=entry.data[CONF_EMAIL],
region=entry.data[CONF_REGION],
code=entry.data[CONF_CODE],
token=entry.data[CONF_TOKEN],
expiration_date=entry.data[CONF_TTL],
from homeassistant.helpers import issue_registry as ir

DOMAIN = "permobil"


async def async_setup_entry(hass: HomeAssistant, _: ConfigEntry) -> bool:
"""Set up config entry."""
ir.async_create_issue(
hass,
DOMAIN,
DOMAIN,
is_fixable=False,
severity=ir.IssueSeverity.ERROR,
translation_key="integration_removed",
translation_placeholders={
"entries": "/config/integrations/integration/permobil",
},
)
try:
p_api.self_authenticate()
except MyPermobilClientException as err:
_LOGGER.error("Error authenticating %s", err)
raise ConfigEntryAuthFailed(f"Config error for {p_api.email}") from err

# create the coordinator with the API object
coordinator = MyPermobilCoordinator(hass, entry, p_api)
await coordinator.async_config_entry_first_refresh()
return True

entry.runtime_data = coordinator
await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)

async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Unload a config entry."""
return True


async def async_unload_entry(hass: HomeAssistant, entry: PermobilConfigEntry) -> bool:
"""Unload a config entry."""
return await hass.config_entries.async_unload_platforms(entry, PLATFORMS)
async def async_remove_entry(hass: HomeAssistant, entry: ConfigEntry) -> None:
"""Remove a config entry."""
if not hass.config_entries.async_loaded_entries(DOMAIN):
ir.async_delete_issue(hass, DOMAIN, DOMAIN)
# Remove any remaining disabled or ignored entries
for _entry in hass.config_entries.async_entries(DOMAIN):
hass.async_create_task(hass.config_entries.async_remove(_entry.entry_id))
70 changes: 0 additions & 70 deletions homeassistant/components/permobil/binary_sensor.py

This file was deleted.

Loading
Loading