Commit graph

78 commits

Author SHA1 Message Date
Robert Resch
380974eed4
Remove hassio from ALLOWED_USED_COMPONENTS and move some functions to helper (#127228)
* Remove hassio from ALLOWED_USED_COMPONENTS

* Move HassioServiceInfo to helpers.service_info

* Deprecate moved functions

* Add note about deprecation

* Fix tests

* Implement suggestion

* Typo

* Update pyproject.toml

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>

---------

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2024-10-30 12:43:41 +01:00
epenet
646f457637
Add missing translation string in otbr (#127909) 2024-10-08 09:00:45 +02:00
Mike Degatano
97d0d91d2c
Use aiohasupervisor for addon info calls (#125926)
* Use aiohasupervisor for addon info calls

* Fix issue/repair tests in supervisor

* Fixes from feedback
2024-09-17 23:22:35 +02:00
Erik Montnemery
e2d84f9a58
Add support for multiple otbr config entries (#124289)
* Add support for multiple otbr config entries

* Fix test

* Drop useless fixture

* Address review comments

* Change unique id from xa to id

* Improve error text

* Store data in ConfigEntry.runtime_data

* Remove useless function
2024-08-27 19:07:35 +02:00
Erik Montnemery
d3deaa6a82
Improve otbr error handling (#124277) 2024-08-20 10:33:02 +02:00
Erik Montnemery
b31c6012ae
Use HassKey in otbr (#124240) 2024-08-20 08:16:59 +02:00
Erik Montnemery
50f3c891fa
Prepare otbr.silabs_multiprotocol for multiple config entries (#124219)
* Prepare otbr.silabs_multiprotocol for multiple config entries

* Simplify
2024-08-19 17:30:48 +02:00
Erik Montnemery
110ee9ff35
Strip trailing / from OTBR url (#124223) 2024-08-19 16:06:20 +02:00
Erik Montnemery
96edaebdd3
Remove unused function otbr.async_get_active_dataset_tlvs (#124210) 2024-08-19 13:15:50 +02:00
Erik Montnemery
054242ff0f
Require specifying extended address in otbr WS API calls (#108282)
Co-authored-by: Stefan Agner <stefan@agner.ch>
2024-07-17 09:04:54 +02:00
Marc Mueller
c41962455e
Use PEP 695 for decorator typing (2) (#117639) 2024-05-17 16:31:01 +02:00
puddly
fc34453caa
Support the Home Assistant Connect ZBT-1 (#114213) 2024-03-27 18:20:48 +01:00
Marc Mueller
988c71ecc5
Add empty line after module docstring [n-q] (#112702) 2024-03-08 15:04:07 +01:00
Erik Montnemery
e0c1feb22c
Migrate integrations n-r to generic flowhandler (#111864) 2024-02-29 20:09:01 +01:00
J. Nick Koston
5267e4f5db
Fix race in otbr config flow (#111044)
* fix otbr

* Update homeassistant/components/otbr/config_flow.py

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>

* unique ids should not change

* handle missing unique id

* handle missing unique id

---------

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2024-02-21 22:02:44 -05:00
Erik Montnemery
b5f049b84c
Bump python-otbr-api to 2.6.0 (#109823) 2024-02-06 21:14:45 +02:00
Marc Mueller
438d3b01b9
Use builtin TimeoutError [o-s] (#109682) 2024-02-05 12:14:37 +01:00
Erik Montnemery
fcfacaaabd
Store preferred border agent extended address for each thread dataset (#109065) 2024-01-31 00:57:46 +01:00
Erik Montnemery
823f268054
Randomize thread network names (#108302)
* Randomize thread network names

* Use PAN ID as network name suffix

* Apply suggestions from code review

Co-authored-by: Stefan Agner <stefan@agner.ch>

* Update tests

* Format code

* Change format of network name again

---------

Co-authored-by: Stefan Agner <stefan@agner.ch>
2024-01-23 22:58:28 +01:00
Ville Skyttä
24b1e01d71
Update Ruff to 0.1.8, avoid linter/formatter conflicts (#106080)
* Disable Ruff rules that may conflict with the formatter

* Upgrade Ruff to 0.1.8

- https://github.com/astral-sh/ruff/releases/tag/v0.1.7
- https://github.com/astral-sh/ruff/releases/tag/v0.1.8

* Format with Ruff 0.1.8
2023-12-20 23:55:09 +01:00
puddly
c8ef3f9393
Automatic migration from multi-PAN back to Zigbee firmware (#93831)
* Initial implementation of migration back to Zigbee firmware

* Fix typo in `BACKUP_RETRIES` constant name

* Name potentially long-running tasks

* Add an explicit timeout to `_async_wait_until_addon_state`

* Guard against the addon not being installed when uninstalling

* Do not launch the progress flow unless the addon is being installed

* Use a separate translation key for confirmation before disabling multi-PAN

* Disable the bellows UART thread within the ZHA config flow radio manager

* Enhance config flow progress keys for flasher addon installation

* Allow `zha.async_unload_entry` to succeed when ZHA is not loaded

* Do not endlessly spawn task when uninstalling addon synchronously

* Include `uninstall_addon.data.*` in SkyConnect and Yellow translations

* Make `homeassistant_hardware` unit tests pass

* Fix SkyConnect unit test USB mock

* Fix unit tests in related integrations

* Use a separate constant for connection retrying

* Unit test ZHA migration from multi-PAN

* Test ZHA multi-PAN migration helper changes

* Fix flaky SkyConnect unit test being affected by system USB devices

* Unit test the synchronous addon uninstall helper

* Test failure when flasher addon is already running

* Test failure where flasher addon fails to install

* Test ZHA migration failures

* Rename `get_addon_manager` to `get_multiprotocol_addon_manager`

* Remove stray "addon uninstall" comment

* Use better variable names for the two addon managers

* Remove extraneous `self.install_task = None`

* Use the addon manager's `addon_name` instead of constants

* Migrate synchronous addon operations into a new class

* Remove wrapper functions with `finally` clause

* Use a more descriptive error message when the flasher addon is stalled

* Fix existing unit tests

* Remove `wait_until_done`

* Fully replace all addon name constants with those from managers

* Fix OTBR breakage

* Simplify `is_hassio` mocking

* Add missing tests for `check_multi_pan_addon`

* Add missing tests for `multi_pan_addon_using_device`

* Use `waiting` instead of `sync` in class name and methods
2023-08-28 17:26:34 -04:00
Erik Montnemery
94ad4786c3
Include extended address in response to WS otbr/info (#98440) 2023-08-15 09:48:29 +02:00
Erik Montnemery
71b92265af
Include border agent id in response to WS otbr/info (#98394)
* Include border agent id in response to WS otbr/info

* Assert border agent ID is not None
2023-08-15 09:17:47 +02:00
Erik Montnemery
6c7f50b5b2
Simplify error handling in otbr async_setup_entry (#98395)
* Simplify error handling in otbr async_setup_entry

* Create issue if the OTBR does not support border agent ID

* Update test

* Improve test coverage

* Catch the right exception
2023-08-15 08:27:50 +02:00
Erik Montnemery
6294014fcd
Bump python-otbr-api to 2.5.0 (#98403) 2023-08-14 20:09:50 +02:00
Erik Montnemery
e0fd83daab
Store preferred border agent ID for each thread dataset (#98384) 2023-08-14 15:47:18 +02:00
Erik Montnemery
318b8adbed
Set preferred router when importing OTBR dataset (#98379) 2023-08-14 13:40:32 +02:00
Erik Montnemery
4dd102f818
Bump python-otbr-api to 2.4.0 (#98376) 2023-08-14 11:33:07 +02:00
Erik Montnemery
1ee0c907b0
Improve OTBR factory reset (#98017)
Co-authored-by: Stefan Agner <stefan@agner.ch>
2023-08-08 11:38:01 +02:00
Erik Montnemery
0dc5875cbd
Bump python-otbr-api to 2.3.0 (#97185) 2023-07-25 09:22:57 +02:00
Erik Montnemery
b53eae2846
Add WS command for changing thread channels (#94525) 2023-07-19 10:48:32 +02:00
Erik Montnemery
c79fa87a7f
Fix check for HA Yellow radio in otbr config flow (#96789) 2023-07-17 22:21:52 +02:00
Erik Montnemery
863b36c0c3
Include addon name in otbr config entry title (#96786) 2023-07-17 21:26:15 +02:00
Erik Montnemery
8559af8232
Remove extra otbr config entries (#96785) 2023-07-17 21:23:20 +02:00
Erik Montnemery
1e3fdcc4d1
Prevent otbr creating multiple config entries (#96783) 2023-07-17 21:22:50 +02:00
Erik Montnemery
23d15850da
Use addon name as title in otbr hassio flow (#87081)
* Use addon name as title in otbr hassio flow

* Address review comments
2023-06-08 23:04:12 +02:00
Erik Montnemery
1fa2fb4639
Fix OTBR reset (#94157) 2023-06-07 18:42:40 +02:00
Erik Montnemery
15e5cf01bb
Add silabs_multiprotocol platform (#92904)
* Add silabs_multiprotocol platform

* Add new files

* Add ZHA tests

* Prevent ZHA from creating database during tests

* Add delay parameter to async_change_channel

* Add the updated dataset to the dataset store

* Allow MultipanProtocol.async_change_channel to return a task

* Notify user about the duration of migration

* Update tests
2023-06-01 12:32:14 +02:00
Erik Montnemery
16d8c8d4d5
Bump python-otbr-api to 2.1.0 (#93790)
* Bump python-otbr-api to 2.1.0

* Fix tests
2023-05-30 12:47:46 +02:00
Erik Montnemery
901624ad6f
Adapt otbr to upstream openthread REST API changes (#93544)
* Adapt otbr to upstream openthread REST API changes

* Bump python-otbr-api to 2.0.0
2023-05-30 10:11:21 +02:00
Erik Montnemery
9c01ea003c
Add empty config schema to integrations i-o (#93698) 2023-05-29 20:58:00 +02:00
Erik Montnemery
63f3767a29
Include UUID in hassio discovery data (#91970) 2023-04-25 09:48:47 +02:00
Erik Montnemery
bff5b75377
Adjust OTBR channel conflict URL (#90847) 2023-04-05 16:06:00 +02:00
Erik Montnemery
c3091fad4c
Raise repair issue if OTBR and ZHA are on different channels (#90494)
* Raise repair issue if OTBR and ZHA are on different channels

* Update issues after creating or setting dataset

* Explain impact

* Add link to documentation, adjust language

* Update homeassistant/components/otbr/strings.json

---------

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2023-04-03 13:02:10 -04:00
Erik Montnemery
3c3860c923
Make OTBR use same channel as ZHA (#88546) 2023-03-28 12:34:25 +02:00
Erik Montnemery
130c8ea5f5
Update OTRB config entry if REST API port has changed (#90101)
* Update OTRB config entry if REST API port has changed

* Improve test coverage
2023-03-22 14:03:39 +01:00
Erik Montnemery
85e0177195
Add WS command for connecting OTBR to a known Thread network (#89692)
* Add WS command for connecting OTBR to a known Thread network

* Add test
2023-03-14 15:28:06 +01:00
Erik Montnemery
2f4e9c8ef3
Use otbr domain as dataset source (#89653) 2023-03-13 20:56:09 -04:00
Erik Montnemery
d422b0dcc2
Make OTBR add newly created dataset to thread credential store (#89645) 2023-03-13 14:09:09 -04:00
Erik Montnemery
0f2abe7f25
Bump python-otbr-api to 1.0.9 (#89637) 2023-03-13 15:52:36 +01:00