From b9effc67bd623f7d9fcd38c1cbbc63ae136ee6ef Mon Sep 17 00:00:00 2001 From: Simone Chemelli Date: Sat, 18 Jul 2026 20:45:15 +0200 Subject: [PATCH] Remove redundant var from Shelly (#176780) --- homeassistant/components/shelly/ble_provisioning.py | 7 +++---- homeassistant/components/shelly/update.py | 4 +--- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/homeassistant/components/shelly/ble_provisioning.py b/homeassistant/components/shelly/ble_provisioning.py index dc3eceecf87d..e37c63ac09fa 100644 --- a/homeassistant/components/shelly/ble_provisioning.py +++ b/homeassistant/components/shelly/ble_provisioning.py @@ -2,13 +2,12 @@ import asyncio from dataclasses import dataclass, field -import logging from homeassistant.core import HomeAssistant, callback from homeassistant.helpers.device_registry import format_mac from homeassistant.util.hass_dict import HassKey -_LOGGER = logging.getLogger(__name__) +from .const import LOGGER @dataclass @@ -62,7 +61,7 @@ def async_register_zeroconf_discovery( state = registry.get(normalized_mac) if not state: - _LOGGER.debug( + LOGGER.debug( "No BLE provisioning state found for %s (host %s, port %s)", normalized_mac, host, @@ -70,7 +69,7 @@ def async_register_zeroconf_discovery( ) return - _LOGGER.debug( + LOGGER.debug( "Registering zeroconf discovery for %s at %s:%s (replacing previous)", normalized_mac, host, diff --git a/homeassistant/components/shelly/update.py b/homeassistant/components/shelly/update.py index 304a90d19ae7..ca570a80b526 100644 --- a/homeassistant/components/shelly/update.py +++ b/homeassistant/components/shelly/update.py @@ -2,7 +2,6 @@ from collections.abc import Callable from dataclasses import dataclass -import logging from typing import Any, Final, cast, override from aioshelly.const import RPC_GENERATIONS @@ -25,6 +24,7 @@ from homeassistant.helpers.restore_state import RestoreEntity from .const import ( CONF_SLEEP_PERIOD, DOMAIN, + LOGGER, OTA_BEGIN, OTA_ERROR, OTA_PROGRESS, @@ -42,8 +42,6 @@ from .entity import ( ) from .utils import get_device_entry_gen, get_release_url -LOGGER = logging.getLogger(__name__) - PARALLEL_UPDATES = 0