Bump led-ble to 0.8.3 (#78188)
* Bump led-ble to 0.8.0 Fixes setup when the previous shutdown was not clean and the device is still connected * bump again * bump again * bump again
This commit is contained in:
parent
a877c8030f
commit
c406e4defe
5 changed files with 9 additions and 7 deletions
|
@ -6,7 +6,7 @@ from datetime import timedelta
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
import async_timeout
|
import async_timeout
|
||||||
from led_ble import BLEAK_EXCEPTIONS, LEDBLE
|
from led_ble import BLEAK_EXCEPTIONS, LEDBLE, get_device
|
||||||
|
|
||||||
from homeassistant.components import bluetooth
|
from homeassistant.components import bluetooth
|
||||||
from homeassistant.components.bluetooth.match import ADDRESS, BluetoothCallbackMatcher
|
from homeassistant.components.bluetooth.match import ADDRESS, BluetoothCallbackMatcher
|
||||||
|
@ -27,7 +27,9 @@ _LOGGER = logging.getLogger(__name__)
|
||||||
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
||||||
"""Set up LED BLE from a config entry."""
|
"""Set up LED BLE from a config entry."""
|
||||||
address: str = entry.data[CONF_ADDRESS]
|
address: str = entry.data[CONF_ADDRESS]
|
||||||
ble_device = bluetooth.async_ble_device_from_address(hass, address.upper(), True)
|
ble_device = bluetooth.async_ble_device_from_address(
|
||||||
|
hass, address.upper(), True
|
||||||
|
) or await get_device(address)
|
||||||
if not ble_device:
|
if not ble_device:
|
||||||
raise ConfigEntryNotReady(
|
raise ConfigEntryNotReady(
|
||||||
f"Could not find LED BLE device with address {address}"
|
f"Could not find LED BLE device with address {address}"
|
||||||
|
|
|
@ -48,12 +48,12 @@ class LEDBLEEntity(CoordinatorEntity, LightEntity):
|
||||||
"""Initialize an ledble light."""
|
"""Initialize an ledble light."""
|
||||||
super().__init__(coordinator)
|
super().__init__(coordinator)
|
||||||
self._device = device
|
self._device = device
|
||||||
self._attr_unique_id = device._address
|
self._attr_unique_id = device.address
|
||||||
self._attr_device_info = DeviceInfo(
|
self._attr_device_info = DeviceInfo(
|
||||||
name=name,
|
name=name,
|
||||||
model=hex(device.model_num),
|
model=hex(device.model_num),
|
||||||
sw_version=hex(device.version_num),
|
sw_version=hex(device.version_num),
|
||||||
connections={(dr.CONNECTION_BLUETOOTH, device._address)},
|
connections={(dr.CONNECTION_BLUETOOTH, device.address)},
|
||||||
)
|
)
|
||||||
self._async_update_attrs()
|
self._async_update_attrs()
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
"name": "LED BLE",
|
"name": "LED BLE",
|
||||||
"config_flow": true,
|
"config_flow": true,
|
||||||
"documentation": "https://www.home-assistant.io/integrations/ble_ble",
|
"documentation": "https://www.home-assistant.io/integrations/ble_ble",
|
||||||
"requirements": ["led-ble==0.7.1"],
|
"requirements": ["led-ble==0.8.3"],
|
||||||
"dependencies": ["bluetooth"],
|
"dependencies": ["bluetooth"],
|
||||||
"codeowners": ["@bdraco"],
|
"codeowners": ["@bdraco"],
|
||||||
"bluetooth": [
|
"bluetooth": [
|
||||||
|
|
|
@ -968,7 +968,7 @@ lakeside==0.12
|
||||||
laundrify_aio==1.1.2
|
laundrify_aio==1.1.2
|
||||||
|
|
||||||
# homeassistant.components.led_ble
|
# homeassistant.components.led_ble
|
||||||
led-ble==0.7.1
|
led-ble==0.8.3
|
||||||
|
|
||||||
# homeassistant.components.foscam
|
# homeassistant.components.foscam
|
||||||
libpyfoscam==1.0
|
libpyfoscam==1.0
|
||||||
|
|
|
@ -706,7 +706,7 @@ lacrosse-view==0.0.9
|
||||||
laundrify_aio==1.1.2
|
laundrify_aio==1.1.2
|
||||||
|
|
||||||
# homeassistant.components.led_ble
|
# homeassistant.components.led_ble
|
||||||
led-ble==0.7.1
|
led-ble==0.8.3
|
||||||
|
|
||||||
# homeassistant.components.foscam
|
# homeassistant.components.foscam
|
||||||
libpyfoscam==1.0
|
libpyfoscam==1.0
|
||||||
|
|
Loading…
Add table
Reference in a new issue