Commit Graph

11505 Commits (9ab56bd5c846d42ca32c885072d87c0f12932ea2)

Author SHA1 Message Date
Michael Chisholm 3c15fe8587
Add media browser support to dlna_dmr (#66425) 2022-02-19 21:07:38 -08:00
jan iversen 6a7872fc1b
Remove async_setup_component() from tests (#66905) 2022-02-19 21:00:14 -08:00
Allen Porter f3add292d5
Update nest climate set_temperature to allow hvac_mode (#66909) 2022-02-19 20:57:29 -08:00
J. Nick Koston e9ca7c2516
Add support for WiZ diagnostics (#66817) 2022-02-19 20:54:12 -08:00
René Klomp 496583bca5
Prefix sma sensor name (#65234)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2022-02-19 20:27:06 +01:00
James Taylor 27038fda27
Update RSS feed template (#62966) 2022-02-19 13:26:42 -06:00
G Johansson 6464ab8356
Bump pysensibo to 1.0.4 (#66886) 2022-02-19 12:00:49 -06:00
Keilin Bickar d59dbbe859
Create button entities for SleepIQ (#66849) 2022-02-19 11:54:52 -06:00
Klaas Schoute 6c2d6fde66
Add Pure Energie integration (#66846) 2022-02-19 17:53:25 +01:00
J. Nick Koston 8f0b6eac41
Fix yeelight config flow ip update and timeout (#66883) 2022-02-19 17:24:50 +01:00
J. Nick Koston a18d4c51ff
Ensure dhcp can still discover new devices from device trackers (#66822)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-19 09:01:34 -06:00
Simon Hansen 52ca1a3d47
Code enhancements for ISS (#66813)
* Code enhancements for ISS

* Assert options
2022-02-19 11:38:10 +01:00
Raman Gupta 4ff1f5c788
Create zwave_js ping button at the right time (#66848)
* Create zwave_js ping button at the right time

* fix tests
2022-02-19 11:16:14 +01:00
Paulus Schoutsen 1bbc1f5f55
Validate in split_entity_id (#66835) 2022-02-18 16:11:17 -08:00
J. Nick Koston 3bf2be1765
Startup with an emergency self signed cert if the ssl certificate cannot be loaded (#66707) 2022-02-18 16:08:26 -08:00
Erik Montnemery ec67dcb620
Add support for validating and serializing selectors (#66565)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-02-18 14:24:08 -08:00
epenet 3aa18ea5d8
Add installed apps to samsungtv sources (#66752)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-18 13:33:49 -08:00
Paulus Schoutsen d3bb622a3c
Bump hass-nabucasa to 0.53.0 (#66826) 2022-02-18 11:53:02 -08:00
Keilin Bickar a367d2be40
Modernize Sleepiq and add new entities (#66336)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-02-18 12:50:44 -06:00
Kevin Stillhammer beb30a1ff1
Add google_travel_time sensor tests (#66568)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2022-02-18 10:21:28 -08:00
Erik Montnemery f1648960f5
Improve cleanup of Google Cast entities (#66801) 2022-02-18 15:05:14 +01:00
Martin Hjelmare 56d45c49e9
Clean webostv notify (#66803)
* Replace conf with attr

* Test notify service without data parameter

* Clean kwargs access

* Replace icon constant

* Use data from notify
2022-02-18 15:03:05 +02:00
Erik Montnemery ba6d1976df
Improve MQTT device removal (#66766)
* Improve MQTT device removal

* Update homeassistant/components/mqtt/mixins.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Adjust tests

* Improve test coverage

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-18 13:45:25 +01:00
Erik Montnemery 2abcd7cd94
Correct state restoring for MQTT temperature sensors (#66741)
* Correct state restoring for MQTT temperature sensors

* Adjust test

* Adjust test
2022-02-18 11:35:44 +01:00
Teemu R 483545eeaa
Bump python-songpal dependency to 0.14 (#66769)
* Bump python-songpal dependency to 0.14

* Fix tests

* pip_check -1

Co-authored-by: Franck Nijhof <git@frenck.dev>
2022-02-18 11:31:46 +02:00
Erik Montnemery 98982c86e4
Add MQTT diagnostics (#66730)
* Add MQTT diagnostics

* Redact device tracker location

* Adjust tests

* Address comments from code review
2022-02-18 09:28:49 +01:00
Dave T 7e3d87a146
Increase helpers.frame test coverage (#65137)
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-02-18 00:05:38 -08:00
Franck Nijhof e26488b1ca
Add config flow to MJPEG IP Camera (#66607) 2022-02-18 00:03:41 -08:00
Raman Gupta 82ebb7047f
Bump zwave-js-server-python to 0.35.0 (#66785)
* Bump zwave-js-server-python to 0.35.0

* Remove support for new event type which should go in a separate PR
2022-02-18 02:36:27 -05:00
Allen Porter 58551ec66d
Update nest camera tests to use common test fixture (#66192) 2022-02-17 23:08:29 -08:00
J. Nick Koston 64277058b5
Ensure lutron caseta imports set the unique id (#66754) 2022-02-18 00:03:20 +01:00
epenet 8bf19655f1
Fix samsung mocks (#66765)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-17 13:04:48 -08:00
epenet 6d0a06c57a
Add type hints in samsungtv tests (#66632)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-17 12:47:58 -08:00
Tom dacc2b1ab0
Plugwise update Zigbee addressing fixture data to 64bits (#66761) 2022-02-17 20:58:06 +01:00
Shay Levy e79348f952
Fix webostv notify service (#66760) 2022-02-17 20:13:09 +01:00
Chris Talkington 9d5dc2ce24
Improve roku play media handling (#66429)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-02-17 10:19:01 -08:00
Tom f8d38a1025
Plugwise: Update fixtures (#66749) 2022-02-17 17:03:18 +01:00
Franck Nijhof 276fd4f42c
Add Python 3.10 to CI (#59729) 2022-02-17 14:58:24 +01:00
Franck Nijhof de24d00a1c
Use min/max/step from thermostat in Plugwise (#66618) 2022-02-17 14:11:47 +01:00
Jan Bouwhuis 83846bb5cc
MQTT climate preset_modes rework (#66062)
* MQTT climate preset_modes rework

* Set deprection date to 2022.9 (6 months)

* add valid_preset_mode_configuration for discovery

* Update deprecation date
2022-02-17 13:51:35 +01:00
Erik Montnemery 4236764fd5
Don't allow creating or updating input_select with duplicates (#66718)
* Don't allow creating or updating input_select with duplicates

* Simplify error message

* Improve error message
2022-02-17 13:11:49 +01:00
epenet a9aefb66b5
Add device info to samsungtv diagnostics (#66728)
* Add device-info to samsungtv diagnostics

* Adjust tests

Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-17 12:35:02 +01:00
Raman Gupta a1b81b2de4
Add inclusion state to zwave_js/network_status WS API cmd (#65398) 2022-02-17 11:38:20 +01:00
Erik Montnemery f89de613d9
Improve MQTT binary_sensor test (#66688) 2022-02-17 00:06:42 +01:00
Brett Adams bccfaceedb
Code Quality improvements for Aussie Broadband (#65408)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-16 23:38:05 +01:00
epenet 2687f61428
Fix slow samsungtv test (#66696) 2022-02-16 16:04:50 -06:00
Erik Montnemery eaf73318e1
Remove duplicated options from input_select (#66680) 2022-02-16 22:04:49 +01:00
epenet 0138caa277
Fix side_effect patching in samsungtv tests (#66651)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-16 12:40:11 -08:00
epenet 2d33e435b9
Fix token refresh in samsungtv (#66533) 2022-02-16 12:28:01 -08:00
Bram Kragten ef34f070ee
Allow metadata in service call data (#66672)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
Co-authored-by: Erik <erik@montnemery.com>
2022-02-16 21:13:36 +01:00
epenet 14e48bac3a
Fix SamsungTVWS mocking in samsungtv tests (#66650)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-16 12:13:11 -08:00
J. Nick Koston 0ec89ae5da
Teach _async_abort_entries_match about entry options (#66662) 2022-02-16 18:15:31 +01:00
Robert Svensson dd9b14d5c9
Add Button platform to deCONZ integration (#65700)
* Improve scene platform

* Add button platform, tests and fix tests affected by new entities existing

* Remove unnused property

* Bump dependency to v87
2022-02-16 17:55:30 +01:00
Bram Kragten a9390908ea
Keep TTS media browser params in identifier (#66663)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-02-16 08:54:57 -08:00
Paulus Schoutsen cd5b69d02e
Add Google local indicator (#66610) 2022-02-16 07:54:59 -08:00
Tobias Sauerwein 3d1cad9f67
Improve handling of cloud hook registration (#65664)
Signed-off-by: cgtobi <cgtobi@gmail.com>
2022-02-16 16:42:45 +01:00
Mike Fugate 0bd0b4766e
Refactor sleepiq as async with config flow (#64850)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-02-16 08:51:29 -06:00
Franck Nijhof 4051e2f518
Fix Plugwise auto HVAC mode (#66639)
* Fix Plugwise auto hvac mode

* Clean up set HVAC
2022-02-16 13:22:21 +01:00
Erik Montnemery dcb3fc49c9
Include changes in EVENT_DEVICE_REGISTRY_UPDATED (#66641) 2022-02-16 12:29:08 +01:00
J. Nick Koston e0cee22b8a
Switch ezviz to use integration discovery (#66579) 2022-02-16 12:07:36 +01:00
J. Nick Koston 38b9bea9a3
Switch tplink to use integration discovery (#66575) 2022-02-16 12:06:58 +01:00
epenet cf5652737a
Cleanup samsungtv tests (#66570)
* Drop unused init method

* Add type hints to media_player tests

* Adjust test_init

* Adjust media_player

* Add type hints to conftest

* Use Mock in test_media_player

* Use lowercase in test_init

* Use relative import in diagnostics

* Add type hints to config_flow

* Adjust coveragerc

* Make gethostbyname autouse

* Cleanup gethostbyname and remote fixtures

* Drop unused fixtures

* Undo type hints and usefixtures on media_player

* Undo type hints and usefixtures in test_init

* Undo type hints in conftest

* Undo usefixtures in test_config_flow

* Format

Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-16 09:29:52 +01:00
Marcel van der Veldt 8f4ec89be6
Bump aiohue to version 4.1.2 (#66609) 2022-02-15 17:26:13 -08:00
J. Nick Koston 99568b133f
Switch flux_led to use integration discovery (#66574) 2022-02-16 01:25:43 +01:00
J. Nick Koston 6ae2331805
Switch senseme to use integration discovery (#66576) 2022-02-16 00:47:01 +01:00
J. Nick Koston d79d775d92
Switch elkm1 to use integration discovery (#66572) 2022-02-15 23:18:55 +01:00
J. Nick Koston b28754e5fe
Switch steamist to use integration discovery (#66578) 2022-02-15 23:18:13 +01:00
J. Nick Koston d64ef2ba73
Deduplicate flux_led title and CONF_NAME (#66598) 2022-02-15 22:44:35 +01:00
J. Nick Koston f069a37f7d
Allow integrations to request dhcp discovery flows for registered devices (#66528) 2022-02-15 11:02:52 -06:00
J. Nick Koston 2b43293363
Switch unifiprotect to use integration discovery (#66569)
Backstory: https://github.com/home-assistant/core/pull/65752#discussion_r800068914
2022-02-15 17:02:33 +01:00
Joakim Sørensen 0d2712e436
Add binary_sensor to Version integration (#66539)
* Add binary_sensor to version integration

* Add test to check we not create for local

* Move _attr_icon to sensor

* Update homeassistant/components/version/binary_sensor.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-15 16:39:34 +01:00
epenet 52ebe58b14
Add tests for samsungtv diagnostics (#66563)
* Add tests for samsungtv diagnostics

* Adjust coveragerc

* Adjust type hints

Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-15 16:24:13 +02:00
Robert Svensson 1bc936ca8d
Improve Deconz sensors (#65259) 2022-02-15 08:32:56 +01:00
Allen Porter 572fa7d055
Update nest camera to pull still images from stream component (#66427)
* Update nest to use stream thumbnail when it exists

* Update nest camera to always pull still image from stream

Update nest camera to always pull the still iamge from the stream component,
removing the use of the separate ffmpeg call, and removing use of the nest event
image. Image for events can now be pulled using the media source APIs, rather
than relying on the camera snapshot.

* Simplify a comment

* Remove more unused variables

* Simplify comments, image, and test code

* Remove assertions for placeholder images
2022-02-14 21:45:09 -08:00
Brett Adams 6b6f50e28b
Bump pyaussiebb in Aussie Broadband (#65754)
Co-authored-by: Shay Levy <levyshay1@gmail.com>
2022-02-14 21:02:40 -06:00
Diogo Gomes b211a1faa7
Fix utility meter restore state (#66490)
* Address #63874

* avoid setting _last_period to None

* name is always set in discovery

* ValueError never happens only DecimalException

* async_tariff_change tracks state change - state machine will not pass a None

* test we only reset one utility_meter

* test corrupted restored state

* pretty sure _current_tariff doesn't change from init until here

* missing assert

* Revert "async_tariff_change tracks state change - state machine will not pass a None"

This reverts commit 24fc04a964.

* address review comment

* always a Decimal
2022-02-15 02:16:30 +01:00
Raman Gupta 152dbfd2fe
Add button entity to ping zwave_js node (#66129)
* Add button entity to ping zwave_js node

* Fix docstring

* Fix docstrings

* Fix and simplify tests

* Fix name

* Update homeassistant/components/zwave_js/button.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/zwave_js/services.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/zwave_js/button.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/zwave_js/button.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/zwave_js/button.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* review comments

* Update homeassistant/components/zwave_js/button.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/zwave_js/button.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Remove self.client line

* Add callback to remove entity

* Add extra dispatch signal on replacement

* Combine signals for valueless entities

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-14 15:38:22 -05:00
Raman Gupta 113c3149c4
Improve zwave_js device automation strings for config parameters (#66428)
* Improve zwave_js device automation strings for config parameters

* rename things to be more clear

* Match config file format
2022-02-14 15:14:02 -05:00
Simon Hansen 7cb0ce0eec
Move config option to OptionsFlow in iss (#65303)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2022-02-14 21:07:50 +01:00
Paulus Schoutsen 8456c6416e
Add a media source to TTS (#66483) 2022-02-14 08:54:12 -08:00
J. Nick Koston 013d227113
Ensure WiZ cleans up on shutdown and failed setup (#66520) 2022-02-14 17:32:34 +01:00
Paulus Schoutsen fec8c2ab82
Add support for MJPEG cameras to camera media source (#66499) 2022-02-14 17:04:19 +01:00
J. Nick Koston 63cb79ec29
Add support for setting the effect speed in WiZ (#66457) 2022-02-14 16:49:43 +01:00
J. Nick Koston 445ad1d592
Add test coverage for WiZ lights and switches (#66387) 2022-02-14 16:31:26 +01:00
Paulus Schoutsen 707f112f51
Improve raised exception consistency for media source (#66497) 2022-02-14 15:41:53 +01:00
Erik Montnemery 795d249c8c
Small improvement of cast test (#66513) 2022-02-14 15:06:33 +01:00
J. Nick Koston 00d7fdd274
Add WiZ occupancy sensor support (#66231) 2022-02-14 14:25:15 +01:00
Ryan Fleming 35b343de9e
Octoprint buttons (#66368) 2022-02-14 11:05:06 +01:00
Raman Gupta 051bf173dc
revert change in vizio logic to fix bug (#66424) 2022-02-14 09:49:19 +02:00
Shay Levy fe077b6990
Use shorthand attributes in webostv (#66418) 2022-02-13 23:47:37 +02:00
Joshua Roys bc2cc42955
Don't abort zeroconf discovery for IPv6-only devices (#66455) 2022-02-13 15:24:23 -06:00
J. Nick Koston ffcac67d99
Add is_ipv4_address and is_ipv6_address utils (#66472) 2022-02-13 15:23:11 -06:00
Jc2k 40c6832cc1
Update homekit_controller to use the new typed discovery data (#66462) 2022-02-13 12:45:30 -06:00
Erik Montnemery d40a830b89
Remove entities when config entry is removed from device (#66385)
* Remove entities when config entry is removed from device

* Update tests/helpers/test_entity_registry.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Don't remove entities not connected to a config entry

* Update homeassistant/helpers/entity_registry.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

Co-authored-by: Franck Nijhof <git@frenck.dev>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-13 17:23:30 +01:00
Jc2k b8a8485e91
Replace use of deprecated APIs in aiohomekit (#66409) 2022-02-12 23:17:55 -06:00
Allen Porter 0a128d006f
Improve stream robustness by always retrying worker (#66417)
Improve stream robustness by always retrying in the worker on failure, rather than only when
keepalive is enabled.

This will make cloud cameras like nest more robust, since they have a tendency to be flaky. This
is also needed to improve client side retry behavior because when the client attempts to retry,
the stream token is already revoked because the worker stopped.

The worker will still idle timeout if no streams are present, so it won't go on forever if no
frontend is viewing the stream.
2022-02-12 20:59:11 -08:00
kpine a7e5f38a3e
Add is_controller_node flag to WS node status (#66404) 2022-02-12 22:08:39 +01:00
G Johansson a8304392b5
Code quality file (#65258) 2022-02-12 11:49:37 -06:00
corneyl 17a732197b
Add Picnic re-auth flow (#62938)
* Add re-auth handler for Picnic

* Extracted authentication part so right form/errors can be shown during re-auth flow

* Add tests for Picnic's re-authentication flow

* Simplify re-auth flow by using the same step as step_user

* Use user step also for re-auth flow instead of having an authenticate step

* Add check for when re-auth is done with different account

* Remove unnecessary else in Picnic config flow

* Fix the step id in the translation strings file
2022-02-12 08:15:36 -08:00
G Johansson 6d20e68e6d
Code quality scrape (#65441) 2022-02-12 08:28:54 -06:00
G Johansson 3771c154fa
Improve code quality command_line (#65333) 2022-02-12 08:19:37 -06:00
G Johansson 8da150bd71
Improve code quality sql (#65321) 2022-02-12 08:13:01 -06:00
Jc2k 95e4ea8fcd
Simplify the homekit_controller unignore journey (#66353) 2022-02-12 13:16:05 +00:00
Allen Porter b2f5ab2008
Publish Nest Motion/Person events with optional user defined zone information (#66187)
Publish Nest events with zone information if present. User defined zones are configured
in the Google Home app, and are published with Motion/Person event.
2022-02-11 21:22:53 -08:00
Chris Talkington f344ea7bbb
Add select platform to roku (#66133) 2022-02-11 20:52:31 -06:00
G Johansson 9610fa5979
Code cleanup yale_smart_alarm (#65081) 2022-02-11 18:04:04 -06:00
J. Nick Koston 13af2728c2
Fix zwave_me zeroconf mocking (#66356) 2022-02-11 17:13:57 -06:00
J. Nick Koston a6742eff34
Add button to wake august locks from deep sleep (#66343) 2022-02-11 17:13:35 -06:00
Joshua Roys 9134e5c844
Get discovered zeroconf IPv6 addresses (#65462) 2022-02-11 16:46:17 -06:00
Jc2k 0daf20c0cc
Prepare for new aiohomekit lifecycle API (#66340) 2022-02-11 19:26:35 +00:00
Franck Nijhof 2f220b27d4
Fix CPUSpeed with missing info (#66339) 2022-02-11 19:38:55 +01:00
Franck Nijhof 8ff987d90c
Fix PVOutput when no data is available (#66338) 2022-02-11 19:11:06 +01:00
Shay Levy 89b20b9133
Fix webostv restored supported features turn on (#66318)
* Fix webostv restored supported features turn on

* Remove ternary operator expression
2022-02-11 16:48:36 +02:00
Joakim Sørensen 7a40ae13a4
Add guard for invalid EntityCategory value (#66316) 2022-02-11 14:57:45 +01:00
Franck Nijhof 11a13aa0b8
Add heating and cooling binary sensors to Plugwise (#66317) 2022-02-11 13:36:27 +01:00
Erik Montnemery 335a918118
Create MQTT discovery flow when manual config is present (#66248)
* Create MQTT discovery flow when manual config is present

* Change to integration_discovery flow

* Add test

* Add default handler for integration_discovery
2022-02-11 10:31:51 +01:00
jjlawren 4d944e35fd
Skip polling Sonos audio input sensor when idle (#66271) 2022-02-10 12:48:13 -08:00
J. Nick Koston c91a20537a
Add discovery on network up to WiZ (#66144) 2022-02-10 12:30:18 -08:00
Erik Montnemery fe38e6ba87
Drop MQTT import flow (#66160)
* Drop MQTT import flow

* Reload manually configured MQTT entities when config entry is setup

* Address review comments

* Actually remove the import flow
2022-02-10 21:09:57 +01:00
Franck Nijhof bd920aa43d
Cleanup existing Plugwise tests and test fixtures (#66282)
* Cleanup existing Plugwise tests and test fixtures

* More cleanup
2022-02-10 20:41:30 +01:00
Franck Nijhof b8253b1b47
Plugwise HVAC/Preset mode fixes (#66273) 2022-02-10 18:10:21 +01:00
Paulus Schoutsen dd48f1e6fc
Allow uploading media to media folder (#66143) 2022-02-10 08:03:14 -08:00
J. Nick Koston 0fb2c78b6d
Add RGBW/RGBWW support to WiZ (#66196) 2022-02-10 09:08:33 -06:00
Franck Nijhof 8760cb035a
More cleanup in Plugwise switch (#66254) 2022-02-10 10:17:37 +01:00
Franck Nijhof b3814aa4e6
Refactor Plugwise command handling (#66202) 2022-02-10 09:53:26 +01:00
j-a-n 243d003acc
Add Moehlenhoff Alpha2 underfloor heating system integration (#42771)
* Add Moehlenhoff Alpha2 underfloor heating system integration

* isort changes

* flake8 changes

* Do not exclude config_flow.py

* pylint changes

* Add config_flow test

* correct requirements_test_all.txt

* more tests

* Update test description

* Test connection and catch TimeoutError in async_setup_entry

* Add version to manifest file

* Remove version from manifest file

* Replace tests.async_mock.patch by unittest.mock.patch

* Update moehlenhoff-alpha2 to version 1.0.1

* Update requirements for moehlenhoff-alpha2 1.0.1

* Update moehlenhoff-alpha2 to 1.0.2

* Use async_setup_platforms

* Use async_unload_platforms

* Separate connection and devices for each entry_id

* Use async_track_time_interval to schedule updates

* Check if input is valid before checking uniqueness

* Move Exception handling to validate_input

* Catch aiohttp.client_exceptions.ClientConnectorError

* Remove translation files

* Mock TimeoutError

* Fix data update

* Replace current callback implementation with ha dispatcher

* Return False in should_poll

* Remove unused argument

* Remove CONNECTION_CLASS

* Use _async_current_entries

* Call async_schedule_update_ha_state after data update

* Remove unneeded async_setup

Co-authored-by: Milan Meulemans <milan.meulemans@live.be>

* Remove unneeded async_setup_platform

Co-authored-by: Milan Meulemans <milan.meulemans@live.be>

* Set Schema attribute host required

Co-authored-by: Milan Meulemans <milan.meulemans@live.be>

* Remove unused Exception class

Co-authored-by: Milan Meulemans <milan.meulemans@live.be>

* Update manifest.json

Co-authored-by: Milan Meulemans <milan.meulemans@live.be>

* pylint constructor return type None

* Replace properties by class variables

* use pass instead of return

* Remove unused sync update method

* remove property hvac_action

* remove pass

* rework exception handling

* Update homeassistant/components/moehlenhoff_alpha2/config_flow.py

Co-authored-by: Milan Meulemans <milan.meulemans@live.be>

* Correct indentation

* catch Exception in validate_input

* Replace HomeAssistantType with HomeAssistant

* Update to moehlenhoff-alpha2 1.0.3

* Allow to switch between heating and cooling mode

* Update moehlenhoff-alpha2 to version 1.0.4

* Update heatarea data after setting target temperature

* Support hvac_action

* Fix heatarea update with multiple bases

* Update data after setting preset mode

* Use custom preset modes like defined by device

* Fix config flow test

* Fix test_duplicate_error

* Rename property to extra_state_attributes

Rename property device_state_attributes to extra_state_attributes and
return lowercase keys in dict.

* Refactor using DataUpdateCoordinator

* Remove _attr_should_poll

* Raise HomeAssistantError on communication error

Catch HTTPError instead of broad except and reraise as HomeAssistantError

* Change DataUpdateCoordinator name to alpha2_base

* Refresh coordinator before setting data

* Raise ValueError on invalid heat area mode

* Rename heatarea to heat_area

* Set type annotation in class attribute

* Move coordinator to top

* Move exception handling to the coordinator

* Use heat_area_id directly

* Sore get_cooling() result into local var

* Add explanation of status attributes

and remove BLOCK_HC

* Fix pylint warnings

* from __future__ import annotations

* Use Platform Enum

* Move data handling to coordinator

* Remove property extra_state_attributes

* Add missing annotations

* Update moehlenhoff-alpha2 to version 1.1.2

* Rework tests based on the scaffold template

* Set also heat/cool/day/night temp with target temp

* Remove unneeded code from tests

Co-authored-by: Milan Meulemans <milan.meulemans@live.be>
2022-02-10 08:28:52 +01:00
epenet cc5bb556c8
Move Freebox reboot service to a button entity (#65501)
* Add restart button to freebox

* Add warning

* restart => reboot

* Add button tests

Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-09 22:20:24 +01:00
Paulus Schoutsen 3bce870c6d
Add helper for media players to handle HA hosted media (#66120)
* Sonos to sign all HASS urls

* Don't sign if queries in url

* Extract media player hass URL handling to helper
2022-02-09 12:50:33 -08:00
Stephan Traub a6013dc0de
Update WiZ with IP address validation (#66117) 2022-02-09 12:53:32 -06:00
Franck Nijhof aa95150360
Add entity descriptions to Plugwise switch platform (#66174) 2022-02-09 17:56:07 +01:00
Erik Montnemery 3f7b7187ab
Fix controlling nested groups (#66176) 2022-02-09 14:27:46 +01:00
Kevin Stillhammer a0119f7ed0
Resolve zones and return state in find_coordinates (#66081) 2022-02-09 10:43:20 +01:00
Duco Sebel f2fe091979
Allow HomeWizard devices with disabled api to show up in discovery (#65295) 2022-02-08 14:51:28 -08:00
Dave T 5ebc02cef6
Fix generic camera typo in attr_frame_interval (#65390) 2022-02-08 14:47:36 -08:00
Paulus Schoutsen 716a1e2a64
Add camera media source (#65977) 2022-02-08 14:32:02 -08:00
Franck Nijhof b9f21d4e07
Improve typing of Spotify (#66109)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-08 23:07:13 +01:00
Robert Svensson b012b79167
Adapt deCONZ number platform to align with updated design of binary sensor and sensor platforms (#65248)
* Adapt number to align with binary sensor and sensor platforms

* Make number tests easier to expand
2022-02-08 23:03:37 +01:00
Erik Montnemery 911e488d48
Fix ENTITY_CATEGORIES_SCHEMA (#66108)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-02-08 14:00:53 -08:00
Erik Montnemery 009b31941a
Support restoring SensorEntity native_value (#66068) 2022-02-08 14:00:26 -08:00
Patrik Lindgren f8a84f0101
Add diagnostics for Tradfri platform (#66092)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-08 22:05:33 +01:00
epenet 86ab500afd
Add Renault hvac sensors (#65993)
* Add hvac sensors to renault

* Adjust fixtures

* Adjust tests

* Use icon_fn

* Use lambda

Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-08 22:02:45 +01:00
Erik Montnemery 55d8314093
Fix cleanup of MQTT debug info (#66104) 2022-02-08 12:49:25 -08:00
Sander Jochems d574e54fd8
Fivem code quality improvements (#66086)
* specify config type

* move coordinator outside try block

* rename gamename to game_name

* remove log in __init__

* Remove logging and minify update

* Add types to parameters

* Remove name from device

* Remove update listener

* Remove status icon

* Dont allow duplicate entries

* Use default translation string

* Remove online and port from coordinator
2022-02-08 20:42:55 +01:00
Franck Nijhof 4efebcb86c
Use upstream device information for Plugwise (#66074) 2022-02-08 19:08:01 +01:00
Tiernan 2df5060d80
Fix TOD incorrectly determining the state between sunrise and sunset (#65884)
* Fix TOD component incorrectly determining the state between sunrise and sunset (#30199)

* TOD fix

* Comment added

* Review

* Review

* Review

* Update time after day fix workaround for compatibility with
current version.
Only apply fix when using times and not when using sun events.
Add unit test for behaviour.

Co-authored-by: Nikolay Vasilchuk <Anonym.tsk@gmail.com>
2022-02-08 14:26:36 +01:00
Franck Nijhof 1fc717ed1c
Add diagnostics support to Plugwise (#65982) 2022-02-08 12:43:45 +01:00
Franck Nijhof d12a392767
Update plugwise 0.16.2 (#65933) 2022-02-08 11:13:05 +01:00
Sander Jochems 0ea82bdbfb
Fivem integration (#65089)
* Initial fivem integration setup

* Use licenseKey for unique ID

* Create FiveMServer class

* Create FiveMStatusBinarySensor

* Fix platform loading

* Create sensor platform

* Remove config flow tests

* Update manifest.json

* Use attr_ instead or properties in sensors.py

* Use entry_id as unique_id

* Move device info to _attr instead of property

* Register callback in FiveMEntity

* Create config flow tests

* Add loggin to fivem

* Use FiveM in config_flow

* Use update_coordinator instead of dispatcher

* Bump fivem-api to 0.1.2

* Remove leftovers

* More tests for config flow

* Add component files to .coveragerc

* Fix simple comments

* Add gamename check to config flow

* Use entity descriptions for sensors

* Move extra attributes to init

* Use [] instead of get() for server info

* Fix error in gamename test
2022-02-08 11:27:11 +02:00
Tobias Sauerwein 8b38fa58aa
Bump pytest to 7.0.0 (#65981) 2022-02-08 10:03:27 +01:00
Raman Gupta 4076ca9641
Fix schema for zwave_js WS API (#66052) 2022-02-07 21:53:48 -08:00
Patrik Lindgren afd0005a31
Add sensor for filter time left on Tradfri fan platform (#65877)
* Add support for filter time left

* Fix test for fan platform

* Remove debug code

* Add unique id migration tool

* Convert to hours

* Fix tests

* Apply suggestions from code review

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Add comment, check migration

* Refactor migration helper

* Refactor migration helper

* Move definition of new unique id

* Return after warning

* Add test for unique id migration

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-08 02:21:22 +01:00
J. Nick Koston f943f30492
Add discovery support to elkm1 (#65205) 2022-02-07 16:25:26 -08:00
Paulus Schoutsen 95a890c6e1
Get_url to prefer external URL if SSL configured (#66039) 2022-02-07 15:44:02 -08:00
Erik Montnemery 7cc6770f83
Revert "Make idle chromecasts appear as idle instead of off" (#66005) 2022-02-07 20:24:30 +01:00
Franck Nijhof 4732e37005
Remove passing loop into sleep in SamsungTV (#66030) 2022-02-07 20:08:54 +01:00
G Johansson 480ce84b8a
Improve code quality filesize (#65240) 2022-02-07 11:59:06 -06:00
Erik Montnemery 910b1f1ec8
Speed up deletion of duplicated statistics (#66014) 2022-02-07 09:11:52 -08:00
Pedro Lamas ebbe1ff1a2
Cache webostv supported_features state (#65930)
* Cache webostv supported_features state

* Fixes typings

* Restore supported_features attribute on restart

* Reverts change on supported_features initial state

Co-authored-by: Shay Levy <levyshay1@gmail.com>

* Fixes tests

Co-authored-by: Shay Levy <levyshay1@gmail.com>
2022-02-07 17:49:18 +02:00
Poltorak Serguei 3c5a667d97
Add Z-Wave.Me integration (#65473)
* Add support of Z-Wave.Me Z-Way and RaZberry server (#61182)

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: LawfulChaos <kerbalspacema@gmail.com>

* Add switch platform to Z-Wave.Me integration (#64957)

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Dmitry Vlasov <kerbalspacema@gmail.com>

* Add button platform to Z-Wave.Me integration (#65109)

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
Co-authored-by: Dmitry Vlasov <kerbalspacema@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Fix button controller access (#65117)

* Add lock platform to Z-Wave.Me integration #65109 (#65114)

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
Co-authored-by: Dmitry Vlasov <kerbalspacema@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Add sensor platform to Z-Wave.Me integration (#65132)

* Sensor Entity

* Sensor fixes

* Apply suggestions from code review

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Inline descriotion according to review proposal

* State Classes for sensor

* Generic sensor

* Generic sensor

Co-authored-by: Dmitry Vlasov <kerbalspacema@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Add binary sensor platform to Z-Wave.Me integration (#65306)

* Binary Sensor Entity

* Update docstring

Co-authored-by: Dmitry Vlasov <kerbalspacema@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Add Light Entity platform to Z-Wave.Me integration (#65331)

* Light Entity

* mypy fix

* Fixes, ZWaveMePlatforms enum

* Apply suggestions from code review

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Fixes

* Fixes

* Fixes

Co-authored-by: Dmitry Vlasov <kerbalspacema@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Add Thermostat platform to Z-Wave.Me integration #65331 (#65371)

* Climate entity

* Climate entity

* Apply suggestions from code review

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Climate entity fix

* Clean up

* cleanup

* Import order fix

* Correct naming

Co-authored-by: Dmitry Vlasov <kerbalspacema@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Correct zwave_me .coveragerc (#65491)

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: LawfulChaos <kerbalspacema@gmail.com>
Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2022-02-07 16:27:11 +01:00
Joakim Sørensen b1015296d9
Add diagnostics to Version integration (#65999)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-07 16:11:04 +01:00
epenet 486c068111
Allow None on Renault binary sensors (#65997)
* Enable None on renault binary sensors

* Adjust tests

Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-07 15:06:40 +02:00
Joakim Sørensen 38f7213002
Add more tests to device registry updates (#65989) 2022-02-07 11:15:04 +01:00
rhpijnacker bb762d5b0f
100% code coverage for config_flow of dsmr component (#65238) 2022-02-07 10:48:33 +01:00
Chris Talkington f05caf451e
Small cleanup of sonarr sensor platform (#65962) 2022-02-07 09:53:23 +01:00
Teemu R fd7e2e76e7
Add tplink diagnostics (#65822) 2022-02-06 16:50:44 -06:00
Teemu R f4ebb03bab
Add tplink hardware version to device info (#65951)
* Add tplink hardware version to device info

* Update mocks

Co-authored-by: J. Nick Koston <nick@koston.org>
2022-02-07 00:37:54 +02:00
ollo69 341d039252
Improve androidtv mac address handling and test coverage (#65749)
* Better mac addr handling and improve test coverage

* Apply suggested changes

* Apply more suggested changes
2022-02-06 14:15:50 -08:00
Allen Porter ddd198de37
Fix legacy nest diagnostics to return empty rather than fail (#65824)
Fix legacy nest diangostics to return gracefully, rather than a TypError
by checking explicitiy for SDM in the config entry. Update diagnostics
to use the common nest test fixture, and extend with support for the
legacy nest config. Use the sdm test fixture in the existing legacy
tests so they all share the same config files.
2022-02-06 14:14:25 -08:00
J. Nick Koston 41f602c3df
Fix loss of ability to control white channel in HomeKit on RGB&W lights (#65864)
* Fix loss of ability to control white channel in HomeKit on RGB&W lights

- Fix white channel missing from RGB/W lights

- Fix temp missing from RGB/CW lights

- Fixes #65529

* cover the missing case

* bright fix

* force brightness notify on color mode change as well
2022-02-06 14:12:30 -08:00
J. Nick Koston 62da194340
Add diagnostics support to HomeKit (#65942)
* Add diagnostics support to HomeKit

* remove debug
2022-02-06 14:02:07 -08:00
Alex Yao 88309a26b7
Fix Yeelight Music Mode Rate Limits (#64891) 2022-02-06 15:34:27 -06:00
Diego Elio Pettenò c6aa526469
Support songpal wireless-only soundbar identifiers (#65330)
As shown in #64868, a number of newer models don't come wiht a macAddr
attributes, so for those fall back to the wireless address.

This could be hidden by the python-songpal library but for now this will
make it possible to have multiple modern songpal devices on the same
network.
2022-02-06 22:33:58 +01:00
Niels AD ccdf182d31
rfxtrx: Add command_on/command_off support for pt2262 switch entities (#65798) 2022-02-06 19:39:57 +01:00
Sander Huisman e7dfc89452
Add unique ID to InfluxDB sensor (#65518) 2022-02-06 18:40:37 +01:00
Franck Nijhof 62a314015c
BinarySensorEntityDescriptions for Plugwise (#65887) 2022-02-06 17:25:55 +01:00
ollo69 13699baa4d
Remove deprecated yaml config from AsusWRT (#65904) 2022-02-06 17:03:04 +02:00
J. Nick Koston 9dc158f5e0
Add support for picking discovered devices to WiZ (#65826)
* Add support for picking discovered devices

- Also fixes state not being written initially (it was not so
  obvious since the next coordinator update wrote it)

* store it

* store it

* order

* fixes

* more cleanups

* hints

* naming

* merge branches
2022-02-05 22:23:31 +01:00
Franck Nijhof b0bb2d2453
Cleanup Plugwise config flow and tests (#65818) 2022-02-05 19:07:02 +01:00
J. Nick Koston 5621e20963
WiZ Cleanups part 3 (#65819)
* WiZ Cleanups part 3

- Sockets are now using the switch platform

* tweaks

* remove rgb colorcheck

* tweaks

* tweaks

* cover

* cover
2022-02-05 18:56:17 +01:00
J. Nick Koston 676edb610f
Add coverage for color_rgbww_to_rgb, fix divzero case (#65721) 2022-02-05 10:59:32 -06:00
J. Nick Koston adbc0e5955
Prevent multiple dhcp flows from being started for the same device/domain (#65753) 2022-02-05 10:59:22 -06:00
J. Nick Koston 2bcd4f8f93
Add discovery support to WiZ Part 1 (#65752) 2022-02-05 10:36:44 -06:00
Franck Nijhof 5c6d019d6b
Remove options flow from Plugwise (#65808) 2022-02-05 16:46:50 +01:00
J. Nick Koston 342f5182b9
WiZ cleanups part 1 (#65746)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2022-02-05 09:23:19 -06:00
Franck Nijhof fa09cf663e
Update black to 22.1.0 (#65788) 2022-02-05 14:19:37 +01:00
Franck Nijhof e242796394
Remove deprecated format for date(time) sensors (#65734) 2022-02-04 23:42:29 -08:00
Aaron Bach 3387e8368b
Add redacted subscription data to SimpliSafe diagnostics (#65751) 2022-02-04 23:41:12 -08:00
Paulus Schoutsen d753f4a2e7
Fix UPNP access to SSDP info (#65728) 2022-02-04 21:33:53 -08:00
Stephan Traub 432d9a8f19
Introduce wiz integration for the WiZ Platform (#44779)
Co-authored-by: Marvin Wichmann <marvin@fam-wichmann.de>
Co-authored-by: J. Nick Koston <nick@koston.org>
Co-authored-by: Jan Stienstra <65826735+j-stienstra@users.noreply.github.com>
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: Franck Nijhof <git@frenck.dev>
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-02-04 16:20:21 -08:00
Paulus Schoutsen 5da923c341
Protect state.as_dict from mutation (#65693) 2022-02-04 14:45:25 -08:00
Duco Sebel 0d3bbfc9a7
Fix `homewizard_energy` migration issues from #65594 (#65718) 2022-02-04 14:45:06 -08:00
J. Nick Koston 26ff6d2aa0
Fix warm/cold reversal in rgbww_to_color_temperature (#65677) 2022-02-04 11:36:30 -08:00
Jeff Irion fe05d6680c
Bump androidtv to 0.0.63 (fix MAC issues) (#65615) 2022-02-04 20:13:08 +01:00
Joakim Sørensen 8021b05448
Allow selecting own repositories (#65695) 2022-02-04 19:33:10 +01:00
Paulus Schoutsen a6caf3f579
Call out 3rd party containers more clearly (#65684) 2022-02-04 09:57:14 -08:00
Erik Montnemery 41ab12cb88
Don't use shared session during recorder migration (#65672) 2022-02-04 09:55:11 -08:00
Duco Sebel a97e69196c
Add migration to migrate 'homewizard_energy' to 'homewizard' (#65594) 2022-02-04 09:12:35 -08:00
Erik Montnemery 8245ff7473
Log transmitted MQTT messages (#65550) 2022-02-04 17:35:32 +01:00
Erik Montnemery ac7662c82d
Remove limit of amount of duplicated statistics (#65641) 2022-02-04 14:49:45 +01:00
Robert Svensson 96c4e33b24
Parametrize deCONZ binary sensors (#65012)
* Improve test coverage prior to improving deCONZ binary sensor platform

* Define all relevant binary sensors as DeconzBinarySensorDescription

* Fix review comment

* Allow providing extra update keys if sensor provides extra attributes

* Minor touch up of naming

* Remove duplicate assert
2022-02-04 12:58:07 +01:00
alexanv1 98a7125933
Fix Z-Wave lights (#65638)
* Fix Z-Wave lights

* Update tests
2022-02-04 10:50:24 +01:00
Paulus Schoutsen bc41028800
Some tweaks to the demo (#65623)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2022-02-04 09:49:47 +01:00
Raman Gupta c477378835
Raise when zwave_js device automation fails validation (#65610) 2022-02-04 02:50:47 +01:00
G Johansson 24cd63973d
Add back resolvers config flow dnsip (#65570) 2022-02-03 15:05:56 -08:00
Paulus Schoutsen 157276f4e6
Add a Lovelace cast platform (#65401) 2022-02-03 13:43:23 -08:00
J. Nick Koston b97cd3ce93
Do not update unifiprotect host from discovery if its not an ip (#65548) 2022-02-03 19:14:36 +01:00
J. Nick Koston 3d8d507ed9
Migrate powerwall from using ip address as unique id (#65257)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-03 18:39:57 +01:00
mk-maddin efb6fd1569
Fix script / automation repeat with count 0 fails (#65448)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-02-03 08:18:58 -08:00
Jan Bouwhuis 2f0d0998a2
Add Mqtt vacuum `unknown` state (#65311)
* Add Mqtt vacuum `unknown` status

* Update tests/components/mqtt/test_state_vacuum.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-02-03 16:50:39 +01:00
Jan Bouwhuis cf52357229
Add MQTT light unknown state support (#65308)
* Add MQTT light unknown sate support

* Update homeassistant/components/mqtt/light/schema_basic.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Update homeassistant/components/mqtt/light/schema_json.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Update homeassistant/components/mqtt/light/schema_template.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Update tests for default unknown state

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-02-03 16:49:57 +01:00
Jan Bouwhuis 2d011821ea
Add MQTT humidifier unknown state support (#65302)
* Add MQTT humidifier unknown state support

* Update homeassistant/components/mqtt/humidifier.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Fix tests for changed default optimistic state

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-02-03 16:49:09 +01:00
Jan Bouwhuis 711bd7169e
Add Mqtt Fan unknown state support (#65301)
* Add Mqtt Fan unknown state support

* Update homeassistant/components/mqtt/fan.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Adjust default state in tests

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-02-03 16:48:03 +01:00
Jan Bouwhuis 3d434dffc7
Add support Mqtt switch for unkown state (#65294)
* Mqtt switch allow unkown state

* correct type

* Update discovery tests

* Optimistic mode if not state_topic is configured.

* Default state UNKNOWN in optimistic mode

* fix discovery test
2022-02-03 16:47:24 +01:00
Jan Bouwhuis 63459feede
Return current state if template throws (#65534) 2022-02-03 16:46:36 +01:00
epenet 8234625d30
Use Domain not Platform on test service calls (#65508)
* Adjust atag

* adjust broadlink

* Adjust onewire

* Adjust plex

* Adjust renault

* Adjust tasmota

* Adjust zha

Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-03 14:16:35 +01:00
Erik Montnemery 63680f0b36
Make util.async_.protect_loop name names (#65493) 2022-02-03 14:06:40 +01:00
epenet c8504bd21d
Add tests for pylint plugins (#65436)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-02-03 10:01:02 +01:00
Erik Montnemery 23ee8adf59
Fix flaky homewizard test (#65490) 2022-02-03 09:23:32 +01:00
Erik Montnemery f3a89de71f
Fix race when handling updated MQTT discovery data (#65415) 2022-02-02 17:12:22 -08:00
Maciej Bieniek 32be5576dc
Get wind speed unit from AccuWeather data (#65425) 2022-02-02 17:07:12 -08:00
Tobias Sauerwein 81ad56b8ad
Add events on cloud connect and disconnect (#65215)
* Add events on cloud connect and disconnect

Signed-off-by: cgtobi <cgtobi@gmail.com>

* Use event capture helper

Signed-off-by: cgtobi <cgtobi@gmail.com>

* Provide listener method instead of public event

Signed-off-by: cgtobi <cgtobi@gmail.com>

* Add test for disconnect notification

Signed-off-by: cgtobi <cgtobi@gmail.com>

* Apply suggestions from code review

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Use Enum

Signed-off-by: cgtobi <cgtobi@gmail.com>

* Add module level api

Signed-off-by: cgtobi <cgtobi@gmail.com>

* Apply suggestions from code review

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Clean up dead code

Signed-off-by: cgtobi <cgtobi@gmail.com>

* Flake8

Signed-off-by: cgtobi <cgtobi@gmail.com>

* Clean up

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-02 18:11:06 +01:00
Erik Montnemery fda0fbd115
Stringify MQTT payload in mqtt/debug/info WS response (#65429) 2022-02-02 18:08:48 +01:00
Erik Montnemery 5a34feb7de
Don't warn on time.sleep injected by the debugger (#65420) 2022-02-02 08:58:14 -08:00
J. Nick Koston 530fc8a9af
Ensure unifiprotect discovery can be ignored (#65406) 2022-02-02 16:16:29 +01:00
Jan Bouwhuis 2c07330794
Fix MQTT expire_after effects after reloading (#65359)
* Cleanup sensor expire triggers after reload

* fix test binary_sensor

* Also trigger cleanup parent classes

* Restore an expiring state after a reload

* correct discovery_update

* restore expiring state with remaining time

* Update homeassistant/components/mqtt/binary_sensor.py

description

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Log remaining time

* Move check

* check and tests reload

* remove self.async_write_ha_state()

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-02-02 16:14:52 +01:00
Erik Montnemery 0eb2caabcf
Report unmet dependencies for failing config flows (#65061)
* Report unmet dependencies for failing config flows

* Apply suggestions from code review

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/setup.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Modify error message

* Add test

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-02-02 15:06:27 +01:00
J. Nick Koston 73189ead1f
Handle brightness being None for senseme (#65372) 2022-02-01 14:51:28 -08:00
Robert Svensson 69ac59ce73
Redact host address in UniFi diagnostics (#65379) 2022-02-01 09:52:56 -08:00
Bram Kragten c82aa1606a
Allow removing keys from automation (#65374) 2022-02-01 09:45:08 -08:00
ZuluWhiskey 65ea54927d
Fix MotionEye config flow (#64360)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-02-01 09:05:50 -08:00
G Johansson 390d32c71b
Fix options for dnsip (#65369) 2022-02-01 16:47:42 +01:00
Paulus Schoutsen b05b4c4b38
Simplify unifi cleanup logic (#65345) 2022-02-01 07:22:12 +01:00
Allen Porter 88ed2f3b3e
Improve google calendar test coverage to 97% (#65223)
* Improve google calendar test coverage to 97%

* Remove commented out code.

* Remove unnecessary (flaky) checks for token file persistence

* Remove mock code assertions

* Add debug logging to google calendar integration

* Increase alarm time to polling code to reduce flakes

* Setup every test in their own configuration directory

* Mock out filesystem calls to avoid disk dependencies

Update scope checking code to use Storage object rather than text file matching

* Update tests to check entity states when integration is loaded

* Mock out google service in multiple locations

* Update homeassistant/components/google/__init__.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/google/__init__.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-02-01 03:14:49 +01:00
Paulus Schoutsen 5289935ac1
I zone, you zone, we zoning (#65344) 2022-01-31 17:04:46 -08:00
Martin Hjelmare d0412d65ac
Remove stale tradfri devices (#65218) 2022-01-31 16:43:16 -08:00
Michael c9f38355f7
Improve debugging and error handling in Fritz!Tools (#65324) 2022-01-31 15:28:11 -08:00
J. Nick Koston 18ea3fb85a
Prevent unifiprotect from being rediscovered on UDM-PROs (#65335) 2022-01-31 15:27:26 -08:00
J. Nick Koston c7eb676449
Fix guardian being rediscovered via dhcp (#65332) 2022-01-31 15:24:55 -08:00
Paulus Schoutsen bf138c4ffb
Alexa to handle brightness and catch exceptions (#65322) 2022-01-31 15:01:46 -08:00
Chris Talkington 70da08499a
Refactor sonarr tests (#64886) 2022-01-31 16:59:18 -06:00
Jc2k 0f88790303
Refactor homekit_controller to prepare for more typing information (#65329) 2022-01-31 16:48:16 -06:00
w35l3y 076faaa4a4
Add support to reprompt user (#65256) 2022-01-31 10:23:26 -08:00
Franck Nijhof 441e81c02a
Add diagnostics support to WLED (#65317) 2022-01-31 09:16:33 -08:00
Erik Montnemery 80da5c52ae
Correct cast media browse filter for audio groups (#65288) 2022-01-31 11:45:48 +01:00
Erik Montnemery b0c36d7729
Add cast platform for extending Google Cast media_player (#65149)
* Add cast platform for extending Google Cast media_player

* Update tests

* Refactor according to review comments

* Add test for playing using a cast platform

* Apply suggestions from code review

Co-authored-by: jjlawren <jjlawren@users.noreply.github.com>

* Pass cast type instead of a filter function when browsing

* Raise on invalid cast platform

* Test media browsing

Co-authored-by: jjlawren <jjlawren@users.noreply.github.com>
2022-01-31 10:50:05 +01:00
Jan Bouwhuis 6fdaec0847
Add MQTT siren platform (#64440)
* Add mqtt siren draft

* fix tests

* Intergrate notify platform

* tests and fixes siren platform

* Add tests notify platform

* config parameters and abbreviations

* remove duplicate key

* undo move topic abbreviation

* Move const CONF_MESSAGE_COMMAND_TEMPLATE

* Remove notify service integration

* Rework

* Update homeassistant/components/mqtt/siren.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Publish JSON by default

* Allow unknown state - rename value_template

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-01-31 10:31:57 +01:00
Jan Bouwhuis bfaada34e2
Allow `unknown` state to be set (#65183) 2022-01-31 10:25:08 +01:00
J. Nick Koston 8c9bd6e790
Increase august timeout and make failure to sync at startup non-fatal (#65281) 2022-01-30 20:50:49 -08:00
J. Nick Koston 2f6bf08165
Fix senseme fan lights (#65217) 2022-01-30 20:24:42 -08:00
J. Nick Koston 73bd8db273
Fix flux_led not generating unique ids when discovery fails (#65250) 2022-01-30 20:17:19 -08:00