* Add sensors for second radio
* Add test for zigbee2 sensor
* Update homeassistant/components/smlight/sensor.py
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* drop useless replace
* Fix test failure
* Fix code coverage in config flow
* Update homeassistant/components/smlight/sensor.py
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* fix conversion of iterator to list
* Remove assert on radios
* simplify handling of radios further
---------
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>
* Reapply "Add support for subentries to config entries" (#133470) (#136061)
* Reapply "Add support for subentries to config entries" (#133470)
This reverts commit ecb3bf79f32a2e25d141ff467e5958826ed9fc3a.
* Update test snapshot
* Add config subentry support to device registry (#128157)
* Add config subentry support to device registry
* Apply suggestions from code review
* Update syrupy serializer
* Update snapshots
* Address review comments
* Allow a device to be connected to no or a single subentry of a config entry
* Update snapshots
* Revert "Allow a device to be connected to no or a single subentry of a config entry"
This reverts commit ec6f613151cb4a806b7961033c004b71b76510c2.
* Update test snapshots
* Bump release version in comments
* Rename config_subentries to config_entries_subentries
* Add config subentry support to entity registry (#128155)
* Add config subentry support to entity registry
* Update syrupy serializer
* Update snapshots
* Update snapshots
* Accept suggested changes
* Clean registries when removing subentry (#136671)
* Clean up registries when removing subentry
* Update tests
* Clean up subentries from deleted devices when removing config entry (#136669)
* Clean up subentries from deleted devices when removing config entry
* Move
* Add config subentry support to entity platform (#128161)
* Add config subentry support to entity platform
* Rename subentry_id to config_subentry_id
* Store subentry type in subentry (#136687)
* Add reconfigure support to config subentries (#133353)
* Add reconfigure support to config subentries
* Update test
* Minor adjustment
* Rename supported_subentry_flows to supported_subentry_types
* Address review comments
* Add subentry support to kitchen sink (#136755)
* Add subentry support to kitchen sink
* Add subentry reconfigure support to kitchen_sink
* Update kitchen_sink tests with subentry type stored in config entry
* Update kitchen_sink
* Update kitchen_sink
* Adjust kitchen sink tests
* Fix hassfest
* Apply suggestions from code review
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* Improve docstrings and strings.json
---------
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* Update snapshots
* Update snapshots
* Update snapshots
* Update snapshots
* Update snapshots
* Update snapshots
* Update snapshots
---------
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* Add get_radio helper function
This is defined here primarily for use in simplifying otherwise repetitive
logic in the lambdas for entity descriptions.
* Get firmware manifests for second radio
* Create optional update entity for radio 2
* Add info fixture for SLZB-MR1
* Test for firmware updates of second radio
* Remove use of entity description creating entities
* Add idx to lambda functions
* Add latest_version lambda to ED
* Use Single zb_update description
* test radio2 update
* device type heading for release notes
* fix failing no internet test
* update release note tests
* assert radios
* fix return type installed_version
* refactor latest_version code
* update listener
* Dont create update entities for legacy firmware that can't upgrade
* Address review comments for update listener
* Abort config flow if device is not yet supported
* Abort on user step for unsupported device
* Add string for unsupported device
* fix tests due to extra get_info calls
* add tests for unsupported devices to abort flow
* Add button for router reconnect
* strings for router reconnect
* remove stale router reconnect if zigbee is not running router firmware
* Add tests for router reconnect button
* Update homeassistant/components/smlight/strings.json
And fix associated tests
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Make router button entity dynamic
* adjust test for dynamic runtime removal
* drop if statements from tests
---------
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Dont launch SSE client for core firmware 0.9.9
* Dont offer updates on core firmware 0.9.9
* Add correct firmware done event for legacy v2 firmware
* test update legacy v2 firmware
* Dont raise issue for firmware v2
* Add vpn_status sensor
* update test fixures with new attributes
* Add vpn enabled switch
vpn strings
* Add vpn switch to test
* update snapshots
* Add vpn status to disabled by default test
* Add internet sensor updated by events
* Strings for internet sensor
* Update binary_sensor snapshot with internet sensor
* Add test for internet sensor
* Address review comments
---------
Co-authored-by: Tim Lunn <tim@feathertop.org>
* Move entity category to class
* improve type hints
* Regenerate sensor snapshots to remove some invalid entries
* Add info sensors that display various device settings/modes
* Add strings for info sensors
* Update sensor snapshot with new sensors
* Use StateType
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Use icon translations
* statetype
* drop ip sensor
* Lookup enum values before translating
* entities use options
* update options strings
strings
* lookup values from options
* update sensor snapshot
---------
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Update Info fixture with new fields from pysmlight 0.0.14
* Create repair if device is running unsupported firmware
* Add test for legacy firmware info
* Add strings for repair issue
* Add reauth flow for smlight integration
* add strings for reauth
* trigger reauth flow on authentication errors
* Add tests for reauth flow
* test for update failed on auth error
* restore name title placeholder
* raise config entry error to trigger reauth
* Add test for reauth triggered at startup
---------
Co-authored-by: Tim Lunn <tim@feathertop.org>
* Add uptime sensor as derived sensor class
* Add strings for uptime sensors
* Update sensor tests to include uptime sensors
* test zigbee uptime when disconnected
* Initial SMLIGHT integration
Signed-off-by: Tim Lunn <tl@smlight.tech>
* Generated content
Signed-off-by: Tim Lunn <tl@smlight.tech>
* Cleanup LOGGING
* Use runtime data
* Call super first
* coordinator instance attributes
* Move coordinatorEntity and attr to base class
* cleanup sensors
* update strings to use sentence case
* Improve reauth flow on incorrect credentials
* Use fixture for config_flow tests and test to completion
* Split uptime hndling into a new uptime sensor entity
* Drop server side events and internet callback
will bring this back with binary sensor Platform
* consolidate coordinator setup
* entity always include connections
* get_hostname tweak
* Add tests for init, coordinator and sensor
* Use custom type SmConfigEntry
* update sensor snapshot
* Drop reauth flow for later PR
* Use _async_setup for initial setup
* drop internet to be set later
* sensor fixes
* config flow re
* typing fixes
* Bump pysmlight dependency to 0.0.12
* dont trigger invalid auth message when first loading auth step
* Merge uptime sensors back into main sensor class
* clarify uptime handling
* Apply suggestions from code review
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* address review comments
* pass host as parameter to the dataCoordinator
* drop uptime sensors for a later PR
* update sensor test snapshot
* move coordinator unique_id to _async_setup
* fix CI
* Apply suggestions from code review
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* drop invalid_auth test tag
* use snapshot_platform, update fixtures
* Finish all tests with abort or create entry
* drop coordinator tests and remove hostname support
* add test for update failure on connection error
* use freezer for update_failed test
* fix pysmlight imports
---------
Signed-off-by: Tim Lunn <tl@smlight.tech>
Co-authored-by: Tim Lunn <tim@feathertop.org>
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>