Commit Graph

12328 Commits (f6600bbc209130cffee3b8b115e8309488eafc73)

Author SHA1 Message Date
hesselonline c973e5d0d2
Add Switch platform to Wallbox (#70584)
Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
2022-04-26 23:27:43 +02:00
Paulus Schoutsen 9303e35a7d
tts.say to use media source URLs (#70382) 2022-04-26 13:49:32 -07:00
Erik Montnemery f96c1136b0
Bump pytest-socket to 0.5.1 (#69624)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-26 10:42:37 -10:00
Erik Montnemery ce302f4540
Play first item in m3u and pls playlists when casting (#70047)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-04-26 13:16:37 -07:00
J. Nick Koston 6ce768465f
Improve purge performance for non-sqlite databases (#70576) 2022-04-26 13:11:57 -07:00
J. Nick Koston 1c4a785fb3
Prevent autoflush from happening during attrs lookup (#70768) 2022-04-26 13:04:58 -07:00
J. Nick Koston f073f17040
Refactor tracking of the recorder run history (#70456)
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-04-26 09:59:43 -10:00
Marc Mueller 997fb7a11c
Add fritzbox_callmonitor type hints (2) (#70293) 2022-04-26 20:26:42 +02:00
Paulus Schoutsen 4a53121b58
Test that mobile app requires empty object for encrypted webhooks without data (#70718) 2022-04-26 19:30:08 +02:00
epenet abdf5bb86a
Use light enums in tasmota (#70788) 2022-04-26 19:04:12 +02:00
epenet bd87ae79ae
Adjust climate constants in coolmaster config flow (#70764) 2022-04-26 18:57:45 +02:00
Erik Montnemery 3016b5fbfc
Use recorder fixtures and helpers in tests (#70773) 2022-04-26 06:08:00 -10:00
Raman Gupta 24b090a038
Create zwave_js.invoke_cc_api service (#70466) 2022-04-26 11:30:49 -04:00
J. Nick Koston 89e3a48751
Use database executor in migration test (#70774) 2022-04-26 07:42:28 -07:00
epenet 7d2363ad22
Use light enums in tests (#70801) 2022-04-26 16:32:00 +02:00
Franck Nijhof cad2ba4d44
Detect duplicate script objects in config validation (#70368) 2022-04-26 15:33:43 +02:00
epenet 5d8b35face
Use light enums in yeelight (#70797) 2022-04-26 14:55:44 +02:00
epenet fe0120b65a
Use light enums in zwave_js (#70791) 2022-04-26 15:31:25 +03:00
epenet 67b411d2b2
Use light enums in lcn (#70796) 2022-04-26 15:30:34 +03:00
epenet 24b4690e5d
Use climate enums in zwave_js (#70757) 2022-04-26 12:23:48 +02:00
Robert Svensson f7d9797c62
Streamline setup of deCONZ scene platform (#70700) 2022-04-26 11:42:56 +02:00
Álvaro Fernández Rojas add7103d55
Use Airzone WebServer MAC address as unique ID (#70287)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-25 22:52:55 -10:00
epenet 8745401af5
Use climate enums in zha (#70754) 2022-04-26 10:09:13 +02:00
epenet 9f428f268c
Use climate enums in atag (#70623) 2022-04-26 09:59:31 +02:00
epenet 4827fe5280
Use climate enums in homematicip_cloud (#70668) 2022-04-26 09:41:02 +02:00
Marc Mueller eeecdf213d
Use StrEnum [fritzbox_callmonitor] (#70289) 2022-04-26 09:40:08 +02:00
epenet a7bb74e151
Use climate enums in melissa (#70690) 2022-04-26 09:30:46 +02:00
epenet 2dbd2575d8
Use climate enums in whirlpool (#70752) 2022-04-25 21:27:28 -10:00
epenet 10905f6074
Use climate enums in vera (#70750) 2022-04-25 21:25:24 -10:00
epenet 65af9cb1a0
Use climate enums in airzone (#70624) 2022-04-25 21:21:44 -10:00
epenet 1bc9744be3
Use climate enums in advantage_air (#70621) 2022-04-25 21:21:17 -10:00
epenet 7fb0691a8b
Use climate enums in balboa (#70626) 2022-04-25 21:19:52 -10:00
epenet 073833fcec
Use climate enums in netatmo (#70724) 2022-04-26 09:18:09 +02:00
epenet 09393d6f64
Use climate enums in modbus (#70693) 2022-04-25 21:18:00 -10:00
epenet 20f7e2f4d2
Use climate enums in venstar (#70749) 2022-04-25 21:17:19 -10:00
epenet 98d757b2b2
Use climate enums in smartthings (#70737) 2022-04-26 09:12:54 +02:00
epenet c44391f368
Use climate enums in smarttub (#70738) 2022-04-26 09:10:48 +02:00
epenet 7fb8bb7769
Use climate enums in nexia (#70725) 2022-04-25 21:06:33 -10:00
epenet 896b616687
Use climate enums in plugwise (#70729) 2022-04-26 09:03:23 +02:00
epenet 62c8687a86
Use climate enums in homekit_controller (#70663) 2022-04-25 18:27:58 -10:00
Álvaro Fernández Rojas 8d71595f31
Improve and fix Airzone config flow (#70474) 2022-04-25 18:25:11 -10:00
jjlawren 5bcc83f6f2
Remove "sonos" prefix for Sonos switch entity_ids (#70698) 2022-04-25 16:01:54 -10:00
J. Nick Koston 1d2c949c51
Convert history_stats to use a coordinator (#70388)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2022-04-25 15:20:06 -07:00
Paulus Schoutsen 87dceaf238
Hue config flow to guard ipv6 (#70703)
* Hue config flow to guard ipv6

* Use helper
2022-04-25 10:52:57 -07:00
Paulus Schoutsen 5317bf02e6
Fix hidden default (#70699) 2022-04-25 10:10:42 -07:00
J. Nick Koston 5224cf5968
Update async_upnp_client to 0.29.0 (#70604) 2022-04-25 09:53:35 -07:00
Tom Harris 6363c67398
Insteon HUB DHCP discovery (#70685)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2022-04-25 09:01:56 -07:00
Erik Montnemery 28ba572d9d
Only apply color from light profile if no color specified (#70640) 2022-04-25 07:56:07 -07:00
Marc Mueller 9b9b553521
Disable no-self-use [pylint] (#70641)
* Disable no-self-use

* Remove disable comments
2022-04-25 07:41:01 -07:00
epenet 9dcbc8469e
Use climate enums in deconz (#70630)
* Use climate enums in deconz

* Adjust tests

* Adjust type hint

* Update climate.py

* Update climate.py

* Update climate.py

* Don't edit files in Github!
2022-04-25 16:18:44 +02:00
David F. Mulcahey ea9c8b15de
Coerce int in Flo set sleep mode service (#70592)
* Coerce int in Flo set sleep mode service

* add test to ensure exception thrown for bad value
2022-04-25 09:18:09 -04:00
epenet 069dd567f7
Use climate enums in knx (#70676) 2022-04-25 14:57:31 +02:00
Erik Montnemery 23d9e135bc
Allow 'turning on' cast groups (#70642)
* Allow 'turning on' cast groups

* Adjust test
2022-04-25 14:41:24 +02:00
Erik Montnemery d045e8678d
Use recorder test fixtures in tests (#70652) 2022-04-25 14:23:52 +02:00
Martin Hjelmare 09b4b7eb37
Remove hass.helpers from config_entries (#70660) 2022-04-25 14:21:03 +02:00
epenet d52234a57a
Use climate enums in fritzbox (#70650)
* Use climate enums in fritzbox

* Adjust tests

* Update homeassistant/components/fritzbox/climate.py

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

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-04-25 13:33:51 +02:00
epenet 0fd2a7dc83
Use climate enums in freedompro (#70651)
* Use climate enums in freedompro

* Adjust tests

* Adjust type hints
2022-04-25 13:33:19 +02:00
epenet e51ed7a11b
Use climate enums in blebox (#70628)
* Use climate enums in blebox

* Adjust tests
2022-04-25 13:17:46 +02:00
Erik Montnemery 28ebab9c5a
Simplify waiting for recorder in tests (#70647) 2022-04-25 12:04:47 +02:00
epenet a8a7359c6f
Use VacuumEntityFeature in mqtt (#70570)
* Use VacuumEntityFeature in mqtt

* Fix tests
2022-04-25 11:34:06 +02:00
epenet 23c5bd9779
Use climate enums in gree (#70655)
* Use climate enums in gree

* Adjust tests
2022-04-25 10:58:39 +02:00
epenet b81f8e75ee
Use climate enums in generic_thermostat (#70656)
* Use climate enums in generic_thermostat

* Adjust tests
2022-04-25 10:58:05 +02:00
Robert Svensson 8eae572c93
Mark type "On/Off Switch" as a deCONZ switch entity (#70598)
Convert entity types of light platform to switch platform
2022-04-25 08:25:38 +02:00
J. Nick Koston 9f11063724
Fix state_changes_during_period bakery caching for limit and descending (#70610) 2022-04-24 21:47:21 -07:00
David F. Mulcahey 31eae0980b
Add state class to Flo sensor entities (#70591) 2022-04-24 12:48:49 -10:00
Johann Vanackere e2bbdb26be
Daikin AC : Round to nearest half degree (#70446) (#70452) 2022-04-24 14:47:09 -07:00
Robert Svensson b15387ffb9
Remove migration of entities from deCONZ switch to siren platform (#70600) 2022-04-24 23:32:13 +02:00
Allen Porter bab9f4ba76
Fix nest error handling and bug in tests for media fetches (#70596) 2022-04-24 10:17:59 -10:00
Allen Porter dc7e3a6df6
Fix boundary case in calednar trigger (#70467)
Update calendar trigger scan logic to add a one second boundary due to the
exclusive search. Add a test that reproduced the issue.
2022-04-24 12:52:17 -07:00
G Johansson 472ffd3bc6
Implement config flow for SQL integration (#68700) 2022-04-24 08:50:32 -10:00
David F. Mulcahey 9b8d217b0e
Implement support for start_up_on_off in ZHA (#70110)
* Implement support for start_up_on_off

fix discovery issues

remove cover change

* add tests
2022-04-24 12:50:06 -04:00
glcos 8a73381b56
ZHA ElectricalMeasurement cluster add Frequency and Power Factor (#59417)
* Add files via upload

* Add Frequency and PF

* Add Frequency and PF

Add Frequency and PF

* Add Frequency and PF

Add Frequency and PF

* Add Frequency and PF

Add Frequency and PF

* Add Frequency and PF

Add Frequency and PF

* Update homeassistant/const.py

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

* Update homeassistant/components/zha/sensor.py

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

* Update homeassistant/const.py

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

* Fix rebase

* rebase cleanup

* fix stale doc string

* missed this again

* isort

* update tests

* update discovery test data

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
Co-authored-by: David Mulcahey <david.mulcahey@me.com>
2022-04-24 12:42:52 -04:00
Robert Svensson 009111151d
Move deCONZ alarm system imports to reflect the changes in pydeconz (#70453) 2022-04-24 10:17:46 +02:00
Robert Svensson 301dcaae63
Move deCONZ sensor imports to reflect changes in pydeconz (#70471) 2022-04-23 22:59:51 +03:00
Ani Betts 6c391ecc59
Remove broken Arlo component (#70330)
* Remove broken Arlo component

This component has been fully broken since early 2019 because of
authentication changes from Arlo.

* Update requirements
2022-04-23 20:16:28 +03:00
Matthias Alphart 639e3bb900
Add optional `type` for KNX notify entity configuration (#70451) 2022-04-23 12:21:58 +02:00
Álvaro Fernández Rojas 0c2acdf337
Add Airzone diagnostics (#69362)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-22 22:28:07 -10:00
Erik Montnemery 982e314de6
Use recorder_mock in tests (#70363)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-04-22 19:29:44 -10:00
Álvaro Fernández Rojas a29265e725
Add Airzone Low Battery Binary Sensor (#69022)
* airzone: binary_sensor: add Low Battery

This binary sensor is only applicable for Radio Thermostats.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>

* airzone: use BinarySensorDeviceClass

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2022-04-22 19:27:23 -10:00
Allen Porter 5ffaa70bb6
Add calendar event end trigger (#70372)
* Add calendar event end trigger

* Rename start date to last_endtime

* Rename now to last_endtime
2022-04-22 21:19:35 -07:00
Jason Hunter 9008a76bd4
Remove deprecated YAML configuration from ONVIF (#70395)
* Remove deprecated YAML configuration from ONVIF

* remove async_setup completely
2022-04-22 21:35:11 -04:00
Erik Montnemery e45d4d53dd
Correct time stamp format in Alexa responses (#70267) 2022-04-22 08:44:59 -07:00
J. Nick Koston cc3d6aa247
Ensure rainmachine creates config entry titles as strings (#70417) 2022-04-22 07:58:19 -06:00
J. Nick Koston 3737b58e85
Avoid fetching metadata multiple times during stat compile (#70397) 2022-04-22 00:25:42 -10:00
J. Nick Koston c96781a795
Prevent plumbum from causing the testsuite to fail (#70400) 2022-04-22 08:40:23 +02:00
Dave T 70e125850c
Limit autogenerated entity_id string length (#69739) 2022-04-21 22:39:51 -07:00
Franck Nijhof 7b75a16745
Add visible by default property to base Entity (#70370) 2022-04-21 22:06:34 -07:00
J. Nick Koston 3142a106fc
Additional prep work for sqlalchemy 2.0 (#70358) 2022-04-21 12:39:18 -10:00
J. Nick Koston 034ba7d3ff
Only read HomeKit service/chars from disk once (#70354) 2022-04-21 13:54:44 -07:00
J. Nick Koston f1b400feaf
Revert changes from #70300 part 2 (#70386) 2022-04-21 10:50:00 -10:00
J. Nick Koston 23de8d4156
Revert changes to test/conftest.py from #70300 (#70385) 2022-04-21 10:49:47 -10:00
Jason Hunter 22db21b9d4
Add diagnostics to ONVIF (#69708) 2022-04-21 11:38:20 -07:00
Franck Nijhof d08b751a85
Add unique ID to scripts (#70345) 2022-04-21 20:04:02 +02:00
jjlawren ac88d0be14
Add Sonos favorites sensor (#70235) 2022-04-21 10:37:16 -07:00
Erik Montnemery 9bec649323
Restore state of trigger-based template sensor (#69344) 2022-04-21 09:32:18 -07:00
Erik Montnemery 7b1e0e42f7
Allow device conditions and triggers for unitless sensors (#70337) 2022-04-21 09:31:15 -07:00
Jeef 4d09078114
IntelliFire Config API Token Config Update (#68134)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-21 09:14:13 -07:00
J. Nick Koston 73a368c242
Refactor history_stats to minimize database access (part 2) (#70255) 2022-04-21 09:06:59 -07:00
ollo69 f6e5e1b167
Simplify AsusWRT config flow (#69800) 2022-04-21 08:23:40 -07:00
Allen Porter a2c74b9786
Add initial implementation of a calendar trigger (#68674)
* Add initial implementation of calendar trigger

This is an initial implementation of a calendar trigger, that supports
triggering on calendar start time.

See architecture proposal in:
https://github.com/home-assistant/architecture/discussions/700

* Address reviewer feedback

* Use f-strings for all tests

* Apply suggestions from code review

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

* Remove logging f-strings, and move to main code

* Remove mypy ignore

* Apply suggestions from code review

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

* Update calendar triggers to use new calendar data model

* Update tests/components/calendar/test_trigger.py

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

* Rewrite tests using freezegun

Rewrite tests using freezegun and improve edge case handling, and use utc consistently for all alarms.

* Update homeassistant/components/calendar/trigger.py

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

* Update homeassistant/components/calendar/trigger.py

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

* Increase test coverage based on pr feedback

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2022-04-21 08:09:50 -07:00
Franck Nijhof 7003862bd8
Fix Plugwise to not use invalid discovery data (#70366) 2022-04-21 16:06:22 +03:00
Raman Gupta 220cb57add
Bump zwave-js-server-python to 0.35.3 (#70357) 2022-04-21 14:14:39 +02:00
Erik Montnemery de9f39745b
Fix race in _process_recorder_platform (#70339)
* Fix race in _process_recorder_platform

* Update homeassistant/components/recorder/__init__.py

Co-authored-by: J. Nick Koston <nick@koston.org>

* Update tests

Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-21 09:03:05 +02:00
Raman Gupta c390834ae4
Add available tones property to siren entity description (#70216)
* Fix siren entity description and available tones property

* Add test

* Fix bug

* Add coverage
2022-04-21 02:33:22 -04:00
Erik Montnemery 5e50a8abd5
Mark device triggers from hidden or auxiliary entities as secondary (#70335)
* Mark device triggers from hidden or auxiliary entities as secondary

* Update tests
2022-04-21 08:01:32 +02:00
Allen Porter 0e0c0ce22b
Move google calendar integration to aiohttp (#70173)
* Use new aiohttp based google client library in gcal_sync.

* Use base url in tests for shorter string

* Remove unnecessary line of code

* Jump to gcal-sync-0.4.1

* Update tests/components/google/conftest.py

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

* Update to gcal_sync 0.5.0 incorporating PR feedback

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-04-20 20:18:24 -07:00
Franck Nijhof 35687def02
Merge stop & error script actions (#70109) 2022-04-20 14:22:37 -07:00
Steven Looman bddfbe01f3
Better handle devices changing UDN and/or location in upnp component (#70008) 2022-04-20 11:01:43 -10:00
Franck Nijhof bfc82b030f
Replace Climate CURRENT_HVAC_* constants with HVACAction enum (#70319) 2022-04-20 13:41:05 -07:00
Erik Montnemery 150f173eed
Mark device conditions from hidden or auxiliary entities as secondary (#70333) 2022-04-20 21:41:59 +02:00
Erik Montnemery 7c0b0f7cc1
Migrate homekit_controller light to color_mode (#69261) 2022-04-20 09:26:15 -10:00
Erik Montnemery 64381acbaf
Mark device actions from hidden or auxiliary entities as secondary (#70278) 2022-04-20 10:48:46 -07:00
Glenn Waters 2a99084911
ElkM1 integration, add strict types to config_flow (#70323) 2022-04-20 10:46:36 -07:00
Johann Vanackere b0ed42a5a5
Fix #69952: Daikin AC Temperature jumps after being set (#70326) 2022-04-20 10:43:44 -07:00
Paulus Schoutsen b049ffca23
Add Insteon USB discovery (#70306)
* Add Insteon USB discovery

* Update tests/components/insteon/test_config_flow.py

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

* Black

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-04-20 10:07:35 -07:00
akloeckner d20a620590
Make `this` variable available in template entities (#65201)
* feat: make this variable available in template entities

This makes the variable `this` available in template entities.
It will simplify the use of self-referencing template entities.
Because, without this, we have to repeat the entity id every time.
If we can solve this without explicitly spelling the entity id,
code can be re-used much better.

As a side-effect, this will allow to use `variables`-like patterns,
where attributes can be used as variables to calculate subsequent attributes or state.

Example:
```yaml
template:
  sensor:
    - name: test
      state: "{{ this.attributes.test }}"
      # not: "{{ state_attr('sensor.test', 'test' }}"
      attributes:
        test: "{{ now() }}"
```

* expose entity_id instead of this

* add test

* Refactor to expose this variable

* Tweak repr dunder

Co-authored-by: Erik <erik@montnemery.com>
2022-04-20 15:30:17 +02:00
Franck Nijhof a22f36178f
Replace Climate HVAC_MODE_* constants with HVACMode enum (#70286)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-20 13:20:53 +02:00
Shay Levy 70616d2b78
Revert "Add humidity to tomorrowio hourly weather forecasts (#70186)" (#70311)
This reverts commit febcab11fb.
2022-04-20 11:56:13 +03:00
Diego Elio Pettenò 16de5edcbf
Don't attempt to set invalid fan percentage and preset_mode (try 3) (#70294)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-19 23:59:57 -07:00
Franck Nijhof c460100af1
Add backup.create service (#70118) 2022-04-20 08:56:05 +02:00
arantes555 a1f33a093c
Generic thermostat temp step (#70303)
* Add target_temp_step to generic_thermostat

* Add target_temp_step to generic_thermostat : fix default + add tests

* Add target_temp_step to generic_thermostat : fix test by using new 'units_imperial' fixture
2022-04-20 01:19:59 +03:00
J. Nick Koston 309424d3b9
Prevent tests changing units from affecting other tests (#70300)
* Prevent tests changing temperature_unit from affecting other tests

* tweak
2022-04-19 11:38:52 -10:00
J. Nick Koston 27c9e96865
Fix flapping goalzero tests (#70298) 2022-04-19 23:38:07 +02:00
J. Nick Koston c08afca912
Revert "Add target_temp_step to generic_thermostat (#58691)" (#70299)
This reverts commit ba4ca3e38e.
2022-04-19 22:46:42 +03:00
Paulus Schoutsen 78f5614cdc
Add extra tests for input text (#70283) 2022-04-19 19:31:09 +02:00
lymanepp febcab11fb
Add humidity to tomorrowio hourly weather forecasts (#70186)
* Add humidity to hourly weather forecasts

* Don't include humidity in daily forecasts

* Fix test
2022-04-19 19:14:07 +03:00
Mask3007 2228ea5ee0
Add update entity to fritz integration (#70096) 2022-04-19 17:12:21 +02:00
Álvaro Fernández Rojas 5729209d5d
Update aioairzone to v0.4.0 (#70280) 2022-04-19 17:03:13 +02:00
arantes555 ba4ca3e38e
Add target_temp_step to generic_thermostat (#58691)
* Add target_temp_step to generic_thermostat

* Add target_temp_step to generic_thermostat : fix default + add tests
2022-04-19 17:16:37 +03:00
Franck Nijhof d65e12ab6e
Add clear_skipped service to update entity (#70116) 2022-04-19 16:11:16 +02:00
Joakim Sørensen 9525077574
Add diagnostics platform to the Supervisor integration (#70265)
* Add diagnostics platform to the Supervisor integration

* Apply suggestions from code review

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

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-04-19 12:16:36 +02:00
Diogo Gomes 03874d1b65
Correct state restoring for Utility Meter sensors (#66851)
* fix merge

* backward compatability

* add status

* increase coverage

* increase further the coverage

* adds support for Decimal in SensorExtraStoredData

* more precise

* review

* don't restore broken last_reset

* increase coverage

* address review comments

* stale

* coverage increase

* Update homeassistant/components/utility_meter/sensor.py

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

* catch corrupt files and respective tests

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-04-19 09:01:52 +02:00
Diogo Gomes 9dfd37c60b
Use CONF_NAME consistently in utility meter sensors with and without tariffs (#69152)
* apply name to tariff based sensors too

* change name without breaking entity_id

* address comments
2022-04-19 09:00:36 +02:00
hesselonline 84666ce05e
Rename wallbox non-config CONF_ variables (#69737) 2022-04-19 08:44:25 +02:00
J. Nick Koston d03760d0bb
Switch to using ULIDs for context_ids (#70246) 2022-04-18 22:45:41 -07:00
J. Nick Koston e70c8fa359
Refactor history_stats to minimize database access (part 1) (#70134) 2022-04-18 13:18:38 -10:00
IceBotYT 6c75eaa1bc
Add outage map alerts to PECO (#69825) 2022-04-18 23:22:14 +02:00
J. Nick Koston f63465bd71
Add recorder platform to input_select (#70223) 2022-04-18 22:18:19 +02:00
Thomas Lovén b50f369fe4
Add shorthand notation for boolean conditions (#70120) 2022-04-18 22:09:09 +02:00
Sebastian Lövdahl 8f4979ea17
Reduce state updates for OctoPrint (#70146) 2022-04-18 21:33:40 +02:00
ollo69 f4d4b52204
Improve AsusWrt test coverage (#70215)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-18 09:20:40 -10:00
Franck Nijhof ce1f074ca9
Add Template selector (#70229) 2022-04-18 11:28:01 -07:00
Franck Nijhof 1e4aacaeb1
Replace Alarm Control Panel FORMAT_ constants with CodeFormat enum (#69861) 2022-04-18 19:37:32 +02:00
Franck Nijhof 81f3c82aef
Add recorder platform to input_text (#70227) 2022-04-18 08:22:14 -07:00
Franck Nijhof ec92c295d4
Add recorder platform to input_number (#70226) 2022-04-18 08:21:53 -07:00
Franck Nijhof 5d62f405f1
Add recorder platform to input_datetime (#70225) 2022-04-18 08:19:55 -07:00
Franck Nijhof fc4e9b0cc3
Add recorder platform to input_button (#70224) 2022-04-18 08:18:46 -07:00
Dave T d69a7e7be9
Hide credentials from generated titles in generic camera (#70204) 2022-04-18 07:57:52 -07:00
Greg Dowling 23264c8fd4
Improve roon integraton (#66000)
* Update to new library, revise discovery to work with new library, specify port to work with new library.

* Move user gui to fallback.

* Revise tests.

* Handle old config.

* Improve debugging, refresh faster on load.

* Remove duplicate.

* Bump library version.

* Fix docstring per review.

* Review suggestion

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

* Review suggestion

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

* Add check for duplicate host.

* Add error message to strings.

* Tidy.

* Review changes.

* Remove default.

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-04-18 16:27:14 +02:00
J. Nick Koston c3108b3899
Exclude attributes for automation and script domains (#70168) 2022-04-18 12:10:18 +02:00
Franck Nijhof 38a1ef45ed
Add recorder platform to input_boolean (#70154)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-18 11:38:48 +02:00
J. Nick Koston 026e1635cc
Rename async_process_integration_platform to async_process_integration_platform_for_component (#70217) 2022-04-17 20:59:31 -10:00
J. Nick Koston a9a5645255
Defer profiler imports until needed to reduce memory pressure (#70202) 2022-04-17 20:16:25 -10:00
jjlawren c53aa50093
Rework Sonos discovery & availability (#70066) 2022-04-17 22:54:51 -07:00
J. Nick Koston 40eb1554d9
Only set attributes based on the configured type for min_max sensors (#70142) 2022-04-17 22:53:49 -07:00
J. Nick Koston b4ef150339
Add a guard when there are no integration platforms loaded (#70182) 2022-04-17 22:45:52 -07:00
Dave T 32f9aefb40
Auto set content type for stream-only in generic camera (#70200) 2022-04-17 22:28:25 -07:00
J. Nick Koston 42c448c422
Add the ability to process integration platforms on demand (#70174) 2022-04-17 00:23:00 -10:00
Raman Gupta 3bcd921a28
Add entity registry helper to update entity platform (#69162)
* Add entity registry helper to migrate entity to new platform

* Add additional assertion

* Add more properties to migration logic

* Change logic after thinking about erik's comments

* Require new_config_entry_id if entry.config_entry_id is not None

* Create private async_update_entity function that all update functions use

* Don't have special handling for entity ID missing in async_update_entity_platform

* fix docstring
2022-04-16 16:18:52 -04:00
Robert Svensson f0b1d35562
Address late review of deconz climate (#70148)
* Fix late comment

* Avoid unnecessary properties

* Add clip sensor test to increase coverage of climate

* Fix review_comment
2022-04-16 21:14:54 +02:00
J. Nick Koston ad1241a116
Fix missing patching of homekit matchers in zeroconf tests (#70141) 2022-04-16 16:41:10 +02:00
Thomas Lovén 7cc799becf
Fix setup failure tests failing for the wrong reason (#70144) 2022-04-16 11:59:38 +02:00
Raman Gupta 7c875bf658
Correct tomorrowio weather units (#70107) 2022-04-15 23:20:54 +03:00
Paulus Schoutsen 5f6a970826
Bump pyevilgenius to 2.0.0 (#70074)
* Bump pyevilgenius to 2.0.0

* Fix tests
2022-04-15 20:54:20 +03:00
J. Nick Koston 03c91dad78
Fix missing title placeholders during unifiprotect reauth (#70067) 2022-04-15 07:31:50 -10:00
Franck Nijhof 1b48d7eda1
Add for each item support to repeat action (#70093) 2022-04-15 19:10:25 +02:00
Franck Nijhof e04fef3c2d
Allow disabling specific triggers/actions/conditions (#70082) 2022-04-15 09:33:09 -07:00
Joakim Sørensen ae9315aa29
Limit Supervisor refresh updates (#70075) 2022-04-15 09:31:02 -07:00
J. Nick Koston 89807f0d2d
Reduce the number of queries needed to compile statistics (#69731)
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-04-15 09:13:29 -07:00
Álvaro Fernández Rojas abea7d3245
airzone: implement turn on/off (#70095)
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2022-04-15 16:13:59 +03:00
Milan Meulemans c932407560
Add SENZ OAuth2 integration (#61233) 2022-04-14 15:29:31 -07:00
J. Nick Koston c85387290a
Increase recorder queue max backlog to 40k, improve message (#70065) 2022-04-14 11:45:07 -10:00
Álvaro Fernández Rojas 459d775ad5
Update aioairzone to v0.3.8 (#70060) 2022-04-14 10:59:14 -10:00
Franck Nijhof cdabcce83a
Add ability to continue scripts/automations on error (#70004) 2022-04-14 13:43:14 -07:00
Robert Svensson 87551b7880
Improve typing of deCONZ climate platform (#69882)
* Improve typing of deCONZ climate platform

homeassistant/components/deconz/climate.py:153: error: Dict entry 0 has incompatible type "str": "bool"; expected "str": "str"  [dict-item]
homeassistant/components/deconz/climate.py:154: error: Dict entry 1 has incompatible type "str": "bool"; expected "str": "str"  [dict-item]
homeassistant/components/deconz/climate.py:176: error: Argument 1 to "get" of "Mapping" has incompatible type "Optional[Literal['off', 'low', 'medium', 'high', 'on', 'auto', 'smart']]"; expected "str"  [arg-type]
homeassistant/components/deconz/climate.py:200: error: Argument 1 to "get" of "Mapping" has incompatible type "Optional[Literal['off', 'auto', 'cool', 'heat', 'emergency heating', 'precooling', 'fan only', 'dry', 'sleep']]"; expected "str"  [arg-type]
homeassistant/components/deconz/climate.py:218: error: Argument 1 to "set_config" of "Thermostat" has incompatible type "**Dict[str, str]"; expected "Optional[int]"  [arg-type]
homeassistant/components/deconz/climate.py:218: error: Argument 1 to "set_config" of "Thermostat" has incompatible type "**Dict[str, str]"; expected "Optional[bool]"  [arg-type]
homeassistant/components/deconz/climate.py:218: error: Argument 1 to "set_config" of "Thermostat" has incompatible type "**Dict[str, str]"; expected "Optional[List[str]]"  [arg-type]
homeassistant/components/deconz/climate.py:225: error: Argument 1 to "get" of "Mapping" has incompatible type "Optional[Literal['holiday', 'auto', 'manual', 'comfort', 'eco', 'boost', 'complex']]"; expected "str"  [arg-type]
homeassistant/components/deconz/climate.py:244: error: Unused "type: ignore" comment
homeassistant/components/deconz/climate.py:250: error: Unused "type: ignore" comment
homeassistant/components/deconz/climate.py:253: error: Unused "type: ignore" comment

* Simplify populating supported_hvac_modes
Fix tests
2022-04-14 23:19:42 +03:00
Paulus Schoutsen a5134d9ba2
Check supported features in media player reproduce state (#70055) 2022-04-14 12:44:41 -07:00
Raman Gupta 60ac53374b
Fix tomorrow.io units... again... (#70029) 2022-04-14 09:58:16 -07:00
J. Nick Koston c73cf2cf50
Fix race during homekit controller pairing (#69948) 2022-04-14 09:57:36 -07:00
Allen Porter 36bb947cdf
Fix bug in google calendar offset calculation (#70024)
Move the offset reached computation outside of the update method so that it is
computed when state updates occur rather than when data refreshes happen (which
are throttled and happen at most every 15 minutes).

Issue #69892
2022-04-13 19:04:59 -07:00
Diogo Gomes 8e64ae8478
Add unique_id to utility_meter sensors (#68596)
Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-04-13 23:58:15 +02:00
Shay Levy d4d819679c
Add Shelly gen2 authentication support (#69753) 2022-04-14 00:30:03 +03:00
Maciej Bieniek 7edbe66b26
Add `diagnostics` platform for GIOS integration (#69918)
* Add diagnostics platform

* Fix fixture data
2022-04-14 00:12:56 +03:00
Michael Chisholm 37bf504828
Fix config_flow error for UPnP info with single service (#69979) 2022-04-13 10:53:04 -10:00
Franck Nijhof d704d4f853
Add parallel automation/script actions (#69903) 2022-04-13 13:07:44 -07:00
Maciej Bieniek 74e9c050af
Add `diagnostics` platform for Airly integration (#69874)
Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>
2022-04-13 19:22:37 +02:00
Diogo Gomes fa28ee1f14
Remove deprecated unit configuration option from integration integration (#69157) 2022-04-13 19:19:34 +02:00
Álvaro Fernández Rojas c76b21e24e
Support specifying Airzone System ID (#69751) 2022-04-13 19:12:21 +02:00
Michael Chisholm 4e57b1b118
Fix config_flow error from dlna_dmr for UPnP discovery info containing a single service (#69977) 2022-04-13 19:04:03 +02:00
J. Nick Koston ad5d7a845b
Fix HomeKit Controller device class for CO Sensors (#69949) 2022-04-13 07:50:56 +02:00
Paulus Schoutsen f6a3598070
Guard against non http schemes (#69938) 2022-04-12 15:27:20 -07:00
Franck Nijhof fb92fc6a8e
Trigger on not matching to/from states (#69760) 2022-04-12 14:18:23 -07:00
Steven Looman 0d6d8a17e3
Drop upnp options flow (#69134) 2022-04-12 14:10:54 -07:00
Erik Montnemery ba07663e7d
Fix adjusting statistics in ft³ (#69913)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-04-12 14:08:38 -07:00
Erik Montnemery eb3458a3d2
Add MutexPool for recorder tests (#69410)
* Add MutexPool for recorder tests

* Fix get_schema_version

* Update test test_last_run_was_recently_clean

* Update test test_shutdown_before_startup_finishes

* Revert comments in test_write_lock_db

* Make the MutexPool lock a class variable

* Remove stale comment

* Move MutexPool

* Tweak debug prints
2022-04-12 07:41:46 -10:00
Erik Montnemery 1645ab25a6
Use quickplay when casting splash for mediaplayer.turn_on (#69866) 2022-04-12 10:06:25 -07:00
Erik Montnemery 80ff1ecb2a
Fix adjusting 5-minute statistics (#69921) 2022-04-12 18:10:17 +02:00
Erik Montnemery a9742cc445
Drop frontend metadata from entity service schemas (#69894) 2022-04-12 18:09:06 +02:00
Franck Nijhof d1f4b7a3d9
Fix climate HVAC device condition (#69908) 2022-04-12 15:31:59 +02:00
Franck Nijhof 67b200a532
Add if/else automation/script action (#69811)
Co-authored-by: Erik <erik@montnemery.com>
2022-04-12 15:02:17 +02:00
epenet d8d1e98d4e
Fix unique id in SamsungTV config flow (#69899)
* Fix unique id in SamsungTV config flow

* coverage

Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-11 23:37:05 -10:00
Joakim Sørensen 2ebbdf45f8
Handle add-on issues (#69897) 2022-04-12 11:00:55 +02:00
David F. Mulcahey 5f37f58673
Add diagnostics support for ZHA (#69756) 2022-04-11 22:35:29 -07:00
Franck Nijhof c93c7e8eff
Replace Camera STREAM_ constants with StreamType enum (#69871) 2022-04-11 16:27:27 -07:00
Franck Nijhof 81d90b1bc7
Add stop/error script/automation action (#67340) 2022-04-11 14:22:22 -07:00
Franck Nijhof 7087020283
Allow any entity to match state condition (#69763) 2022-04-11 10:53:42 -07:00
Franck Nijhof 27bc5e1d74
Add ColorMode enum to light platform (#69223) 2022-04-11 18:18:29 +02:00
Marvin Wichmann 3d30a757bf
Update xknx to 0.20.2 (#69853) 2022-04-11 16:51:13 +02:00
Franck Nijhof 6524dd8fb7
Add support for expanding zones in templates (#69793) 2022-04-11 12:59:45 +02:00
Raman Gupta b325c112b4
Add SelectorType enum and TypedDicts for each selector's data (#68399)
* rebase off current

* rearrange

* Overload selector function

* Update/fix all selector references

* better typing?

* remove extra option

* move things around

* Switch to Sequence type to avoid ignoring mypy error

* Get rid of ...'s

* Improve typing to reduce number of ignores

* Remove all typing ignores

* Make config optional for selectors that don't need a config

* add missing unit prefixes

* Rename TypedDicts

* Update homeassistant/helpers/selector.py

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

* review feedback

* remove peta from integration integration

* Fix min_max

* Revert change to selector function

* Fix logic

* Add typing for selector classes

* Update selector.py

* Fix indent

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-04-11 09:20:56 +02:00
Franck Nijhof 800bf926aa
Add attribute to zone indicating persons in zone (#69767)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-04-10 23:36:40 -07:00
jjlawren 016f67b855
Retry on more Plex connection failures during startup (#69822) 2022-04-10 22:25:19 -07:00
Allen Porter f99b6004ea
Cleanup calendar APIs and introduce a dataclass for representing events (#68843)
* Introduce data class to hold calendar event data

* Rename CalendarEventDevice to CalendarEntity

* Apply suggestions from code review

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

* Fix docstring on google calendar api conversion function.

* Update todoist to new calendar enttiy api, tested manually

* Add back old API for a legacy compatibility layer

* Add deprecation warning for old calendar APIs

* Fix deprecation warning

* Fix merge for missing summary #69520

* Add mypy typing for newly introduced classes

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-04-10 12:04:07 -07:00
Matthias Alphart b3d1574a71
Refactor KNX config flow and validate user input (#69698)
* validate config flow user input

* test flow for invalid user input

* validate multicast address blocks

* Update homeassistant/components/knx/config_flow.py

Co-authored-by: Marvin Wichmann <me@marvin-wichmann.de>

Co-authored-by: Marvin Wichmann <me@marvin-wichmann.de>
2022-04-10 15:56:45 +02:00
Allen Porter a063f55c82
Handle expired credentials in reauth in google calendar initialization (#69772)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-04-09 23:01:48 -07:00
Christopher Bailey ad29d89484
Fix unifiprotect for 2.0.0-beta2 of UniFi Protect (#69762) 2022-04-09 11:34:48 -10:00
Mike Fugate 836b051be9
Fix SleepIQ firmness number step and min values (#69757)
* fix sleepiq firmness number step and min values

* add asserts for min/max/step attributes
2022-04-09 22:46:58 +03:00
J. Nick Koston fe6a4bfb1d
Remove EVENT_TIME_CHANGED and EVENT_TIMER_OUT_OF_SYNC (#69643)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-04-09 09:05:54 -10:00
J. Nick Koston 689b347904
Increase tplink effects random seed allowed range to 1-600 (#69725)
* Increase tplink effects random seed allowed range to 1-600

Reported https://community.home-assistant.io/t/tp-link-integration-support-for-kl430-led-light-strip/190635/62?u=bdraco

* cover
2022-04-09 10:08:17 +03:00
Allen Porter d76fb2d891
Remove unnecessary async from test fixtures (#69722) 2022-04-09 08:33:24 +02:00
Dave T 6d17f4ffff
Support webp still image format in generic camera (#69718) 2022-04-08 23:06:34 -07:00
epenet 071ef6c74f
Fix upnp subscription in SamsungTV (#69652)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-04-08 23:05:00 -07:00
Dave T 6fd041b290
Don't test config on yaml import for generic camera (#69714) 2022-04-08 22:59:54 -07:00
Shay Levy 06e4c2f351
Fix Shelly gen2 cover unavailable when not calibrated (#69671) 2022-04-08 22:54:42 -07:00
Allen Porter 06d2aeec6b
Refresh google calendar tokens with invalid expiration times (#69679)
* Refresh google calendar tokens with invalid expiration times

* Update tests/components/google/conftest.py

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

* Remove unnecessary async methods in functions being touched already

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-04-08 20:27:58 -07:00
Marvin Wichmann b5b514b62f
Full test coverage for KNX integration (#69697)
* Full test coverage for KNX integration

* Allow for 0 values, since we all live at those kind of areas in the world

* Remove unneeded method

* Add missing test for climate mode

* Cleanup test and remove fixture that was used only once
2022-04-09 00:33:50 +02:00
Allen Porter d54cb49f32
Remove "XXX" from calendar tests and implement real test (#69677)
* Remove "XXX" from calendar tests and implement real test

Remove a placeholder that was accidentally commited in the
calendar tests, and replace with a real test.

* Remove stale comment
2022-04-08 18:46:51 +03:00
J. Nick Koston 72fffde77a
Fix spelling of periodic in recorder (#69658)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-04-07 23:37:02 -10:00
Allen Porter 1cce0a5744
Fix bugs calendar oauth token date handling (#69641) 2022-04-07 21:53:30 -07:00
J. Nick Koston 66f0a3816a
Reduce memory pressure during database migration (#69628) 2022-04-07 18:29:31 -10:00
Matt Zimmerman 8c00fde27d
[powerwall] Skip backup reserve sensor if data is unavailable (#69637) 2022-04-07 20:34:00 -07:00
Erik Montnemery 949b0e1b65
Don't allow in-memory SQLite database (#69616) 2022-04-08 00:43:09 +02:00
puddly fab1f29a29
Move new `zha_event` command parameters into a `params` key to ensure backwards compatibility (#69631) 2022-04-07 15:33:14 -07:00
Dave T be8e28503c
Generic fix stream thumbnail (#69378) 2022-04-07 15:01:29 -07:00
Diogo Gomes a3cfb6d4ae
Fix utility_meter reset service (#69612) 2022-04-07 23:55:34 +02:00
J. Nick Koston 6dc72ebf6c
Mark backgrounds optional for tplink random effects (#69622) 2022-04-07 23:19:17 +02:00
epenet a61ac3ddc6
Add EntityFeature enum to Siren (#69585)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2022-04-07 23:08:09 +02:00
Patrik Lindgren 74021d62da
Finalize deprecation of groups in Tradfri integration (#69460)
* Finalise cleanup of groups

* Fix tests

* Remove

* Revert change
2022-04-07 22:19:12 +02:00
Erik Montnemery 4a7c978f69
Speedup recorder test test_write_lock_db (#69578) 2022-04-07 15:36:58 +02:00
epenet 190ef4ee35
Use EntityFeature enum in components (s** 2/2) (#69441) 2022-04-07 15:06:34 +02:00
Erik Montnemery e8852e0f30
Migrate lcn light to color_mode (#69419) 2022-04-07 14:49:12 +02:00
J. Nick Koston 47c3aef7a2
Fix registered entities without a category not being exclude-able in the HomeKit UI (#69543) 2022-04-07 13:46:41 +02:00
Joakim Sørensen a5dc95e715
Fix adding OS entities for supervised installations (#69539) 2022-04-07 13:34:20 +02:00
Erik Montnemery 0ad9da9dd0
Always use a commit interval of 0 for the in memory db in tests (#69556) 2022-04-07 13:04:08 +02:00
J. Nick Koston 5c7c09726a
Cleanup recorder history typing (#69408) 2022-04-07 00:09:05 -10:00
epenet 75eec850c1
Use EntityFeature enum in components (u**) (#69462) 2022-04-06 21:35:15 -10:00
Erik Montnemery 9834197f71
Migrate myq light to color_mode (#69427) 2022-04-06 21:09:07 -10:00
Allen Porter 10a1b1f734
Gracefully handle empty summary in google calendar (#69520)
Gracefully handle empty summary in google calendar matching the old behavior
before some code cleanup.
2022-04-07 08:26:07 +02:00
Allen Porter c07100e519
Move Local OAuth http endpoint registration to auth component (#69507) 2022-04-06 22:34:31 -07:00
J. Nick Koston d6619dd4bc
Fix reloading the sun integration (#69495) 2022-04-06 16:06:22 -07:00
Michael 95421b1ae7
Ignore IPv6 link local address on ssdp discovery in Fritz!Smarthome (#69455) 2022-04-06 15:45:46 -07:00