Update ruff to 0.12.0 (#147106)

This commit is contained in:
Marc Mueller
2025-06-19 20:39:09 +02:00
committed by GitHub
parent 73d0d87705
commit 2c13c70e12
96 changed files with 291 additions and 427 deletions

View File

@@ -452,11 +452,9 @@ def async_fire_mqtt_message(
# Local import to avoid processing MQTT modules when running a testcase
# which does not use MQTT.
# pylint: disable-next=import-outside-toplevel
from paho.mqtt.client import MQTTMessage
from paho.mqtt.client import MQTTMessage # noqa: PLC0415
# pylint: disable-next=import-outside-toplevel
from homeassistant.components.mqtt import MqttData
from homeassistant.components.mqtt import MqttData # noqa: PLC0415
if isinstance(payload, str):
payload = payload.encode("utf-8")
@@ -1736,8 +1734,7 @@ def async_get_persistent_notifications(
def async_mock_cloud_connection_status(hass: HomeAssistant, connected: bool) -> None:
"""Mock a signal the cloud disconnected."""
# pylint: disable-next=import-outside-toplevel
from homeassistant.components.cloud import (
from homeassistant.components.cloud import ( # noqa: PLC0415
SIGNAL_CLOUD_CONNECTION_STATE,
CloudConnectionState,
)