Compare commits

..

815 Commits

Author SHA1 Message Date
Franck Nijhof
933e016150 Merge pull request #52627 from home-assistant/rc 2021-07-07 14:23:39 +02:00
Franck Nijhof
342366750b Bumped version to 2021.7.0 2021-07-07 13:09:52 +02:00
Franck Nijhof
a048809ca7 Bumped version to 2021.7.0b6 2021-07-07 11:21:23 +02:00
Bram Kragten
f7c844d728 Update frontend to 20210707.0 (#52624) 2021-07-07 11:21:06 +02:00
Franck Nijhof
998ffeb21d Fix broadlink creating duplicate unique IDs (#52621) 2021-07-07 11:21:03 +02:00
J. Nick Koston
a794c09a0f Fix deadlock at shutdown with python 3.9 (#52613) 2021-07-07 11:20:59 +02:00
Alexei Chetroi
a7ee86730c Bump up ZHA dependencies (#52611) 2021-07-07 11:20:56 +02:00
Chris
dd26bfb92b Fix mysensors rgb light (#52604)
* remove assert self._white as not all RGB will have a white channel

* suggested change

* Update homeassistant/components/mysensors/light.py

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

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2021-07-07 11:20:50 +02:00
Franck Nijhof
b14b284e62 Bumped version to 2021.7.0b5 2021-07-06 18:51:38 +02:00
Simone Chemelli
bad2525a6d Fix Fritz Wi-Fi 6 networks with same name as other Wi-Fi (#52588) 2021-07-06 18:51:23 +02:00
Robert Svensson
7a503a6c1f Make use of entry id rather than unique id when storing deconz entry in hass.data (#52584)
* Make use of entry id rather than unique id when storing entry in hass data

* Update homeassistant/components/deconz/services.py

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

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-07-06 18:51:19 +02:00
J. Nick Koston
40d9541d9b Revert nmap_tracker to 2021.6 version (#52573)
* Revert nmap_tracker to 2021.6 version

- Its unlikely we will be able to solve #52565 before release

* hassfest
2021-07-06 18:51:16 +02:00
Aaron Bach
746a52bb27 Fresh attempt at SimpliSafe auto-relogin (#52567)
* Fresh attempt at SimpliSafe auto-relogin

* Fix tests
2021-07-06 18:51:12 +02:00
ondras12345
90f4b3a4ed Fix update of Xiaomi Miio vacuum taking too long (#52539)
Home assistant log would get spammed with messages like
Update of vacuum.vacuum_name is taking over 10 seconds
every 20 seconds if the vacuum was not reachable through the network.

See #52353
2021-07-06 18:51:08 +02:00
Shay Levy
2c75e3fe99 Fix Sensibo timeout exceptions (#52513) 2021-07-06 18:51:05 +02:00
Raman Gupta
e1c14b5a30 Don't raise when setting HVAC mode without a mode ZwaveValue (#52444)
* Don't raise an error when setting HVAC mode without a value

* change logic based on discord convo and add tests

* tweak
2021-07-06 18:51:01 +02:00
Thibaut
631e555e25 Update Somfy to reduce calls to /site entrypoint (#51572)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-07-06 18:50:57 +02:00
Bram Kragten
422de2c56d Bumped version to 2021.7.0b4 2021-07-06 11:57:50 +02:00
Bram Kragten
2356c1e52a Update frontend to 20210706.0 (#52577) 2021-07-06 11:54:32 +02:00
Raman Gupta
2220c8cd3f Bump pyeight version to 0.1.9 (#52568) 2021-07-06 11:54:31 +02:00
Franck Nijhof
979d37dc19 Fix unavailable entity capable of triggering non-numerical warning in Threshold sensor (#52563) 2021-07-06 11:54:30 +02:00
J. Nick Koston
701fa06584 Bump aiohomekit to 0.4.2 (#52560)
- Changelog: https://github.com/Jc2k/aiohomekit/compare/0.4.1...0.4.2

- Fixes: #52548
2021-07-06 11:54:29 +02:00
Alexei Chetroi
1c9053fef6 Bump up zha dependencies (#52555) 2021-07-06 11:54:28 +02:00
J. Nick Koston
777cf116aa Update the ip/port in the homekit_controller config entry when it changes (#52554) 2021-07-06 11:54:27 +02:00
René Klomp
a52b4b0f62 Bump pysma version to 0.6.2 (#52553) 2021-07-06 11:54:26 +02:00
J. Nick Koston
dfce89f2c7 Bump zeroconf to 0.32.1 (#52547)
- Changelog: https://github.com/jstasiak/python-zeroconf/compare/0.32.0...0.32.1

- Fixes #52384
2021-07-06 11:54:25 +02:00
Tom Brien
0cd097cd12 Update list of supported Coinbase wallet currencies (#52545) 2021-07-06 11:54:24 +02:00
Franck Nijhof
9368f75cec Bumped version to 2021.7.0b3 2021-07-05 13:41:25 +02:00
Franck Nijhof
d5b419eeda Remove problematic/redudant db migration happning schema 15 (#52541) 2021-07-05 13:41:01 +02:00
J. Nick Koston
e140cd9b6a Bump HAP-python to 3.5.1 (#52508)
- Fixes additional cases of invalid mdns hostnames
2021-07-05 13:40:57 +02:00
jan iversen
206437b10c Fix MODBUS connection type rtuovertcp does not connect (#52505)
* Correct host -> framer.

* Use function pointer
2021-07-05 13:40:54 +02:00
J. Nick Koston
36eec7ddbc Remove empty hosts and excludes from nmap configuration (#52489) 2021-07-05 13:40:51 +02:00
Aaron Bach
afb187942a Revert "Force SimpliSafe to reauthenticate with a password (#51528)" (#52484)
This reverts commit 549f779b06.
2021-07-05 13:40:47 +02:00
J. Nick Koston
070991c160 Bump aiohomekit to 0.4.1 (#52472)
- Fixes mdns queries being sent with the original case received on the wire
  Some responders were case sensitive and needed the original case sent

- Reduces mdns traffic
2021-07-05 13:40:44 +02:00
Franck Nijhof
ebc3e1f658 Fix Statistics recorder migration path by dropping in pairs (#52453) 2021-07-05 13:40:40 +02:00
Maciej Bieniek
d2cef65b63 Bump gios library to version 1.0.2 (#52527) 2021-07-05 09:23:02 +02:00
Franck Nijhof
95132cc425 Bumped version to 2021.7.0b2 2021-07-02 21:07:17 +02:00
Franck Nijhof
4b077b5a39 Fix Statistics recorder migration order (#52449) 2021-07-02 21:06:52 +02:00
Simone Chemelli
77c643946b Fix Fritz call deflection list (#52443) 2021-07-02 21:06:48 +02:00
Franck Nijhof
4b3ce4763d Abort existing reauth flow on entry removal (#52407) 2021-07-02 21:06:45 +02:00
Franck Nijhof
8b54d958f3 Bumped version to 2021.7.0b1 2021-07-02 17:58:59 +02:00
Erik Montnemery
730c8cbcc4 Correct recorder table arguments (#52436) 2021-07-02 17:57:38 +02:00
Erik Montnemery
729f3dc6b8 Avoid duplicated database queries when fetching statistics (#52433) 2021-07-02 17:57:34 +02:00
Milan Meulemans
d04b0978df Fix typo in forecast_solar strings (#52430) 2021-07-02 17:57:29 +02:00
Franck Nijhof
66680e44e4 Upgrade aioimaplib to 0.9.0 (#52422) 2021-07-02 17:57:25 +02:00
Erik Montnemery
94638d316f Drop statistic_id and source columns from statistics table (#52417)
* Drop statistic_id and source columns from statistics table

* Remove useless double drop of statistics table

* Update homeassistant/components/recorder/models.py

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

* black

Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-07-02 17:57:21 +02:00
J. Nick Koston
e4a7347e7d Import track_new_devices and scan_interval from yaml for nmap_tracker (#52409)
* Import track_new_devices and scan_interval from yaml for nmap_tracker

* Import track_new_devices and scan_interval from yaml for nmap_tracker

* Import track_new_devices and scan_interval from yaml for nmap_tracker

* tests

* translate

* tweak

* adjust

* save indent

* pylint

* There are two CONF_SCAN_INTERVAL constants

* adjust name -- there are TWO CONF_SCAN_INTERVAL constants

* remove CONF_SCAN_INTERVAL/CONF_TRACK_NEW from user flow

* assert it does not appear in the user step
2021-07-02 17:57:17 +02:00
Raman Gupta
e2e72851d7 Bump eight sleep dependency to fix bug (#52408) 2021-07-02 17:57:13 +02:00
Franck Nijhof
e8ed497950 Upgrade wled to 0.7.1 (#52405) 2021-07-02 17:57:08 +02:00
Tom Brien
527af96ad9 Add update listener to Coinbase (#52404)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-07-02 17:57:05 +02:00
René Klomp
61bc95d704 Bump pysma to 0.6.1 (#52401) 2021-07-02 17:57:01 +02:00
Erik Montnemery
4959561bde Fix sensor statistics collection with empty states (#52393) 2021-07-02 17:56:57 +02:00
Erik Montnemery
eea544d2d2 Fix MQTT cover optimistic mode (#52392)
* Fix MQTT cover optimistic mode

* Add test
2021-07-02 17:56:53 +02:00
Joakim Plate
b8b0bc9392 Reject trusted network access from proxies (#52388) 2021-07-02 17:56:48 +02:00
Erik Montnemery
3dcad64d53 Improve sensor statistics tests (#52386) 2021-07-02 17:56:44 +02:00
Aaron Bach
5cc878fc79 Fix missing default latitude/longitude/elevation in OpenUV config flow (#52380) 2021-07-02 17:56:40 +02:00
Alexei Chetroi
8de7312c92 Bump up ZHA dependencies (#52374)
* Bump up ZHA dependencies

* Fix broken tests

* Update tests/components/zha/common.py

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

Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-07-02 17:56:36 +02:00
Tobias Sauerwein
c783ef49c7 Bump pyatmo to v5.2.0 (#52365)
* Bump pyatmo to v5.2.0

* Revert formatting changes
2021-07-02 17:56:32 +02:00
Frederik Bolding
6d346a59c2 Bump bt_proximity (#52364) 2021-07-02 17:56:28 +02:00
J. Nick Koston
96998aafe3 Update homekit_controller to use async zeroconf (#52330) 2021-07-02 17:56:24 +02:00
Bruce Sheplan
b565dcf3b0 Add screenlogic reconnect (#52022)
Co-authored-by: Kevin Worrel <37058192+dieselrabbit@users.noreply.github.com>
2021-07-02 17:56:20 +02:00
Franck Nijhof
355e557c24 Bumped version to 2021.7.0b0 2021-06-30 16:55:41 +02:00
Erik Montnemery
d450cda385 Report target unit in statistics meta data (#52341) 2021-06-30 16:53:51 +02:00
Matthias Alphart
9ed93de472 xknx 0.18.8 (#52340) 2021-06-30 15:06:33 +02:00
Erik Montnemery
9d0c4c168e Convert units when fetching statistics (#52338) 2021-06-30 14:53:42 +02:00
jan iversen
c0751c060f review comments. (#52337) 2021-06-30 14:34:33 +02:00
Erik Montnemery
0476c7f9ee Normalize temperature statistics to °C (#52297)
* Normalize temperature statistics to °C

* Fix tests

* Support temperature conversion to and from K, improve tests

* Fix test

* Add tests, pylint
2021-06-30 14:17:58 +02:00
Bram Kragten
508f9a8296 Update frontend to 20210630.0 (#52336) 2021-06-30 13:34:28 +02:00
Erik Montnemery
0ab999738b Add statistics meta data table (#52331)
* Add statistics meta data table

* Tweak meta data generation
2021-06-30 13:32:17 +02:00
stefano055415
d8337cf98f Add Freedompro (#46332)
Co-authored-by: Milan Meulemans <milan.meulemans@live.be>
Co-authored-by: Maciej Bieniek <bieniu@users.noreply.github.com>
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-06-30 13:21:06 +02:00
Tom Schneider
dc407fe7a1 Fix MusicCast subwoofers (#52335) 2021-06-30 13:09:57 +02:00
mlemainque
a7ece4ecaa Fix Daikin integration power sensors (#51905) 2021-06-30 12:01:08 +02:00
Brian Towles
3e4dacb885 Add Modern Forms binary sensor platform (#52312)
Co-authored-by: Erik Montnemery <erik@montnemery.com>
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-06-30 11:56:02 +02:00
Aaron Bach
3902f0bdd4 Speed up lookup of AirVisual pollutant labels, levels, and units (#52327)
* Speed up lookup of AirVisual pollutant levels, labels, and units

* Mispellings
2021-06-30 11:33:50 +02:00
Anaïs Betts
da9bb99ba8 Create service to enable Continuous Mode on Nuki Opener (#51861) 2021-06-30 08:43:02 +02:00
Carlos Gomes
f2906d0fca Add quantiles to Statistics integration (#52189)
* Add quantiles as another Statistics attribute

Quantiles divide states into intervals of equal probability. The
statistics.quantiles() function was added in Python 3.8 and can now
be included in the Statistics integration without new dependencies.

Quantiles can be used in conjunction with other distribution metrics to
create box plots (quartiles) and other graphical resources for
visualizing the distribution of states.

* Add quantiles reference to basic tests
2021-06-30 08:31:33 +02:00
J. Nick Koston
9f16e390f5 Deprecate IPv6 zeroconf setting in favor of the network integration (#51173) 2021-06-29 17:13:31 -10:00
Fredrik Erlandsson
3c20f2dd42 Fix point ConnectionTimeout during startup (#52322) 2021-06-29 21:10:25 -04:00
GitHub Action
5baaede85b [ci skip] Translation update 2021-06-30 00:11:18 +00:00
Daniel Hjelseth Høyer
04d8f88269 Fix Mill consumption data (#52320)
Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2021-06-30 01:31:56 +02:00
Otto Winter
f772eab7b7 ESPHome delete store data when unloading entry (#52296) 2021-06-29 15:06:24 -07:00
Erik Montnemery
cca5964ac0 Normalize pressure statistics to Pa (#52298) 2021-06-29 23:30:13 +02:00
J. Nick Koston
2eebfe6ff3 Fix esphome startup with missing api_version key (#52324) 2021-06-29 22:50:29 +02:00
Heine Furubotten
56d1bf255b Bump enturclient to v0.2.2 (#52321) 2021-06-29 16:34:09 -04:00
Franck Nijhof
7c39092aa8 Upgrade nmap tracker with forked package for compatibility (#52300)
* Upgrade nmap tracker with forked package for compatibility

* Bump to 0.7.0.2

* Bump cache version
2021-06-29 21:50:25 +02:00
Aaron Bach
ddef5d2314 Refactor Tile entity unique ID migration to use helper (#52315)
* Refactor Tile entity unique ID migration to use helper

* Clarify

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-29 21:15:56 +02:00
Pascal Vizeli
853ca331e4 Stop build wheels for python38 (#52309) 2021-06-29 20:33:38 +02:00
Franck Nijhof
aac0180abf Disable import of disabled eebrightbox in tests (#52314) 2021-06-29 19:59:25 +02:00
Aaron Bach
935f4d16a9 Fix small inconsistencies in RainMachine vegetation and sprinkler types (#52313) 2021-06-29 13:57:28 -04:00
Otto Winter
b43d0877e7 ESPHome Migrate to dataclasses (#52305) 2021-06-29 19:53:57 +02:00
Daniel Hjelseth Høyer
ba7ad8a58f Add Melcloud device class and state class (#52276) 2021-06-29 19:16:43 +02:00
Koen Kanters
2576dd9da9 Fix Todoist incorrect end date when task has no time (#52258) 2021-06-29 10:15:50 -07:00
Teemu R
6afa4d6914 Skip updating tplink bulb state if the new state not reported by the device (#52310) 2021-06-29 19:14:34 +02:00
Simone Chemelli
7959225fef Add switch platform to Fritz (#51610)
* Add switch platform to Fritz

* Fix tests

* Pylint

* Small fix

* Bump fritzprofiles to fix log level and identifier

* Fix different WiFi networks with same name

* Changed exposed attributes

* Moved to extra_state

* Remove redundant lambda

* Add missing wait

* Removed identifiers

* Update homeassistant/components/fritz/switch.py

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

* Update homeassistant/components/fritz/switch.py

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

* Add mapping dict

* Device Profile disabled by default

* Heavy cleanup

* Tweak

* Bug fix

* Update homeassistant/components/fritz/switch.py

Co-authored-by: Aaron David Schneider <aaron.schneider@nbi.ku.dk>

* Fix port forward switching + small log improvement

* Cleanup from old approach

* Handle port mapping hot removal (from device)

* Minor fixes

* Typying

* Removed lambda call

* Last missing strict typing

* Split get entities

* Func rename

* Move FritzBoxBaseSwitch to switch.py

* Removed lambda

* Update homeassistant/components/fritz/common.py

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

* Update homeassistant/components/fritz/common.py

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

* Update homeassistant/components/fritz/switch.py

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

* Update homeassistant/components/fritz/switch.py

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

* Update homeassistant/components/fritz/switch.py

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

* Update homeassistant/components/fritz/switch.py

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

* Fixes after applying comments

* Remvoed redundant try block

* Removed broad-except

* Optimized async/sync switch

* Update homeassistant/components/fritz/switch.py

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

* Update homeassistant/components/fritz/switch.py

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

* Update homeassistant/components/fritz/switch.py

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

* Address remaining comments

* Optimize return list

* More optimization for return lists

* Some missing strict typing

* Redundant typing

* Update homeassistant/components/fritz/switch.py

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

* Wrong if

* Introduce const for profile status

* Update homeassistant/components/fritz/switch.py

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

* Update homeassistant/components/fritz/switch.py

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

* Fix mypy

* Switch back to get_local_ip()

* Address latest comments

Co-authored-by: J. Nick Koston <nick@koston.org>
Co-authored-by: Aaron David Schneider <aaron.schneider@nbi.ku.dk>
2021-06-29 11:57:34 -04:00
Tom Brien
897f5d9247 Coinbase code quality improvements from review (#52307)
* Fix breaking loop if single bad currency

* Remove unneeded update

* Reduce executor calls and use helper

* Avoid setting up integration when not needed in test

* Remove defunct info from strings

* Move already configured check

* Move instance update out of data class init
2021-06-29 11:54:38 -04:00
Franck Nijhof
b11af5e6f8 Fix Garmin Connect sensor dependency import (#52306) 2021-06-29 16:39:25 +02:00
Erik Montnemery
8a00c3a2f5 Implement color_mode support for kulersky (#52080) 2021-06-29 16:31:29 +02:00
Franck Nijhof
f1b40b683d Disable dependency checks and tests for disabled EE Brightbox integration (#52304) 2021-06-29 16:09:42 +02:00
Joakim Sørensen
720a67957b Bump hass-nabucasa to 0.44.0 (#52303) 2021-06-29 16:04:21 +02:00
Franck Nijhof
d3210ada1d Allow None value return type for Number entity state value (#52302) 2021-06-29 15:07:31 +02:00
Erik Montnemery
6131ed09f0 Compile statistics for power sensors (#52299) 2021-06-29 14:48:08 +02:00
Jesse Hills
e1797ea670 Add number entities to ESPHome (#52241)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-29 14:33:04 +02:00
Adrián Moreno
a639cb7ba7 Add sensor platform to Meteoclimatic integration (#51467)
* Add meteoclimatic sensor platform

Signed-off-by: Adrian Moreno <adrian@morenomartinez.com>

* Add sensor.py to coverage file

Signed-off-by: Adrian Moreno <adrian@morenomartinez.com>

* Add explicit return type None

Signed-off-by: Adrian Moreno <adrian@morenomartinez.com>

* Fix sample station code

Signed-off-by: Adrian Moreno <adrian@morenomartinez.com>

* Apply frenck suggestions

Signed-off-by: Adrian Moreno <adrian@morenomartinez.com>

* Remove extra attributes

Signed-off-by: Adrian Moreno <adrian@morenomartinez.com>

* Revert translations

Signed-off-by: Adrian Moreno <adrian@morenomartinez.com>

* Remove None icons and classes

Signed-off-by: Adrian Moreno <adrian@morenomartinez.com>
2021-06-29 13:52:39 +02:00
Franck Nijhof
198b664409 Merge branch 'master' into dev 2021-06-29 13:46:39 +02:00
Franck Nijhof
3311b1bafb Small clean up for Motion Blinds (#52281) 2021-06-29 14:08:19 +03:00
Erik Montnemery
c785db4ffa Normalize energy statistics to kWh (#52238) 2021-06-29 12:20:10 +02:00
Erik Montnemery
b77f2b9e12 Filter MQTT camera JSON attributes (#52279)
* Filter MQTT camera JSON attributes

* Add missing attribute to blocked list
2021-06-29 12:14:02 +02:00
Erik Montnemery
39a064683a Filter MQTT cover JSON attributes (#52282) 2021-06-29 11:59:23 +02:00
Erik Montnemery
30a9198d97 Add test to MQTT device tracker (#52292) 2021-06-29 11:33:26 +02:00
Franck Nijhof
8a82557142 Demo: Remote improvements (#52265)
* Demo: Remote improvements

* Address pylint warning
2021-06-29 11:32:46 +02:00
Erik Montnemery
a7dd7c1a3d Filter MQTT select JSON attributes (#52288) 2021-06-29 11:22:58 +02:00
Erik Montnemery
74e61ab7f7 Filter MQTT switch JSON attributes (#52290) 2021-06-29 11:22:25 +02:00
Erik Montnemery
de4cfb0ce2 Filter MQTT vacuum JSON attributes (#52291) 2021-06-29 11:21:22 +02:00
Erik Montnemery
61f7f5c96a Filter MQTT sensor JSON attributes (#52289) 2021-06-29 11:19:40 +02:00
Erik Montnemery
e0f7987544 Filter MQTT fan JSON attributes (#52283) 2021-06-29 11:18:50 +02:00
Erik Montnemery
71a0e474cc Filter MQTT number JSON attributes (#52286) 2021-06-29 11:16:57 +02:00
Erik Montnemery
3b89fcfe83 Filter MQTT lock JSON attributes (#52285) 2021-06-29 11:16:07 +02:00
Jc2k
7de3e7d1dd Support setting hvac_mode and temp in same homekit_controller set_temperature service call (#52195)
* Support setting hvac_mode and temp in same set_temperature service call

* Update homeassistant/components/homekit_controller/climate.py

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>

* Update homeassistant/components/homekit_controller/climate.py

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2021-06-29 11:14:28 +02:00
Erik Montnemery
040c88f982 Filter MQTT climate JSON attributes (#52280) 2021-06-29 11:13:58 +02:00
Erik Montnemery
91b4f7d1d5 Filter MQTT alarm JSON attributes (#52278) 2021-06-29 10:32:23 +02:00
Aaron Bach
dee3e14df2 Fix values of RainMachine Freeze Protection and Hot Days binary sensors (#52275)
* Fix values of RainMachine Freeze Protection and Hot Days binary sensors

* Correct place

* Fix
2021-06-29 10:21:33 +02:00
Aaron Bach
04300464da Update RainMachine sprinkler and vegetation types (#52274) 2021-06-29 10:20:11 +02:00
Aaron Bach
5e18b5c189 Fix bug in detecting RainMachine zone soil type (#52273)
* Fix bug in detecting RainMachine zone soil type

* Simplify
2021-06-29 10:09:38 +02:00
Brian Towles
3ab42c50c9 Add sensor platform to Modern Forms integration (#52249)
* Add sensor platform to Modern Forms integration

* Changes to sensors to timestamp class

* lint cleanup
2021-06-29 10:05:39 +02:00
Chris Talkington
6a528acafe Use attrs instead of properties for ipp (#52270)
* use attrs instead of properties for ipp

* Update __init__.py

* Create entity.py

* Update __init__.py

* Create coordinator.py

* Update coordinator.py

* Update __init__.py

* Update entity.py

* Update sensor.py

* Update sensor.py

* Update __init__.py

* Update __init__.py

* Update coordinator.py

* Update entity.py

* Update entity.py

* Update entity.py

* Update sensor.py

* Update sensor.py
2021-06-29 10:02:49 +02:00
Xuefer
8c37dc5613 Clean up Onvif steps (#52254) 2021-06-29 09:30:56 +02:00
TOM
3f66709882 Fix caldav TZ interpretation of all day events (#48642) 2021-06-29 00:07:29 -07:00
Paulus Schoutsen
bb4d3bfc60 Reduce Ring TTL (#52277) 2021-06-29 08:57:32 +02:00
Franck Nijhof
8dd545d060 Demo: Sensor improvements (#52263) 2021-06-28 23:39:40 -07:00
Franck Nijhof
d37018cf87 Small tweaks to Rituals Perfume Genie (#52269) 2021-06-28 23:39:00 -07:00
Franck Nijhof
94a0259743 Add state class support to SAJ Solar Inverter (#52261) 2021-06-28 23:38:21 -07:00
Franck Nijhof
a93487f389 Add state class support to SolarEdge (#52271) 2021-06-28 23:37:33 -07:00
jan iversen
f1303e02ff Let climate use base_struct_schema. (#52154) 2021-06-28 22:21:31 -07:00
jan iversen
74e1600a84 Add fixture to handle mock restore state (#52198) 2021-06-28 22:21:04 -07:00
Daniel Hjelseth Høyer
1676bf220f Tibber, add device class monetary to accumulated cost (#52259)
Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2021-06-28 20:58:27 -07:00
GitHub Action
81ca5236bf [ci skip] Translation update 2021-06-29 00:25:47 +00:00
Aaron Bach
a448b72ff9 Remove bachya as 17track.net codeowner (#52262)
* Remove bachya as 17track.net codeowner

* Cleanup
2021-06-28 17:41:02 -06:00
Raman Gupta
d6fd7dde7f Bump zwave_js_server to 0.27.0 (#52267) 2021-06-28 18:49:40 -04:00
Milan Meulemans
dc94a45832 Clean up Rituals Perfume Genie integration (#52266) 2021-06-29 00:44:13 +02:00
Marius
7ce4763784 change processor_temperature icon (#52256)
* change processor_temperature icon

to indicate the temperature, using "mdi:thermometer"

* add DEVICE_CLASS_TEMPERATURE,

* add None for icon

* remove Icon from Last boot

since it uses the device_class already
2021-06-29 00:39:21 +02:00
Jc2k
42c944ce56 Add secondary temperature sensors to homekit_controller (#52194) 2021-06-28 23:48:29 +02:00
ollo69
c6efdedd3c Add AsusWRT load average sensors (#52230) 2021-06-28 22:33:15 +02:00
Aaron Bach
f538e07902 Update Tile unique ID to include username (#52175) 2021-06-28 21:36:18 +02:00
Farzad Noorian
fbf85fd86b Add OAuth 2.0 Bearer Token authentication to send_file for telegram_bot (#46567) 2021-06-28 20:43:23 +02:00
Matthias Alphart
d4211c4a66 Cleanup KNX supported_features for climate, cover and fan (#52218) 2021-06-28 20:22:44 +02:00
Tom Brien
9e50bd0b30 Only load requested coinbase accounts (#51981) 2021-06-28 20:21:04 +02:00
Milan Meulemans
6f41168616 Change DiffuserRoomSize number entity to select entity (#51993)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-06-28 20:20:32 +02:00
Tom Brien
a1c741a46d Provide correct defaults for CoinBase options flow (#52255) 2021-06-28 20:14:11 +02:00
Andre Lengwenus
f2fe6c26ab Add tests for LCN integration setup (#48070) 2021-06-28 18:08:09 +02:00
René Klomp
540d6e9fa5 Use pysma exceptions (#52252) 2021-06-28 16:59:17 +02:00
Xuefer
3a5ee00081 Merge onvif host/auth step, allow skipping scan (#49660) 2021-06-28 16:39:18 +02:00
Tom Brien
fd1d110b80 Add config flow for Coinbase (#45354)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-06-28 16:38:12 +02:00
Joakim Sørensen
efee36a176 Don't copy result to new list (#52248) 2021-06-28 15:54:23 +02:00
Erik Montnemery
c86b563fe1 Bump hatasmota to 0.2.19 (#52246) 2021-06-28 15:49:25 +02:00
René Klomp
5e721b2566 Update SMA device info on setup (#51159)
* Update device info on setup

* Remove migration
2021-06-28 15:32:29 +02:00
Guido Schmitz
3027b848c1 Add reauth config flow to devolo Home Control (#49697) 2021-06-28 15:01:31 +02:00
Erik Montnemery
7a4f3fe7b8 Filter MQTT light JSON attributes (#52242) 2021-06-28 14:37:26 +02:00
Joakim Plate
24ba81c3a2 Update new effect before calculating color on Philips TV (#52072) 2021-06-28 14:01:29 +02:00
micha91
8133793f23 Yamaha musiccast grouping-services (#51952)
Co-authored-by: Tom Schneider <tom.schneider-github@sutomaji.net>
2021-06-28 13:57:01 +02:00
Joakim Sørensen
8255a2f6c8 Removal of stale add-on devices on startup (#52245) 2021-06-28 13:49:58 +02:00
Otto Winter
3e1d32f4e0 ESPHome Climate add preset, custom preset, custom fan mode (#52133)
* ESPHome Climate add preset, custom preset, custom fan mode

* Fix copy paste error

* Bump aioesphomeapi to 3.0.0

* Bump aioesphomeapi to 3.0.1

* Persist api version to prevent exception for offline devices
2021-06-28 13:43:45 +02:00
Michael Davie
594bcbcf7a Fix timezones in Environment Canada hourly forecasts (#51917) 2021-06-28 12:57:07 +02:00
billsq
90e9216e9a Add support for overriding SMTP recipient(s) in a service call (#47611) 2021-06-28 12:54:03 +02:00
J. Nick Koston
583626a74f Convert nmap_tracker to be a config flow (#50429) 2021-06-28 12:49:14 +02:00
Vilppu Vuorinen
4ba5a4f36e Fix unique_id generation for AtwZoneSensors (#51227) 2021-06-28 12:20:40 +02:00
J. Nick Koston
ab24d16e00 Suppress duplicate mdns discovery from netdisco (#52099) 2021-06-28 11:46:56 +02:00
Fabian Zimmermann
3c0a24db50 Convert openweathermap dewpoint from kelvin to celcius (#51893)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-28 11:35:33 +02:00
Shay Levy
ab73ce00a0 Change "Not adding entity" log level to debug (#52240) 2021-06-28 11:22:10 +02:00
Brett
486e94e6a5 Add "auto" HVAC mode to Advantage Air (#51693)
* Add support for myAuto

* Small bug fixes for myAutoModeEnabled

* Add myauto to test fixture

* Refactor hvac_modes using AC_HVAC_MODES
2021-06-28 11:21:25 +02:00
myhomeiot
922b195ebf Add hvac_action to Daikin AC (#52035) 2021-06-28 11:10:53 +02:00
Chris Talkington
e4fc76ac2c Add re-authentication support to cloudflare (#51787) 2021-06-28 10:48:18 +02:00
Chris Talkington
bfc2995cf8 Update cloudflare test helpers (#52235) 2021-06-28 10:40:51 +02:00
Erik Montnemery
e14480599b Add value_template support to MQTT number (#52155) 2021-06-28 10:23:34 +02:00
Maciej Bieniek
3d556f14a5 Remove air_quality platform from Airly integration (#52225)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-28 10:15:56 +02:00
Brian Towles
9c84c2889f Modern forms switch platform (#52061)
* Add switch platform to Modern Forms integration

* Add reboot switch

* Update  lib to catch status from switches

* lint ignore

* Removed reboot switch

* bump aiomodernforms for dependency cleanup
2021-06-28 09:47:41 +02:00
Raman Gupta
bef8be9256 Support dynamic schema validation in device conditions and actions (#52007)
* Allow integrations to provide dynamic schema validation in device conditions and actions

* Add tests

* re-add type

* mypy
2021-06-28 09:23:46 +02:00
Christopher Masto
5d3f3c756f Fix Fahrenheit to Celsius conversion in Prometheus exporter (#52212)
const.TEMP_FAHRENHEIT is "°F", but _unit_string converts this to "c",
so the comparison never succeeds and we end up with temperatures in F
but labeled C.
2021-06-28 09:19:49 +02:00
GitHub Action
5c5e43afc1 [ci skip] Translation update 2021-06-28 00:10:15 +00:00
Chris Talkington
8b47faa840 Remove undo listener variable in cloudflare (#52227)
* remove undo listener variable in cloudflare

* Update const.py

* Update __init__.py

* Update __init__.py
2021-06-27 15:58:49 -05:00
Joakim Plate
0d689eefd6 Make Philips TV notify service optional (#50691)
* Make event service optional

* Correct strings for rename

* Drop unload we are just testing config flow here
2021-06-27 22:57:08 +02:00
puddly
c404a196c2 Allow creating ZHA groups with specific IDs (#50781) 2021-06-27 15:21:15 -04:00
SgtBatten
bd399d17a7 Add support for 4th fan speed in izone A/C systems (#51969)
* Add TOP fan speed

My a/c is 4 speed and the top speed is reported as top or boost. 

i.e it supports: low med high boost auto

* add support for top fan speed

Aircons with 4 fan speeds. i.e low, med, high, top/boost

* Update manifest.json

Bump version to 1.1.5

* Update climate.py

* Bump Izone to 1.1.5

* Update climate.py

* fix isort failure

* Use v1.1.6

Co-authored-by: Penny Wood <Swamp-Ig@users.noreply.github.com>
Co-authored-by: Swamp-Ig <github@ninjateaparty.com>
2021-06-27 21:13:26 +02:00
ollo69
e6e39a67f4 AsusWRT code improvements for sensors and related tests (#51822)
* Sensors implementation and tests improvements

* Remove check for unexpected condition
2021-06-27 15:09:03 -04:00
hesselonline
e56069558a Refactor wallbox tests (#51094)
* Changed Testing, removed custom exception
Removed custom exceptions, reverted to builtin. Changed testing approach in all tests, now using the core interface to setup device and mock_requests to create test responses for all calls.

* Reintroduce InvalidAuth exception in __init__
Remove reference to internal HA exception, Reintroduce custom exception

* Removed duplicate entry in test_config_flow

* removed tests from test_init that calling methods directly

* Update tests/components/wallbox/__init__.py

Removed duplicate add_to_hass call

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

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-27 15:06:25 -04:00
avee87
2d1744c573 Add forecasts to MetOffice integration (#50876)
* MetOfficeData now retrieves both 3-hourly and daily data (full forecast data, as well as "now" snapshot) on each update

* Bump datapoint API up to latest version

* Create 2 sets of sensors - one of each set for 3-hourly and for daily data (same ones initially enabled, for now)

* Create two entities (one each for 3-hourly and daily data) and also add in the forecast data for each dataset

* Testing changes to accommodate now having two sets of everything for 3-hourly and daily update data

* Removed unused import (reported by flake8)

* As per conversation with @MatthewFlamm leave the 3-hourly entity's unique_id unchanged (although the display name is changed)

* Make some improvements based on reviews

Make some improvements and fix up the formatting/linting failures.

* Make some improvements based on reviews

Make some improvements and fix up the formatting/linting failures.

* Added more test coverage

* import asyncio

* Try to fix test

* Rewrote everything using CoordinatorEntity

* Fixed config flow

* Fixed lint errors

Co-authored-by: MrHarcombe <ian.harcombe@gmail.com>
Co-authored-by: Henco Appel <hencoappel+github@gmail.com>
2021-06-27 15:04:42 -04:00
Raman Gupta
23339cff95 Add new climacell sensors (#52079)
* Add new climacell sensors

* lint

* add new unit constants
2021-06-27 15:03:20 -04:00
Erik Montnemery
74aa428bd1 Implement color_mode support for ozw (#52063) 2021-06-27 15:00:27 -04:00
Matt Zimmerman
da1d6d3821 Add service to reset SmartTub reminders (#51824)
* Add service to reset SmartTub reminders

* add test

Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-27 20:59:11 +02:00
Hristo Atanasov
a5362542ad Bulgarian language added in Google Translate TTS (#51985)
* Added Bulgarian language

Bulgarian language is supported by Google Translate TTS and by gTTS library. Tested all lockally and it works perfect.
https://github.com/pndurette/gTTS

* Bulgarian language added in v2.2.3

* Run script.gen_requirements_all

Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-27 20:55:36 +02:00
J. Nick Koston
a10847bef3 Fix isy994 fan when turn on is not called with a percentage (#49531)
* Fix isy994 fan when turn on is not called with a percentage

* Make insteon/fan.py logic
2021-06-27 20:35:58 +02:00
Martin Hjelmare
120fd633b2 Add mysensors sensor platform test foundation (#51548) 2021-06-27 20:33:20 +02:00
Lasath Fernando
543e1a0f9c Make PjLink power toggle more robust (#51821)
Occasionally, this integration misses events (or maybe they never get sent) from the projector and gets "stuck" in the wrong power state.
Currently, this prevents this integration from changing the power state as it thinks its already in the correct state. Only way to resolve this is to reboot home assistant.

This PR makes it a little more resilient by attempting to send the correct command even when it thinks it's already in the correct state.
2021-06-27 20:30:49 +02:00
Niels Mündler
aececdfeb9 Update pyfronius to 0.5.2 (#52216)
* Update the pyfronius package to version 0.5.2

this automatically introduces support for API V0 of fronius devices

* Update requirements
2021-06-27 12:43:31 -05:00
Joakim Plate
eedf1c3ebe Reject requests from the proxy itself (#52073)
* Reject requests from the proxy itself

* Adjust tests
2021-06-27 19:02:51 +02:00
ryansun96
dafddce446 Update base image to 2021.06.2 (#52190) 2021-06-27 18:59:27 +02:00
Matt Zimmerman
fad7e43c4f Add state attribute to SmartTub reminders for days remaining (#51825) 2021-06-27 18:39:40 +02:00
Milan Meulemans
a9bd7da79d Remove Rituals room size number entity (#52200) 2021-06-27 18:38:07 +02:00
Matthias Alphart
253310aaa4 Add respond_to_read option to KNX switch (#51790) 2021-06-27 18:34:41 +02:00
Matthias Alphart
89cdda9fe6 Add idle hvac_action to KNX climate (#52006)
* add idle hvac_action and command_value extra_state_attribute

* use class attribute for unit
2021-06-27 18:31:07 +02:00
Daniel Hjelseth Høyer
a788b6ebc1 Clean up surepetcare binary sensor (#52217)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-27 17:27:33 +02:00
Daniel Hjelseth Høyer
a824313e9f Clean up Surepetcare sensor (#52219)
Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2021-06-27 17:25:54 +02:00
Franck Nijhof
3f49cdf9bf DSMR: Use entry unload to unsub update listener (#52220) 2021-06-27 16:58:08 +02:00
Franck Nijhof
75d29b3d9e Upgrade watchdog to 2.1.3 (#52224) 2021-06-27 16:57:30 +02:00
Daniel Hjelseth Høyer
f1b5183e47 Tibber power factor (#52223) 2021-06-27 16:49:22 +02:00
Milan Meulemans
0d6e73236a Upgrade pyrituals 0.0.3 -> 0.0.4 (#52209) 2021-06-27 14:53:55 +02:00
Klaas Schoute
6b08aebe5f Add Forecast Solar integration (#52158)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-27 14:05:04 +02:00
GitHub Action
473ab98a67 [ci skip] Translation update 2021-06-27 00:09:39 +00:00
Daniel Hjelseth Høyer
b45c8466b4 Surepetcare, Use entity class vars and some clean up (#52205) 2021-06-26 15:40:40 -07:00
Pavel Pletenev
db2fda09b9 Fix habitica regression (#52097) 2021-06-26 15:36:45 -07:00
Milan Meulemans
4c7934de46 Clean up strings.json (#52202)
* Remove empty error in arcam_fmj

* Remove empty data in directv

* Remove empty error and data in kraken

* Remove empty data in roku
2021-06-26 20:36:13 +02:00
jan iversen
c558c77413 Correct keyerror exception. (#52150) 2021-06-26 20:09:53 +02:00
Matthias Alphart
5687ced7b3 Cleanup KNX integration (#52168)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-06-26 14:30:36 +02:00
Joakim Sørensen
b7c15d4474 Fix deprecation warning in discord notifier (#52197) 2021-06-26 07:12:10 -04:00
Shay Levy
568e1b379d Address late review of Switcher sensor migration (#52186) 2021-06-26 07:30:47 +02:00
GitHub Action
cd9fa27f2a [ci skip] Translation update 2021-06-26 00:10:53 +00:00
Appleguru
8d8af60b1d Add retries for tplink discovery (#52015)
* Add retries for tplink discovery

* Black Format tplink common.py

* Exit tplink discovery early if all devices found

* Fix typo in tplink retry log msg

* Code style cleanup for tplink retries

* Update homeassistant/components/tplink/common.py

Co-authored-by: Teemu R. <tpr@iki.fi>

* Fix linting errors for tplink retries

Co-authored-by: Teemu R. <tpr@iki.fi>
2021-06-25 23:49:35 +02:00
Daniel Hjelseth Høyer
4abdeec36d Use entity class vars in Broadlink (#52177) 2021-06-25 11:31:17 -10:00
PeteBa
42c4317628 Avoid drift in recorder purge cut-off (#52135) 2021-06-25 11:29:38 -10:00
J. Nick Koston
a71af8e9d3 Abort samsungtv config flow for existing hosts when the unique id is set (#52138)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-25 10:31:33 -10:00
starkillerOG
6bbe477d66 Improve Xiaomi Miio error handling (#52009)
* Xiaomi Miio inprove error logging

* improve error handeling

* fix styling

* fix styling

* Update homeassistant/components/xiaomi_miio/device.py

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

* Update homeassistant/components/xiaomi_miio/gateway.py

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

* Update homeassistant/components/xiaomi_miio/gateway.py

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

* break long line

* Clean up

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-25 21:25:51 +02:00
Joakim Sørensen
328ab21a05 Stream requests to ingress (#52184) 2021-06-25 12:14:26 -07:00
Erik Montnemery
dad7a597ae Add color_mode support to yeelight light (#51973)
* Add color_mode support to yeelight light

* Satisfy pylint

* Address review comment

* Improve test coverage

* Improve test coverage
2021-06-25 17:37:15 +02:00
Franck Nijhof
3b0f67acd1 DSMR: Add deprecation warning for YAML configuration (#52179) 2021-06-25 14:42:06 +02:00
Wim Haanstra
bc2689fd75 Add day-consumption fixed cost sensor in dsmr_reader (#52178)
* Added day-consumption fixed cost property

* black

Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-25 07:59:51 -04:00
Maciej Bieniek
a95294c83f Fix typo in Nettigo Air Monitor integration (#52182) 2021-06-25 12:07:32 +02:00
Franck Nijhof
958016c44f Clean up input_boolean, removing typing exceptions (#52181)
* Clean up input_boolean, removing typing exceptions

* Now pushing all local changes...
2021-06-25 11:57:52 +02:00
Franck Nijhof
b939570c9c Simplify WLED segment tracking (#52174)
* Simplify WLED segment tracking

* Fix master controls
2021-06-25 10:57:12 +02:00
Maciej Bieniek
e6c850136c Add support for state_class to AccuWeather integration (#51510)
* Add support for state_class

* Use get() method
2021-06-25 10:06:15 +02:00
J. Nick Koston
22c8afe637 Create a base class for broadlink entities (#52132)
* Create a base class for broadlink entities

* Update homeassistant/components/broadlink/entity.py

Co-authored-by: Daniel Hjelseth Høyer <mail@dahoiv.net>

* Update homeassistant/components/broadlink/entity.py

* Update homeassistant/components/broadlink/entity.py

Co-authored-by: Daniel Hjelseth Høyer <mail@dahoiv.net>

* black, remove unused

Co-authored-by: Daniel Hjelseth Høyer <mail@dahoiv.net>
2021-06-25 07:39:21 +02:00
J. Nick Koston
d009f06a55 Handle connection being closed in legacy samsungtv (#52137)
* Handle connection being closed in legacy samsungtv

- Mirror the websocket behavior

Fixes
```
2021-06-24 02:54:13 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.89_guestroom fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 401, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 609, in async_device_update
    raise exc
  File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/src/homeassistant/homeassistant/components/samsungtv/media_player.py", line 124, in update
    self._state = STATE_ON if self._bridge.is_on() else STATE_OFF
  File "/usr/src/homeassistant/homeassistant/components/samsungtv/bridge.py", line 113, in is_on
    return self._get_remote() is not None
  File "/usr/src/homeassistant/homeassistant/components/samsungtv/bridge.py", line 232, in _get_remote
    self._remote = Remote(self.config.copy())
  File "/usr/local/lib/python3.8/site-packages/samsungctl/remote.py", line 9, in __init__
    self.remote = RemoteLegacy(config)
  File "/usr/local/lib/python3.8/site-packages/samsungctl/remote_legacy.py", line 32, in __init__
    self._read_response(True)
  File "/usr/local/lib/python3.8/site-packages/samsungctl/remote_legacy.py", line 77, in _read_response
    raise exceptions.ConnectionClosed()
samsungctl.exceptions.ConnectionClosed
```

* add coverage

* pass instead
2021-06-25 07:31:44 +02:00
GitHub Action
febc276db9 [ci skip] Translation update 2021-06-25 00:12:31 +00:00
Franck Nijhof
f9d65b9196 Add preset support to WLED (#52170) 2021-06-24 23:16:07 +02:00
Maciej Bieniek
0730b375f3 Remove air_quality platform from Nettigo Air Monitor integration (#52152)
* Remove air_quality platform

* Clean constants
2021-06-24 22:58:37 +03:00
Daniel Hjelseth Høyer
a5ca25019c Toon, correct generate a 0-timestamp (#52167)
Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2021-06-24 21:48:09 +02:00
Santobert
adade590ed Bump pybotvac to 0.0.21 (#52166) 2021-06-24 21:29:09 +02:00
Daniel Hjelseth Høyer
e039a9d37b Tibber, correct generate a 0-timestamp (#52165)
* Tibber, correct generate a 0-timestamp

* import

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2021-06-24 21:18:46 +02:00
Franck Nijhof
a2be9a487f DSMR: Complete full strictly typed (#52162) 2021-06-24 11:27:25 -07:00
Franck Nijhof
fba7118d44 Add Color Palette Select entities to WLED (#51994)
* Add Color Palette Select entities to WLED

* Update with dev changes, disable by default
2021-06-24 11:25:21 -07:00
J. Nick Koston
5695710463 Add mac address to samsungtv config entry data if missing (#51634)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-24 08:15:16 -10:00
Franck Nijhof
34a317b847 DSMR: Device/state classes, icons, less common disabled by default (#52159) 2021-06-24 18:48:51 +02:00
Erik Montnemery
4533a77597 Add MQTT select (#52120)
* Add MQTT select

* Fix value_template support

* Lint
2021-06-24 17:09:06 +02:00
starkillerOG
69a04cf748 Fix Xiaomi Miio missing gateway info (#52146)
During my last PR: https://github.com/home-assistant/core/pull/47955, I accedently created a bug that will block the setup of the gateway integration.
This fixes that bug.
2021-06-24 17:03:19 +02:00
Simone Chemelli
3b8ece38b3 Second part of Strict types for Fritz (#52086)
Co-authored-by: Shay Levy <levyshay1@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-24 17:02:41 +02:00
Franck Nijhof
75c3daa45f DSMR: Refactor sensor creation, added typing to sensors (#52153)
* DSMR: Refactor sensor creation, added typing to sensors

* Log from package level

* Apply suggestions from code review

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

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-24 16:56:43 +02:00
Erik Montnemery
04c9665241 Filter MQTT JSON attributes (#52076)
* Filter JSON attributes

* Apply suggestions from code review

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>

* Refactor, add tests

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2021-06-24 16:22:54 +02:00
Martin Hjelmare
09b3882a5b Type frontend strictly (#52148) 2021-06-24 16:01:28 +02:00
Franck Nijhof
afa00b7626 DSMR: Remove Gas derivative sensor (#52147) 2021-06-24 14:25:38 +02:00
Martin Hjelmare
0e5040d917 Add zwave_js options flow to reconfigure server (#51840) 2021-06-24 13:15:42 +02:00
Franck Nijhof
fbdd6a9d95 DSMR: Typing cleanup in init & config flow (#52145) 2021-06-24 12:53:16 +02:00
Franck Nijhof
17357bf575 DSMR: Small cleanup; use entity class attributes (#52143) 2021-06-24 11:25:19 +02:00
Eduard van Valkenburg
e21325b975 Fix missing azure event hub instance name (#52049) 2021-06-24 11:24:38 +02:00
Franck Nijhof
780d538bb0 DSMR: Adding myself to the codeowners (#52144) 2021-06-24 11:23:20 +02:00
Maciej Bieniek
ff8b96c65d Remove YAML configuration import from Sony Bravia TV (#52141) 2021-06-24 11:10:21 +02:00
Matthias Alphart
74db49fae4 Add KNX select entity (#52026)
* select entity for knx

* validate select options

* lint

* phytonify

* Tweak

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-06-24 10:54:04 +02:00
Rob Bierbooms
aa56a21b45 Add config flow step user to dsmr (#50318)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-24 10:16:08 +02:00
dependabot[bot]
0714ee68eb Bump docker/login-action from 1.9.0 to 1.10.0 (#52140)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-06-24 09:52:17 +02:00
Franck Nijhof
a67ca08124 Change dynamic segment handling of WLED (#52018) 2021-06-23 23:43:24 +02:00
Paulus Schoutsen
cc00617cd5 Allow defining state class for template sensors (#52130) 2021-06-23 14:37:04 -07:00
Robert Svensson
6352d8fb0e Use more attr instead of properties in deCONZ integration (#52098) 2021-06-23 21:40:34 +02:00
jan iversen
1f4fdb50dc Share struct validator between sensor and climate (#51935) 2021-06-23 11:03:17 -07:00
Franck Nijhof
5b663b1fb9 Add state class to Enphase Envoy (#52113) 2021-06-23 10:46:00 -07:00
Franck Nijhof
38daf94562 Add state class to Eliqonline (#52111) 2021-06-23 10:44:55 -07:00
Franck Nijhof
7f7c0febd8 Add state class to DTE Energy Bridge (#52110) 2021-06-23 10:44:41 -07:00
Franck Nijhof
927b74b4a2 Add state class to The Energy Detective TED5000 (#52109) 2021-06-23 10:44:25 -07:00
Franck Nijhof
0ddd858b4b Add state class to Aurora ABB Solar PV (#52108) 2021-06-23 10:43:57 -07:00
Franck Nijhof
b9e6a6b3b8 Add state class to JuiceNet (#52116) 2021-06-23 10:43:31 -07:00
Franck Nijhof
39b090d957 Add state class to Neurio energy (#52117) 2021-06-23 10:41:48 -07:00
Franck Nijhof
3bfcca2bb0 Add state class to Atome Linky, use class attributes (#52107) 2021-06-23 10:23:56 -07:00
Martin Hjelmare
ed4a3d275a Fix ezviz options flow test patch (#52125) 2021-06-23 18:19:45 +02:00
Matthias Alphart
742159a6a6 Add number entity to KNX (#51786)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-06-23 17:20:49 +02:00
Chris Talkington
4e88b44286 Use attrs instead of properties for directv (#51918)
* Use attrs instead of properties for directv

* Update __init__.py

* Create entity.py

* Update media_player.py

* Update remote.py

* Update media_player.py

* Update remote.py

* Update media_player.py

* Update remote.py

* Update entity.py

* Update __init__.py

* Update media_player.py

* Update remote.py

* Update media_player.py

* Update media_player.py
2021-06-23 16:10:29 +02:00
Erik Montnemery
2351f2d95e Warn when receiving message on illegal MQTT discovery topic (#52106)
* Warn when receiving message on illegal MQTT discovery topic

* Fix test
2021-06-23 15:53:17 +02:00
Tobias Sauerwein
db5bf8ab23 Bump pyatmo version (#52112)
* Bump pyatmo version

* Update tests
2021-06-23 15:51:27 +02:00
Maciej Bieniek
75faee4f25 Use attrs instead of properties in Bravia TV integration (#52045)
* Use attrs instead of properties

* Revert to using properties for dynamic data

* Move volume_level to coordinator

* Move media_title to coordinator

* Remove unused variables

* Fix variable name

* Revert removed variables
2021-06-23 15:46:28 +02:00
Erik Montnemery
80ae346318 Pass the hass object to all MQTT component constructors (#52124) 2021-06-23 15:44:18 +02:00
Erik Montnemery
77de233679 Update MQTT number to treat received payload as UTF-8 (#52121)
* Update MQTT number to treat received payload as UTF-8

* Lint
2021-06-23 15:35:18 +02:00
Erik Montnemery
a374e24843 Add monetary sensor device class (#52087)
* Add total_cost sensor device class

* Change to DEVICE_CLASS_MONETARY
2021-06-23 15:32:25 +02:00
Tobias Sauerwein
5a4a1a250d Catch exception for failed webhook drop for netatmo (#52119) 2021-06-23 14:56:20 +02:00
Franck Nijhof
b3b23066a8 Add state class to Huisbaasje (#52114) 2021-06-23 13:11:33 +02:00
Jesse Hills
33e2b910c2 Add @jesserockz to ESPHome codeowners (#52115) 2021-06-23 13:10:58 +02:00
Jan Bouwhuis
29bfb4b046 Xiaomi_miio fan percentage based speeds and preset_modes (#51791) 2021-06-23 11:30:42 +02:00
Paulus Schoutsen
6c4816567c Add state class to Sense (#52104) 2021-06-23 08:56:11 +02:00
Paulus Schoutsen
c31f267106 Add state class to powerwall (#52102) 2021-06-22 23:19:02 -07:00
GitHub Action
de5431c037 [ci skip] Translation update 2021-06-23 00:09:30 +00:00
Franck Nijhof
b112b18848 Get running event loop in debugpy (#52091) 2021-06-22 21:16:50 +02:00
maurerle
ba3416b724 Handle ConnectionError if proxmoxve host is not reachable (#51970)
* handle ConnectionError if host is not reachable

* import only needed exceptions

fix pylint issue

* don't overwrite built-in ConnectionError

* fix typo
2021-06-22 20:54:27 +02:00
Erik Montnemery
04b425ed89 Use HS color instead of RGB color for Tasmota lights (#52052) 2021-06-22 20:40:59 +02:00
Robert Svensson
e22893a206 Make attestation of supported features easier to read (deCONZ test) (#52096)
Make is_deconz_group a constant
2021-06-22 20:34:25 +02:00
Robert Svensson
6814e9607a Improve deCONZ lights supported_color_modes and tests (#51933)
* Improve deconz lights tests

* Simplify attribute definition

* Bump pydeconz to v80
2021-06-22 19:29:58 +02:00
Shay Levy
5795e76826 Migrate Switcher entity attributes to sensors (#51964)
* Migrate attributes to sensors

Migrate attributes to sensors

* Fix pylint

* Apply suggestions from code review

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

* Add typing imports

Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-22 18:28:09 +02:00
Maciej Bieniek
d08129352f Bump Nettigo Air Monitor library (#52085) 2021-06-22 15:44:53 +02:00
muppet3000
456755c077 Adjust Growatt PV units from W to kW (#52021) 2021-06-22 13:15:38 +02:00
Erik Montnemery
52c142a82d Add support for color_mode white to MQTT light basic schema (#51484)
* Add support for color_mode white to MQTT light basic schema

* Add missing abbreviations
2021-06-22 11:59:20 +02:00
Yuval Aboulafia
39bf304031 Static typing for PiHole (#51681)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-22 11:50:50 +02:00
Brian Towles
9cd3ffbd47 Modern Forms light platform code cleanup (#52058) 2021-06-22 10:10:49 +02:00
Otto Winter
03ec7b3d0b ESPHome rework EsphomeEnumMapper for safe enum mappings (#51975) 2021-06-21 21:22:38 -07:00
Raman Gupta
0eae0cca2b Move zwave_js migration tests into new module (#52075) 2021-06-21 20:42:03 -04:00
GitHub Action
d805e971b4 [ci skip] Translation update 2021-06-22 00:14:17 +00:00
Raman Gupta
8a9a141f3c Fix zwave_js migration logic (#52070)
* Fix zwave_js migration logic

* revert change to move tests to new module

* Update tests/components/zwave_js/test_init.py

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

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-21 16:45:47 -04:00
MattWestb
077131df1a Update climate.py (#52065)
Adding tuya TRVs type Moes that need extra function in ZHA.
https://github.com/home-assistant/core/issues/49378 adding _TYST11/_TZE200_cwnjrr72 that is missed then being added in zigpy.
https://github.com/zigpy/zha-device-handlers/pull/931 is adding the _TZE200_b6wax7g0 and i shall adding the missed _TYST11_b6wax7g0
2021-06-21 15:36:00 -04:00
Erik Montnemery
b916247e8e Improve editing of device automation referring non added select entity (#52047)
* Improve editing of device automation referring non added select entity

* Update tests
2021-06-21 14:49:51 +02:00
Brian Towles
f29bcf7ff7 Modern Forms light platform (#51857)
* Add light platform to Modern Forms integration

* cleanup setup

* Code review cleanup
2021-06-21 10:09:41 +02:00
Franck Nijhof
23719bbb5e Upgrade wled to 0.7.0 (#52017) 2021-06-21 09:44:29 +02:00
Jeff Irion
b46bcdeeb1 Bump adb-shell to 0.3.4 (#52044)
* Bump adb-shell to 0.3.4

* Bump adb-shell to 0.3.4

* Bump adb-shell to 0.3.4
2021-06-21 08:23:22 +02:00
Paulus Schoutsen
076227acbe Merge pull request #52043 from home-assistant/rc 2021-06-20 22:37:31 -07:00
Paulus Schoutsen
34f266bfa6 Bumped version to 2021.6.6 2021-06-20 21:49:17 -07:00
jjlawren
0d351e4a0e Catch unexpected battery update payloads on Sonos (#52040) 2021-06-20 21:49:12 -07:00
Paulus Schoutsen
79cfd444d9 Fix double subscriptions for local push notifications (#52039) 2021-06-20 21:49:11 -07:00
Maciej Bieniek
67699e3c1f Fix AccuWeather sensors updates (#52031)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2021-06-20 21:49:10 -07:00
Fredrik Erlandsson
47560006b8 Bump pydaikin to 2.4.3 (#51926) 2021-06-20 21:49:09 -07:00
Rob Bierbooms
d6fd41bd03 Bump pyRFXtrx to 0.27.0 (#51911)
* Bump version

* Fix test
2021-06-20 21:49:08 -07:00
djtimca
c8e678a2c6 Add Omnilogic switch defaults for max_speed and min_speed (#51889) 2021-06-20 21:49:08 -07:00
Konstantin Antselovich
398fca3b9d Fix whois expiration date (#51868) 2021-06-20 21:49:07 -07:00
Maciej Bieniek
2aed268fb7 Remove undo_listener variable in AccuWeather integration (#52032) 2021-06-20 21:40:04 -07:00
Maciej Bieniek
01a26f1348 Remove undo_listener variable in Sony Bravia TV integration (#52033) 2021-06-20 21:39:14 -07:00
Chris Talkington
d772488472 Remove undo listener variable in sonarr (#52042) 2021-06-20 21:38:45 -07:00
jjlawren
7b5ed8faa8 Catch unexpected battery update payloads on Sonos (#52040) 2021-06-20 21:38:07 -07:00
GitHub Action
067b5258c6 [ci skip] Translation update 2021-06-21 00:09:58 +00:00
Paulus Schoutsen
af8ef634c1 Fix double subscriptions for local push notifications (#52039) 2021-06-20 14:53:21 -07:00
Maciej Bieniek
57106098f9 Fix AccuWeather sensors updates (#52031)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2021-06-20 14:53:08 -07:00
Steven Looman
a127131c1b Upgrade async_upnp_client to 0.19.0 (#52019) 2021-06-20 18:17:39 +02:00
uvjustin
e8b5790846 Clean up stream refactor (#51951)
* Clean up target_duration method

* Consolidate Part creation in one place

* Use BytesIO.read instead of memoryview access

* Change flush() signature
2021-06-20 13:38:02 +08:00
GitHub Action
3836d46dff [ci skip] Translation update 2021-06-20 00:10:44 +00:00
Franck Nijhof
24c1256c2c Small WLED cleanups (#52014) 2021-06-19 17:13:48 +02:00
Oderik
f550c31886 Fix IoT class (#52008) 2021-06-19 15:38:48 +02:00
Bram Kragten
34a44b9bec Use entity sources to find related entities in Search (#51966)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-19 13:25:26 +02:00
Matthias Alphart
1d941284ff Fix not awaiting async super method in KNX climate (#52005) 2021-06-19 01:10:17 -05:00
Matthias Alphart
c246e211eb Update xknx to 0.18.7 (#52000) 2021-06-18 22:22:27 -05:00
GitHub Action
8901e1f157 [ci skip] Translation update 2021-06-19 00:10:05 +00:00
Aaron Bach
549f779b06 Force SimpliSafe to reauthenticate with a password (#51528) 2021-06-18 16:11:35 -06:00
Franck Nijhof
23222589dd Add device condition support to Select entity (#51992) 2021-06-18 23:31:08 +02:00
Franck Nijhof
655f797f67 Add Select entity support to Google Assistant (#51997) 2021-06-18 23:30:46 +02:00
Erik Montnemery
0ca199d8d0 Add WS API for listing available statistic ids (#51984)
* Add WS API for listing available statistic ids

* Update homeassistant/components/history/__init__.py

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: Bram Kragten <mail@bramkragten.nl>
2021-06-18 21:32:30 +02:00
Paulus Schoutsen
805ef3f90b Allow fetching multiple statistics (#51996) 2021-06-18 21:03:13 +02:00
Franck Nijhof
87a43eacb7 Add device action support to Select entity (#51990) 2021-06-18 11:40:29 -07:00
Franck Nijhof
06edc731c5 Add significant change support to select entity (#51978) 2021-06-18 11:31:09 -07:00
Franck Nijhof
98a53188f8 Add reproduce state to select entity (#51977) 2021-06-18 11:30:40 -07:00
Franck Nijhof
c1cfbcc4e3 Add device trigger support to Select entity (#51987) 2021-06-18 10:01:32 -07:00
Martin Hjelmare
2628ce54d9 Type homeassistant triggers event (#51979) 2021-06-18 09:46:20 -07:00
Franck Nijhof
054ca1d7ec Add Select entity component platform (#51849)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-18 11:51:55 +02:00
jan iversen
bc329cb602 Convert if/elif chains to dicts in modbus (#51962) 2021-06-18 11:20:44 +02:00
Brent Petit
c149ecf2cc Handle disconnected ecobee thermostat in humidifier and remote sensors (#51873) 2021-06-18 09:06:31 +02:00
GitHub Action
c0a0c8b283 [ci skip] Translation update 2021-06-18 00:09:11 +00:00
Tom
88eca8cc15 Add deconz support for Lidl Smart Door Bell HG06668 (#51949) 2021-06-17 17:57:27 +02:00
Raman Gupta
1e18011603 Adjust zwave_js WS API commands for logging (#51096) 2021-06-17 17:19:25 +02:00
Franck Nijhof
06c2e541c4 Fully type lock entity component (#51958) 2021-06-17 14:28:56 +02:00
Franck Nijhof
8e07e60741 Fully type binary_sensor entity component (#51957) 2021-06-17 13:53:45 +02:00
Artem Draft
db61a773fd Add remote control platform to BraviaTV (#50845) 2021-06-17 12:33:44 +02:00
jan iversen
08b0ef7a5e Use test fixture for configuration testing (#51803)
* Autospec mock_modbus and usei for configuration.

* Review comment.
2021-06-17 12:27:05 +02:00
Bram Kragten
0327d0b6db Add Mutesync dynamic update interval and catch invalid response values (#50764)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2021-06-17 11:40:48 +02:00
Franck Nijhof
927b5361a3 Define LockEntity entity attributes as class variables (#51909) 2021-06-17 11:25:33 +02:00
jjlawren
d3724355cf Improve Sonos Spotify/Tidal support, add service exceptions (#51871) 2021-06-17 11:09:57 +02:00
Brent Petit
016ba39dfb Ecobee logging cleanup (#51754) 2021-06-17 10:59:13 +02:00
Fredrik Erlandsson
b2aa55cea2 Bump pydaikin to 2.4.3 (#51926) 2021-06-17 10:58:28 +02:00
jan iversen
3ba90776c0 Add autospec to modbus mock, in order to use getattr (#51813) 2021-06-17 10:57:20 +02:00
Erik Montnemery
ee6c77048c Improve editing of device actions referencing non-added humidifier (#51749) 2021-06-17 10:27:22 +02:00
Franck Nijhof
17a71020db Define RemoteEntity entity attributes as class variables (#51904) 2021-06-17 10:21:49 +02:00
Franck Nijhof
9f17b8856a Define WaterHeaterEntity entity attributes as class variables (#51903) 2021-06-17 10:19:29 +02:00
Franck Nijhof
3b00e87ebc Define WeatherEntity entity attributes as class variables (#51899) 2021-06-17 10:16:16 +02:00
Franck Nijhof
7947946793 Type entry setup/unload for entity components (#51912) 2021-06-17 10:10:26 +02:00
Eugenio Panadero
b7c1df7864 Adopt new electricity tariffs in pvpc hourly pricing (#51789) 2021-06-17 09:03:28 +02:00
jjlawren
d4ac5bf048 Bump plexapi to 4.6.1 (#51936) 2021-06-17 09:02:23 +02:00
dependabot[bot]
aaf3a5a9c5 Bump actions/upload-artifact from 2.2.3 to 2.2.4 (#51946)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 2.2.3 to 2.2.4.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2.2.3...v2.2.4)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-06-17 08:31:20 +02:00
RenierM26
fe26c34e87 Clean ezviz error handling in services (#51945) 2021-06-17 08:30:19 +02:00
Konstantin Antselovich
c8329032b2 Fix whois expiration date (#51868) 2021-06-17 05:57:46 +02:00
Adam Król
986c4a8f29 Support Wolflink reconnection after unexpected failure (#47011)
* Support reconnection after unexpected fails

* Update session at every call. Support Offline devices

* Remove unnecessary else branch

* Clean typing

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-17 05:24:17 +02:00
Franck Nijhof
33e08f38da Raise bad request when receiving HTTP request from untrusted proxy (#51839)
* Raise bad request when receiving HTTP request from untrusted proxy

* Fix code comment
2021-06-17 04:41:19 +02:00
GitHub Action
17414439df [ci skip] Translation update 2021-06-17 00:10:03 +00:00
Raman Gupta
a250343c55 Support bitmask as a value (#51892)
* Support bitmask as a value

* Fix value schema and add tests

* fix test

* revert change to value schema
2021-06-16 15:53:45 -04:00
jjlawren
31db3fcb23 Refactor Sonos alarms and favorites into system-level coordinators (#51757)
* Refactor alarms and favorites into household-level coordinators

Create SonosHouseholdCoodinator class for system-level data
Fix polling for both alarms and favorites
Adjust tests

* Fix docstring

* Review cleanup

* Move exception handling up a level, do not save a failed coordinator

* Apply suggestions from code review

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

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-16 10:30:05 -05:00
Franck Nijhof
bc3e5b39ed Clean up cover group (#51924) 2021-06-16 14:47:29 +02:00
djtimca
dc9f1411d4 Add Omnilogic switch defaults for max_speed and min_speed (#51889) 2021-06-16 14:39:09 +02:00
Franck Nijhof
13bf5dbee4 Upgrade mypy to 0.902 (#51907) 2021-06-16 14:35:32 +02:00
Franck Nijhof
4655e3aa08 Clean up light group (#51922) 2021-06-16 14:30:25 +02:00
jan iversen
7ad91fdf71 Add swap to climate and change data_count -> count in modbus (#51668) 2021-06-16 12:11:23 +02:00
Eric Severance
61079ab7fa Support receiving long-press events from WeMo devices (#45503)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-16 12:00:34 +02:00
Franck Nijhof
c65d120633 Fix typo in min/max mired(s) entity class attribute (#51921) 2021-06-16 09:58:21 +02:00
Franck Nijhof
37d3a4dd53 Use entity class vars in Switch demo (#51906)
* Use entity class vars in Switch demo

* Fix missing initial state of the demo switch
2021-06-16 08:29:31 +02:00
Rob Bierbooms
ff0c753c87 Bump pyRFXtrx to 0.27.0 (#51911)
* Bump version

* Fix test
2021-06-15 20:34:05 -05:00
GitHub Action
a072fb059d [ci skip] Translation update 2021-06-16 00:09:27 +00:00
Franck Nijhof
f2bc69a653 Merge pull request #51902 from home-assistant/rc 2021-06-15 20:37:40 +02:00
uvjustin
6d656dd2ec Speed up record stream audio test (#51901) 2021-06-15 14:27:53 -04:00
Franck Nijhof
fcb2c26a24 Bumped version to 2021.6.5 2021-06-15 19:45:33 +02:00
Ludovico de Nittis
ee7a2b29ad Bump pyialarm to 1.9.0 (#51804) 2021-06-15 19:44:48 +02:00
Joakim Sørensen
dcc7bc10e8 Add httpcore with version 0.13.3 (#51799) 2021-06-15 19:44:45 +02:00
Fredrik Erlandsson
8f34d1cf32 Bump pydaikin, fix airbase issues (#51797) 2021-06-15 19:44:42 +02:00
Ron Klinkien
fcc66139f8 Replace garminconnect_aio with garminconnect_ha (#51730)
* Fixed config_flow for multiple account creation

* Replaced python package to fix multiple accounts

* Replaced python package to fix multiple accounts

* Implemented config entries user

* Config entries user

* Fixed test code config flow

* Fixed patch
2021-06-15 19:44:35 +02:00
Milan Meulemans
63e20f2ced Mark config flow fields as required (#51898)
* flo

* goalzero

* mutesync

* ring

* roon

* risco

* Ruckus Unleashed

* Scaffold template
2021-06-15 19:21:30 +02:00
Eric Severance
3488b78365 Add a menu_cursor service to the yamaha component (#44819)
* Add a menu_cursor service to the yamaha component

* Update homeassistant/components/yamaha/media_player.py

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

* Update service description to new format

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-15 19:17:10 +02:00
Franck Nijhof
37af42e470 Upgrade pillow to 8.2.0 (#51897) 2021-06-15 19:14:57 +02:00
Matthias Alphart
b08f473da4 Add current hvac_action to KNX climate (#51464) 2021-06-15 17:51:16 +02:00
Franck Nijhof
16d5d7e508 Upgrade codecov to 2.1.11 (#51885) 2021-06-15 15:04:48 +02:00
Franck Nijhof
e4202aa4de Upgrade pytest-cov to 2.12.1 (#51886) 2021-06-15 15:04:07 +02:00
RenierM26
22b8dc16c2 Add services to ezviz integration (#48984)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-06-15 13:23:32 +02:00
Kevin Worrel
515bd18ddd Don't create unsupported pump sensors (#51828)
* Don't create unsupported pump sensors

* Remove old code and simplify new statements.

* Address notes
2021-06-15 13:19:48 +02:00
Matthias Alphart
c0d311473c Restore state of KNX Switch (#51761) 2021-06-15 13:08:19 +02:00
Jan
333f199bd4 Additional units for HM-ES-TX-WM with ES-IEC (#50713)
The Homematic HM-ES-TX-WM with ES-IEC adapter needs additional unit cast for `IEC_POWER` and `IEC_ENERGY_COUNTER`.
2021-06-15 12:13:03 +02:00
Erik Montnemery
f3c6e846fa Enable asyncio debugging from debugpy integration (#51880)
* Optionally enable asyncio debugging from debugpy integration

* Unconditionally enable asyncio debugging
2021-06-15 12:10:47 +02:00
Raman Gupta
3db8d9ede5 Require admin for new node status WS API command (#51863) 2021-06-15 09:34:04 +02:00
Erik Montnemery
59a3e0f4dc Improve editing of device conditions referencing non-added HVAC (#51832) 2021-06-15 02:23:13 +02:00
GitHub Action
5469cc8fb2 [ci skip] Translation update 2021-06-15 00:11:31 +00:00
rikroe
dfe21eb78f Add selectors to BMW Connected Drive service definitions (#47065)
Co-authored-by: rikroe <rikroe@users.noreply.github.com>
2021-06-15 00:56:14 +02:00
Kim Frellsen
e1538594cd Update fortios device tracker to support FortiOS 7.0 (#51640)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-15 00:29:37 +02:00
starkillerOG
3a2d50fe23 Add Xiaomi Miio EU gateway support (#47955)
* Add EU gateway support

* add options flow translations

* fix options flow

* fix missing import

* try to fix async_add_executor_job

* try to fix async_add_executor_job

* fix unload

* check for login succes

* fix not reloading

* use cloud option

* fix styling

* Return after if

Co-authored-by: Nathan Tilley <nathan@tilley.xyz>

* cleanup

* add options flow tests

* fix new tests

* fix typo in docstring

* add missing blank line

* Use async_on_unload

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

* Use async_on_unload

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

* Use async_setup_platforms

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

* Use async_unload_platforms

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

* Update homeassistant/components/xiaomi_miio/__init__.py

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

* Update homeassistant/components/xiaomi_miio/const.py

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

* default use_cloud False

* add options flow checks

* fix styling

* fix issort

* add MiCloud check tests

* fix indent

* fix styling

* fix tests

* fix tests

* fix black

* re-write config flow

* add explicit return type

* update strings.json

* black formatting

* fix config flow

Tested the config flow and it is now fully working

* fix styling

* Fix current tests

* Add missing tests

* fix styling

* add re-auth flow

* fix styling

* fix reauth flow

* Add reauth flow test

* use ConfigEntryAuthFailed

* also trigger reauth @ login error

* fix styling

* remove unused import

* fix spelling

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

* Fix spelling

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

* fix spelling

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

* remove unessesary .keys()

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

* combine async_add_executor_job calls

* remove async_step_model

* fix wrong indent

* fix gatway.py

* fix tests

Co-authored-by: Nathan Tilley <nathan@tilley.xyz>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-15 00:05:40 +02:00
Raman Gupta
8705168fe6 Add zwave_js WS API cmds to get node state and version info (#51396)
* Add zwave_js view to retrieve a node's state

* remove typehints

* Make dump views require admin

* Add version info to node level dump

* Add back typehints

* switch from list to dict

* switch from dump node view to two WS API commands

* switch to snake
2021-06-14 16:43:51 -04:00
Raman Gupta
f00f2b4ae4 Add zwave_js ping node service (#51435)
* Add zwave_js ping node service

* uncomment code

* use asyncio.gather
2021-06-14 16:38:35 -04:00
Brian Towles
b1fa01e4bc Cleanup of code reviews from initial modern forms (#51794) 2021-06-14 21:04:02 +02:00
yllar
7329dc4f6b Add missing languages to Microsoft TTS (#51774) 2021-06-14 14:10:21 -04:00
jjlawren
e929774481 Add warning during playback if Plex token missing (#51853) 2021-06-14 20:09:27 +02:00
Raman Gupta
0d40ba463e Create zwave_js node status sensor when the node is added (#51850)
* Create node status sensor when the node is added

* Handle race condition

* reduce repeat code
2021-06-14 19:31:44 +02:00
Franck Nijhof
347ef9cb4c Define NumberEntity entity attributes as class variables (#51842) 2021-06-14 09:05:01 -07:00
Franck Nijhof
32409a2c93 Define HumidifierEntity entity attributes as class variables (#51841) 2021-06-14 09:04:46 -07:00
Joakim Sørensen
c8755cd896 Migrate the name for the hassio user (#51771) 2021-06-14 09:01:18 -07:00
uvjustin
97e77ab229 Improve type hints in stream (#51837)
* Improve type hints in stream

* Fix import locations

* Add stream to .strict-typing

Co-authored-by: Ruslan Sayfutdinov <ruslan@sayfutdinov.com>
2021-06-14 23:59:25 +08:00
Malte Franken
7cd57dd156 Bump aio_geojson_geonetnz_quakes to v0.13 (#51846) 2021-06-14 17:29:23 +02:00
Erik Montnemery
4c9f12b9c5 Correct trace path for trigger with custom id (#51847) 2021-06-14 17:09:20 +02:00
Erik Montnemery
a989677bef Improve editing of device conditions referencing non-added binary sensor (#51831)
* Improve editing of device conditions referencing non-added binary sensor

* Update tests
2021-06-14 15:26:46 +02:00
Erik Montnemery
06fc21e287 Improve editing of device conditions referencing non-added sensor (#51835) 2021-06-14 15:22:31 +02:00
Erik Montnemery
59ef55c34f Improve editing of device conditions referencing non-added cover (#51833) 2021-06-14 14:34:59 +02:00
Erik Montnemery
af05543744 Improve editing of device conditions referencing non-added humidifier (#51834) 2021-06-14 14:12:42 +02:00
Malte Franken
33ec6621c7 Bump georss_ign_sismologia_client to v0.3 (#51838) 2021-06-14 13:51:11 +02:00
Felipe Martins Diel
fca79237c3 Create dataclass to mock entry setup in Broadlink tests (#50134) 2021-06-14 13:28:57 +02:00
Erik Montnemery
08af791d4c Improve editing of device conditions referencing non-added alarm (#51830) 2021-06-14 13:05:27 +02:00
jan iversen
77f6d1f5cb Do not return an exception in modbus (#51829) 2021-06-14 10:56:24 +02:00
Tom Schneider
7e1fec8ee4 Rewrite of Yamaha musiccast integration (#51561)
* Initial commit for new musiccast integration

* Add zone support

* Get/set volume level

* Remove volume step

* Create custom MusicCastData type

* Create MusicCastDevice

* Fix await

* Add power and mute control

* Implement all basic media_player parts

* Support input switching

* Add duration/position support

* Add advanced tuner functions

* Basic media browser

* Add layer in media browser to see all available list_infos

* Added join/unjoin services and group informations. Known issue: You can not link zone 2 to main at the moment (WIP)

* Many fixes to make multiple zones and grouping work. Next step: implement error handling and remove debugging information

* WIP: Added Multizone Support and allows clients to directly jump from one group to another. Known issue: If a server tries to join a group as client, he has to close his group first. Sometimes the device that was a server previously jumps out of the group directly after joining.

* Updated group management to make it wait for the updated group information before performing the next actions - Timeouts after 1 second, then polls the distribution data. If the data are still not updated, there will be one retry before an Exception is thrown. Extended the state attributes for clients to make them return group details from their servers (leads to inactive group management buttons for the client). Added documentation and restructured the code.

* Make the service handle function name for group specific service calls unique

* Added service descriptions for set_sleep_timer, set_alarm, recall_netusb_preset, store_netusb_preset

* Added data entries for alarm specific values and a netusb preset list. Implemented fetching function for clock and netusb presets.

* Registered and implemented services for set_sleep_timer, set_alarm, recall_netusb_preset, store_netusb_preset. The set_alarm service works with a special mediaplayer alarm lovelace card, I am currently working on.
The NetUSB Presets are also available using the media browser. Maybe we could also add the Tuner presets in the future for both setting up the alarm and recalling them via service and media browser.

* Removed some debug prints

* Moved MusicCast Integration to the aiomusiccast library. This library supports media browsers with multiple pages. Added ssdp support for the discovery

* Minor fix in the group management and tidied up a bit

* Updated manifest of yamaha musiccast

* Update library

* Minor fix in the media browser. get_distribution_num does not have to be async, so it has been changed. Adjusted the client join function to turn on the client before joining a group - the musiccast app does so, so hopefully this fixes the rare errors when adding a turned off client to a group. Some reformating and by hooks fixed most of the requirements of the hooks. Known exception from this: mypy throws an error for line 116.

* Removed some old out commented code. Fixed some error handling, when the user enters a non reachable or non yamaha host in the manual setup. Fixed linting/styling errors. Implemented tests to bring the coverage for the config flow to 100%.

* Fixed linting/styling errors. Return a DeviceInfo object instead of a dict.

* Fixed linting/styling errors. Added a new error type to the translations.

* In the yamaha API the system_id is equal to the serial number in the DLNA description. Due to that it was possible to configure a device twice, because the serial number from the yamaha API was different. This issue was fixed.

* Updated tests and added a test for adding a device manually, which is already present in the system

* Remove print statements

* Fix sleep timer service call

* Fix yamllint error

* Shrink PR down to just new library + config flow with discovery

* Add __init__.py to .coveragerc

* Apply suggestions from code review

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>

* Implement suggestions from code review

* Improve identifiers and connections, remove event loop parameter

* Add coordinator back

* Better exception handling

* Fix unique id in ssdp step

* Remove abc.ABC from MusicCasteDeviceEntity

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

* Update homeassistant/components/yamaha_musiccast/config_flow.py

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

* Replace the repeat mode mapping from mc to ha by a generic solution

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

* add coordinator to the super call of the mediaplayer

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

* add the coordinator to the init function of the MusicCastEntity

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

* Pass the coordinator from the MusicCastEntity init function to the CoordinatorEntity init function

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

* merged _handle_config_flow into async_step_user

* reformated the exception handling of the user step. In the case that the device already exists, the AbortFlow will be raised.

* Removed model from the config entry. It was neither set nor used anymore.

* Fixed the test for the config flow.

* Use async_write_ha_state instead of schedule_update_ha_state.

* Add default value for the system ID gotten in the user step

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

* Update tests/components/yamaha_musiccast/test_config_flow.py

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

* Added a fixture to avoid IO in the test_user_input_device_not_found test

* Use absolute imprt to import data_entry_flow.

* Use local vars for host and serial_number in async_step_user.

* Remove ip_address and zone_id properties.

* Use device id for the unique ID of an entity instead of the macs

* Removed entry_id from the MusicCastEntity init function.

* Updated strings and English translation.

* don't set the coordinator in the mediaplayer init.

* Implemented legacy configuration.yaml support for existing configurations.

* Added tests for the newly added config flow step.

* Use device_id as identifier

* Fix an accidentally relative import

* Fix pylint warnings

* use logger.error instead of logger.exception in the import step.

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

* Use CONF_HOST instead of 'host'

* Only support the import from configuration.yaml if no config entries are setup for musiccast. If there are already config entries in HA and none of them is a representation of a config given in configuration.yaml (e.g. config added after the first import), an error will be logged.

* Update homeassistant/components/yamaha_musiccast/media_player.py

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

* Readded PLATFORM_SCHEMA for configuration.yaml

* Raise an exception for all services, which are only supported for specific sources.

* Bump aiomusiccast to 0.6 to support asyncio sockets

Co-authored-by: Michael Harbarth <michael.harbarth@gmx.de>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-14 08:58:42 +02:00
blawford
0709aa7c8c Pass metadata when casting an app (#51148)
* Pass through metadata when casting an app

* Remove passing kwargs to quick_play

Add metadata to the app_data dict.

* Include pass-through of metadata

* Bump pychromecast to 9.2.0

* Add changes to test to verify metadata

* Fix order of imports
2021-06-14 08:48:32 +02:00
Alexei Chetroi
cc622f46c5 Bump up ZHA dependencies (#51765) 2021-06-13 21:53:37 -04:00
Ludovico de Nittis
c260fca242 Bump pyialarm to 1.9.0 (#51804) 2021-06-13 21:47:56 -04:00
GitHub Action
1e00e48831 [ci skip] Translation update 2021-06-14 00:09:44 +00:00
J. Nick Koston
75d6ffebc8 Improve error when HomeKit accessory underlying entity is missing (#51713)
* Improve error when HomeKit accessory underlying entity is missing

* docstring in test
2021-06-13 17:27:04 -05:00
jjlawren
d755952148 Set playlist name on playing Sonos media (#51685)
* Use playlist name as media_channel if available

* Use proper playlist attribute
2021-06-13 17:24:46 -05:00
ollo69
4300484ca0 Catch AsusWRT UnicodeDecodeError in get_nvram call (#51811) 2021-06-13 17:20:02 -05:00
uvjustin
123e8f01a1 Refactor stream to create partial segments (#51282) 2021-06-14 00:41:21 +08:00
Jeff Irion
1adeb82930 Bump androidtv to 0.0.60 (#51812)
* Bump androidtv to 0.0.60

* Update requirements_test_all.txt

* Update manifest.json
2021-06-13 18:22:20 +02:00
Simone Chemelli
fbe507a9c1 Strict types - first part (#51479) 2021-06-13 16:45:35 +02:00
Shay Levy
a31e6716d9 Cleanup switcher_kis - move to consts (#51807) 2021-06-13 17:34:42 +03:00
Milan Meulemans
49a943cc94 Fix Roomba strings step_id rename (#51744) 2021-06-13 12:05:24 +02:00
Milan Meulemans
aacb334cc8 Remove connection classes (#51801) 2021-06-13 12:05:09 +02:00
Fredrik Erlandsson
936f155499 Bump pydaikin, fix airbase issues (#51797) 2021-06-13 11:38:55 +02:00
Joakim Sørensen
33ac4dba5a Add httpcore with version 0.13.3 (#51799) 2021-06-13 10:21:26 +02:00
Franck Nijhof
ae28e4934f Mark Ambee as a platinum quality integration (#51779) 2021-06-13 07:41:27 +02:00
GitHub Action
1d0c4c6e99 [ci skip] Translation update 2021-06-13 00:10:48 +00:00
Erik Montnemery
f9e9202e2d Improve editing of device triggers referencing non-added alarm (#51701) 2021-06-13 00:07:25 +02:00
Erik Montnemery
3a739563b4 Improve editing of device actions referencing non-added alarm (#51747) 2021-06-12 23:43:28 +02:00
Franck Nijhof
f975beae77 Upgrade wled to 0.6.0 (#51783) 2021-06-12 22:23:12 +02:00
Franck Nijhof
f362852a24 Upgrade black to 21.6b0 (#51785) 2021-06-12 22:07:22 +02:00
Erik Montnemery
b8669bf4c1 Improve editing of device actions referencing non-added cover (#51748) 2021-06-12 21:40:32 +02:00
Erik Montnemery
6ab37881c9 Improve editing of device actions referencing non-added lock (#51750) 2021-06-12 21:31:30 +02:00
Franck Nijhof
c242e56b8c Add re-authentication support to Ambee (#51773)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-12 16:18:06 +02:00
Franck Nijhof
cfce71d7df Allow keeping master light in WLED (#51759) 2021-06-12 13:33:23 +02:00
Eduard van Valkenburg
779ef3c8e1 Add timedelta option for async_call_later (#50164) 2021-06-12 13:14:35 +02:00
Martin Hjelmare
c3cfbfe54b Refactor zwave_js config flow (#51720) 2021-06-12 13:12:17 +02:00
Malte Franken
3276666457 Bump aio_geojson_nsw_rfs_incidents to v0.4 (#51770) 2021-06-12 11:55:32 +02:00
Martin Hjelmare
be137b085b Refactor zwave_js disconnect client helper (#51718) 2021-06-12 11:35:33 +02:00
Matthias Alphart
4afe7de07f xknx 0.18.6 (#51758) 2021-06-12 11:19:05 +02:00
Ron Klinkien
f6e0165543 Replace garminconnect_aio with garminconnect_ha (#51730)
* Fixed config_flow for multiple account creation

* Replaced python package to fix multiple accounts

* Replaced python package to fix multiple accounts

* Implemented config entries user

* Config entries user

* Fixed test code config flow

* Fixed patch
2021-06-12 10:05:27 +02:00
Paulus Schoutsen
2535f5c155 Merge pull request #51768 from home-assistant/rc 2021-06-11 22:18:37 -07:00
Paulus Schoutsen
97e36cd3c4 Bumped version to 2021.6.4 2021-06-11 21:42:27 -07:00
J. Nick Koston
548e847453 Fix race condition in samsungtv turn off (#51716)
- The state would flip flop if the update happened before the TV had fully shutdown
2021-06-11 21:42:15 -07:00
J. Nick Koston
60b89101e5 Ensure samsungtv reloads after reauth (#51714)
* Ensure samsungtv reloads after reauth

- Fixes a case of I/O in the event loop

* Ensure config entry is reloaded
2021-06-11 21:42:14 -07:00
Pawel
90d28e911c Fix Onvif get_time_zone from device (#51620)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-11 21:42:13 -07:00
Maciej Bieniek
cfea8a9ad1 Do not configure Shelly config entry created by custom component (#51616) 2021-06-11 21:42:12 -07:00
blastoise186
880fe82337 Reduce ovo_energy polling rate to be less aggressive (#51613)
* Reduce polling rate to be less aggressive

The current polling rate is too aggressive for the purpose, this commit reduces it to 12 hours to play nice with OVO.

* tweak polling to hourly
2021-06-11 21:42:11 -07:00
jjlawren
3a5f51ed7d Handle missing section ID for Plex clips (#51598) 2021-06-11 21:42:10 -07:00
jjlawren
cca1b426bb Fix Sonos battery sensors on S1 firmware (#51585) 2021-06-11 21:42:09 -07:00
GitHub Action
30c53a1a13 [ci skip] Translation update 2021-06-12 00:08:54 +00:00
Erik Montnemery
bf6a412be0 Tweak device action scaffold, fix typo (#51751) 2021-06-11 23:22:18 +02:00
Franck Nijhof
b83b82ca7d WLED WebSocket support - local push updates (#51683)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2021-06-11 20:55:08 +02:00
Brent Petit
5cc31a98e2 Add Ecobee humidifier device_info and unique_id (#51504)
* Add Ecobee humidifier device_info and unique_id

Ecobee humidifier entity was not connected to the thermostat device.
This change will ensure the entitiy is properly connected.

This change also fills out the ecobee-data.json fixutre data a bit
to address failures in the test setup.

* Add Ecobee humidifier device_info and unique_id

Adjust test fixture data to increase pytest coverage
Clean up indenting in ecobee-data.json

* Add Ecobee humidifier device_info and unique_id

Update exception case in device_info to not
be included in codecov tests. This case has
been tested locally.

* Add Ecobee humidifier device_info and unique_id

Address pylint issue

* Add Ecobee humidifier device_info and unique_id

Remove no cover pragma and add ecobee humidifier.py to
.coveragerc
2021-06-11 17:39:57 +02:00
Erik Montnemery
b01b33c304 Add trigger condition (#51710)
* Add trigger condition

* Tweaks, add tests
2021-06-11 15:05:57 +02:00
Chris Talkington
fa3ae9b83c Use attrs instead of properties in roku (#51735)
* Use attrs instead of properties in roku.

* Update media_player.py

* Update remote.py

* Update __init__.py

* Create entity.py

* Update entity.py

* Update media_player.py

* Update remote.py

* Update __init__.py

* Update media_player.py

* Update remote.py

* Update __init__.py

* Update __init__.py

* Update entity.py
2021-06-11 13:51:18 +02:00
Chris Talkington
e0013648f6 Use attrs instead of properties in sonarr (#51737)
* Use attrs instead of properties in sonarr

* Create entity.py

* Update sensor.py

* Update __init__.py

* Update entity.py

* Update entity.py

* Update sensor.py
2021-06-11 13:48:20 +02:00
Maciej Bieniek
343e0e0933 Use attrs instead of properties in Brother (#51742)
* Use attrs instead of properties

* Use get() for device_class
2021-06-11 13:36:17 +02:00
Ville Skyttä
7d03b02192 Spelling fixes (#51642) 2021-06-11 13:35:03 +02:00
Malte Franken
be0d9d185b Bump georss_generic_client to v0.6 (#51745) 2021-06-11 13:30:58 +02:00
Franck Nijhof
f17a5f0db9 Clean up redudant exceptions from handlers (#51741) 2021-06-11 13:29:50 +02:00
Franck Nijhof
b4aeddd12f Add 100% test coverage to WLED integration (#51743) 2021-06-11 12:45:22 +02:00
jan iversen
2a51587bc3 Remove reverse_order (replaced by generic swap) (#51665)
Remove reverse_order (replaced by generic swap).
2021-06-11 11:41:41 +02:00
Franck Nijhof
7393cba0a5 Mock WLED in all WLED tests (#51724)
* Mock WLED in all WLED tests

* Update tests/components/wled/conftest.py

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

* Remove useless AsyncMock

* Add missing asserts

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2021-06-11 11:36:54 +02:00
Erik Montnemery
ba6b527d61 Improve editing of device actions referencing non-added HVAC (#51706)
* Improve editing of device actions referencing non-added HVAC

* Improve test coverage
2021-06-11 11:13:55 +02:00
Erik Montnemery
49bec86dae Add base schema for triggers (#51727)
* Add base schema for triggers

* Tweak

* Make TRIGGER_BASE_SCHEMA a voluptuous schema

* Make state trigger BASE_SCHEMA a voluptuous schema
2021-06-11 09:51:12 +02:00
jan iversen
9e378d51af Reduce modbus schemas and add delay to fan/light (#51664) 2021-06-11 09:22:47 +02:00
Yuval Aboulafia
ed9df83932 Static typing for no_ip integration (#51694)
* no_ip type hints

* type import change

* change Any to datetime
2021-06-11 10:06:15 +03:00
GitHub Action
c937c6d6b5 [ci skip] Translation update 2021-06-11 00:11:06 +00:00
Maciej Bieniek
0404acddf9 Add support for state_class (#51512) 2021-06-10 21:31:21 +03:00
Maciej Bieniek
9d64b64d34 Use attrs instead of properties in Airly integration (#51712) 2021-06-10 19:32:41 +02:00
jan iversen
453da10b62 Secure not to activate multiple venv in pre_commit hook (#51715) 2021-06-10 19:27:24 +02:00
J. Nick Koston
4722fdf465 Fix race condition in samsungtv turn off (#51716)
- The state would flip flop if the update happened before the TV had fully shutdown
2021-06-10 19:24:30 +02:00
J. Nick Koston
ab490bc769 Ensure samsungtv reloads after reauth (#51714)
* Ensure samsungtv reloads after reauth

- Fixes a case of I/O in the event loop

* Ensure config entry is reloaded
2021-06-10 19:23:00 +02:00
Robert Svensson
6e0aca49af Replace properties with attr in Axis integration (#51686) 2021-06-10 19:15:01 +02:00
Erik Montnemery
76c3058d15 Rename device trigger base schema to DEVICE_TRIGGER_BASE_SCHEMA (#51719) 2021-06-10 19:11:38 +02:00
Martin Hjelmare
a7f05713a0 Add Supervisor restart add-on helper (#51717) 2021-06-10 18:08:25 +02:00
Jc2k
d75c97cbf3 Revert "Set Fahrenheit reporting precision to tenths for Homekit Controller climate entities (#50415)" (#51698) 2021-06-10 15:41:42 +01:00
Franck Nijhof
17cf0cef0f Increase Ambee update interval to 1 hour (#51708) 2021-06-10 15:08:35 +02:00
Maciej Bieniek
220ad2baea Use attrs instead of properties in Nettigo Air Monitor integration (#51705)
* Use attrs instead of properties

* Remove unused self

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

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-06-10 14:42:28 +02:00
Franck Nijhof
fca0446ff8 Add pollen sensors to Ambee (#51702) 2021-06-10 14:18:09 +02:00
Robert Svensson
79996682e5 Add device trigger for IKEA Trådfri Shortcut button to deCONZ (#51680) 2021-06-10 13:17:48 +02:00
Erik Montnemery
d9110b5208 Improve editing of device triggers referencing non-added binary sensors (#51700) 2021-06-10 13:06:01 +02:00
Erik Montnemery
c1bc99890d Improve editing of device triggers referencing non-added cover (#51703) 2021-06-10 12:46:28 +02:00
tkdrob
181a4519b8 Clean up unloads (#51688) 2021-06-10 09:56:35 +02:00
Robert Svensson
b1022ce84e Use supported color modes in deCONZ integration (#51656)
* Initial commit everything is working, need to reevaluate tests

* Fix supported color modes and hs_color

* Attest color mode
2021-06-10 08:51:58 +02:00
Erik Montnemery
9097f41219 Correct comment in MQTT fan (#51682) 2021-06-10 08:18:59 +02:00
Franck Nijhof
b165e9f0cf Upgrade ambee to 0.3.0 (#51676) 2021-06-10 08:16:25 +02:00
jjlawren
c362ffd384 Clean up unused Sonos subscriptions (#51583) 2021-06-09 23:31:14 -05:00
GitHub Action
417ba5538d [ci skip] Translation update 2021-06-10 00:11:17 +00:00
Franck Nijhof
e5c6ac5ba8 Add 100% test coverage to Ambee integration (#51670)
* Add 100% test coverage to Ambee integration

* Add tests for device and entity registry
2021-06-09 20:23:16 +02:00
Franck Nijhof
332c86ff8c Restructure WLED integration (#51667) 2021-06-09 20:15:46 +02:00
jjlawren
c512e1df3c Bump pysonos to 0.0.51 (#51669) 2021-06-09 18:20:28 +02:00
Kenny Millington
cdf256b93e Create docker series version tag YYYY.M (#51615)
* Create docker series version tag YYYY.M.x

* Only create docker series version for stable tags

Following review on the PR51615

* Remove the ".x" suffix for docker series tags

Following review on PR51615

* Fix the in-line comment

Oversight in previous commit
2021-06-09 18:16:48 +02:00
Yuval Aboulafia
e78c656bfe Static typing for Uptime (#51638)
* uptime typing

* Clean up name type

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-09 14:30:33 +02:00
Matthias Alphart
6e20edc30c Update xknx to version 0.18.5 (#51644)
* xknx 0.18.5

* fix integer DPTs trying to cast str state with `int()`

* Delint

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-09 14:08:29 +02:00
rianadon
d3a4e21cb5 Convert ecobee pressure to local units (#51379)
* Convert ecobee pressure to local units

* Round inHg to 2 places
2021-06-09 14:06:24 +02:00
Pascal Vizeli
c21895facb Remove ASUS.gpio / not working with new GCC (#51662) 2021-06-09 13:33:41 +02:00
Franck Nijhof
a6a34c76f7 Add color mode support to WLED (#51648)
* Add color mode support to WLED

* Update homeassistant/components/wled/light.py

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

* Update homeassistant/components/wled/light.py

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

* Update homeassistant/components/wled/light.py

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

* Update homeassistant/components/wled/light.py

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

* black

* property, property

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2021-06-09 13:31:31 +02:00
Franck Nijhof
d021e593d3 Add Ambee integration (#51645) 2021-06-09 13:22:37 +02:00
Erik Montnemery
87813ea991 Tweak light.valid_supported_color_modes (#51659) 2021-06-09 12:53:08 +02:00
cklagenberg
f09f47f13a Add device trigger support for Philips Hue Wall Switch Module (#51574) 2021-06-09 12:06:02 +02:00
Maciej Bieniek
4e0c9dd18c Increase test coverage in Brother integration (#51657) 2021-06-09 11:52:21 +02:00
Erik Montnemery
443463e19d Emulate color_temp for lights which support color or white (#51654)
* Emulate color_temp for lights which support color or white

* Support legacy lights

* Tidy up group.light code

* Improve color_temp to white conversion

* Remove color_temp to white conversion

* Add test

* Tweak deconz test
2021-06-09 11:23:01 +02:00
dependabot[bot]
062e2bab67 Bump codecov/codecov-action from 1.5.0 to 1.5.2 (#51652)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-06-09 09:27:24 +02:00
Erik Montnemery
a1e3283f8f Improve editing of device automations referencing non-added sensors (#51312) 2021-06-08 23:28:08 -07:00
GitHub Action
6ed671dfda [ci skip] Translation update 2021-06-09 00:10:10 +00:00
Franck Nijhof
d0fa4e1d48 Upgrade wled to 0.5.0 (#51632) 2021-06-08 13:38:20 -07:00
J. Nick Koston
d56bd61b93 Populate upnp devices from ssdp (#51221)
* Populate upnp devices from ssdp

* Update tests since data comes in via HASS format now

* pylint
2021-06-08 22:32:06 +02:00
Erik Montnemery
eb687b7332 Bump hatasmota to 0.2.16 (#51623) 2021-06-08 20:49:13 +02:00
Pascal Vizeli
29a020886e Update Machine support of python 3.9 / Kernel CEC (#51637) 2021-06-08 20:48:49 +02:00
Martin Hjelmare
2eb6f16a94 Fix mysensors awesomeversion strategy usage (#51627)
* Update awesomeversion strategy use in mysensors

* Remove default version
2021-06-08 20:24:54 +02:00
Pawel
abbd4d1d16 Fix Onvif get_time_zone from device (#51620)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-08 20:01:36 +02:00
Pascal Vizeli
79da2bca3f Use baseimage 2021.06.0 / Python 3.9 - Alpine 3.13 (#51628) 2021-06-08 18:12:49 +02:00
Erik Montnemery
67f3e717a8 Add support for color_mode white to tasmota light (#51608) 2021-06-08 17:43:04 +02:00
J. Nick Koston
b3a67a2dd7 Bump sqlalchemy to 1.4.17 (#51593) 2021-06-08 16:53:51 +02:00
Yuval Aboulafia
7790e8f90c Static typing for Zodiac (#51622) 2021-06-08 16:03:28 +02:00
Martin Hjelmare
6de604a326 Fix mysensors tests typing (#51621) 2021-06-08 14:28:36 +02:00
Nick Whyte
3fa6c97801 Address late review of nsw fuel station (#51619) 2021-06-08 14:26:43 +02:00
blastoise186
fa42c676bb Reduce ovo_energy polling rate to be less aggressive (#51613)
* Reduce polling rate to be less aggressive

The current polling rate is too aggressive for the purpose, this commit reduces it to 12 hours to play nice with OVO.

* tweak polling to hourly
2021-06-08 14:20:15 +02:00
Maciej Bieniek
502939c430 Do not configure Shelly config entry created by custom component (#51616) 2021-06-08 13:23:25 +02:00
Franck Nijhof
4007430d72 Small entity attribute cleanup in AirVisual (#51601)
* Small entity attribute cleanup in AirVisual

* Fix icon in sensor update
2021-06-08 08:29:04 +02:00
Erik Montnemery
a4587b5f3b Deprecate support for undocumented value_template in MQTT light (#51589) 2021-06-08 08:23:51 +02:00
Erik Montnemery
4e5ec26ce6 Remove value_template from MQTT_RW_PLATFORM_SCHEMA (#51590) 2021-06-08 08:23:35 +02:00
Brian Towles
01d4140177 Modern Forms integration initial pass - Fan (#51317)
* Modern Forms integration initial pass

* cleanup of typing and nits

* Stripped PR down to Fan only

* Review cleanup

* Set sleep_time to be required for service

* Adjust minimum sleep time to one minute.

* Code review changes

* cleanup icon init a little
2021-06-08 08:22:50 +02:00
Malte Franken
51fa28aac3 Bump aio_geojson_geonetnz_volcano to v0.6 (#51602) 2021-06-08 07:36:23 +02:00
jjlawren
4ffa0dd199 Detect Sonos reboots and recreate subscriptions (#51377) 2021-06-07 20:51:42 -05:00
Milan Meulemans
d0a8e27036 Add Rituals number platform (#49723) 2021-06-08 03:28:31 +02:00
Michael Davie
ae86e96d34 Fix misaligned high/low temperatures in weather card (#49826) 2021-06-08 03:23:44 +02:00
jjlawren
de2dc92741 Handle missing section ID for Plex clips (#51598) 2021-06-08 03:17:14 +02:00
Martin Hjelmare
6c2e452e3d Fix kraken I/O and sleep in tests (#51599) 2021-06-08 03:11:17 +02:00
GitHub Action
330f713e43 [ci skip] Translation update 2021-06-08 00:21:17 +00:00
jjlawren
e257dd4d07 Fix Sonos battery sensors on S1 firmware (#51585) 2021-06-08 00:29:17 +02:00
Malte Franken
490c81aebc Bump georss_qld_bushfire_alert_client to 0.5 (#51596) 2021-06-08 00:24:54 +02:00
Clifford Roche
bc30920824 Correctly support use of Farenheit in Gree Climate component (#50260) 2021-06-08 00:21:03 +02:00
Robert Svensson
aad90b8644 Use supported color modes in Axis integration (#51557)
* Use supported color modes in Axis integration

* Fix Frencks comments

* Do Frencks suggestion
2021-06-08 00:03:33 +02:00
Paulus Schoutsen
e5028d285c Merge pull request #51595 from home-assistant/rc 2021-06-07 14:47:50 -07:00
Paulus Schoutsen
6b38480caf Bumped version to 2021.6.3 2021-06-07 14:15:39 -07:00
Erik Montnemery
4dd875199f Fix deprecated value_template for MQTT light (#51587) 2021-06-07 14:15:31 -07:00
Pascal Vizeli
70f4907414 Update builder to 2021.06.2 (#51582) 2021-06-07 14:15:30 -07:00
jjlawren
bd24431930 Fix Sonos restore calls (#51565) 2021-06-07 14:15:29 -07:00
J. Nick Koston
03f10333c4 Increase isy setup timeout to 60s (#51559)
- Ensure errors are displayed in the UI
2021-06-07 14:15:28 -07:00
stephan192
619e37b600 Bump dwdwfsapi to 1.0.4 (#51556) 2021-06-07 14:15:27 -07:00
Ron Klinkien
5016fd9fa8 Fix garmin_connect config flow multiple account creation (#51542) 2021-06-07 14:15:27 -07:00
Aaron Bach
45d94c7fc8 Bump aiorecollect to 1.0.5 (#51538) 2021-06-07 14:15:26 -07:00
J. Nick Koston
b807b8754b Ensure host is always set with samsungtv SSDP discovery (#51527)
There was a case where self._host could have been None
before _async_set_unique_id_from_udn was called

Fixes #51186
2021-06-07 14:15:25 -07:00
Malte Franken
8818df0663 Improve log message when zone missing in geolocation trigger (#51522)
* log warning message if zone cannot be found

* improve log message

* add test case
2021-06-07 14:15:24 -07:00
Ludovico de Nittis
b06558fa0a Bump pyialarm to 1.8.1 (#51519) 2021-06-07 14:15:23 -07:00
Ron Klinkien
b21076c599 Bump garminconnect_aio to 0.1.4 (#51507) 2021-06-07 14:15:22 -07:00
Daniel Hjelseth Høyer
ed68a268ad Fix missing Tibber power production (#51505)
Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2021-06-07 14:15:22 -07:00
J. Nick Koston
89db8d4519 Handle missing options in foreign_key for MSSQL (#51503) 2021-06-07 14:15:21 -07:00
Aidan Timson
96ade688d5 AsusWRT fix keyerror when firmver is missing from info (#51499)
Co-authored-by: Franck Nijhof <git@frenck.dev>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2021-06-07 14:15:20 -07:00
J. Nick Koston
703b088f86 Fix loop in tod binary sensor (#51491)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2021-06-07 14:15:19 -07:00
Felipe Martins Diel
0f3b73e75f Use a single job to ping all devices in the Broadlink integration (#51466) 2021-06-07 14:15:18 -07:00
Erik Montnemery
76edfe6c62 Fix deprecated value_template for MQTT light (#51587) 2021-06-07 14:14:42 -07:00
J. Nick Koston
ccf4b5a265 Move remaining code out of netdisco to eliminate as SSDP dependency (#51588) 2021-06-07 22:12:33 +02:00
Erik Montnemery
3db21b407a Add support for color_mode white to demo light (#51575)
* Add support for color_mode white to demo light

* Fix unique_id for newly added light

* Update tests
2021-06-07 20:26:25 +02:00
Aidan Timson
ab2951f124 AsusWRT fix keyerror when firmver is missing from info (#51499)
Co-authored-by: Franck Nijhof <git@frenck.dev>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2021-06-07 11:21:24 -07:00
J. Nick Koston
a3146ad150 Fix loop in tod binary sensor (#51491)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2021-06-07 11:21:10 -07:00
Franck Nijhof
a383198c0c Fully type switch entity component (#51586) 2021-06-07 19:36:34 +02:00
Pascal Vizeli
9ffdf9ea08 Update builder to 2021.06.2 (#51582) 2021-06-07 10:16:47 -07:00
Rolf Berkenbosch
1879a4acea Bump meteoalertapi to 0.2.0 (#51383)
* Update manifest.json

* Add version bump to requirements

* Add version bump to requirements

* Update manifest.json

* Update manifest.json

* Update requirements_all.txt
2021-06-07 18:08:34 +02:00
Malte Franken
67d9dc78cb Bump aio_georss_gdacs to 0.5 (#51577) 2021-06-07 17:57:44 +02:00
Andreas
88b60a44ad Bump nad_receiver to version 0.2.0 (#51381)
Co-authored-by: andreas-amlabs <andreas-amlabs@users.noreply.github.com>
2021-06-07 16:14:45 +02:00
Martin Hjelmare
7560a77e0e Type mysensors strictly (#51535) 2021-06-07 16:04:04 +02:00
Martin Hjelmare
564042ec67 Clean mysensors gateway type selection (#51531)
* Clean mysensors gateway type selection

* Fix comment grammar
2021-06-07 15:45:58 +02:00
Franck Nijhof
4c51299dcc Add easy converting string timestamps/dates to datetime objects in templates (#51576) 2021-06-07 15:02:15 +02:00
dependabot[bot]
4227a01e62 Bump home-assistant/wheels from 2021.05.4 to 2021.06.0 (#51569)
Bumps [home-assistant/wheels](https://github.com/home-assistant/wheels) from 2021.05.4 to 2021.06.0.
- [Release notes](https://github.com/home-assistant/wheels/releases)
- [Commits](https://github.com/home-assistant/wheels/compare/2021.05.4...2021.06.0)

---
updated-dependencies:
- dependency-name: home-assistant/wheels
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-06-07 14:54:18 +02:00
Franck Nijhof
f35929ba63 Allow referencing sensor entities for before/after in time conditions (#51444)
* Allow referencing sensor entities for before/after in time conditions

* Fix typo in variable naming

* Improve test coverage
2021-06-07 14:50:31 +02:00
Franck Nijhof
88386a7f44 Cleanup of Toon (#51230) 2021-06-07 13:24:07 +02:00
Robert Svensson
fb21affe45 Replace supported_features property with class attribute in deCONZ light entities (#51558)
* Replace supported_features property with class attribute

* attr_supported_features is already set to 0
2021-06-07 12:50:08 +02:00
J. Nick Koston
75dffee312 Increase isy setup timeout to 60s (#51559)
- Ensure errors are displayed in the UI
2021-06-07 11:49:37 +02:00
jjlawren
85ce679c64 Fix Sonos restore calls (#51565) 2021-06-07 11:46:56 +02:00
stephan192
ae83191121 Bump dwdwfsapi to 1.0.4 (#51556) 2021-06-07 10:53:36 +02:00
Ron Klinkien
b171c5ebe9 Fix garmin_connect config flow multiple account creation (#51542) 2021-06-07 10:09:08 +02:00
Daniel Perna
dc9b031544 Update pyhomematic to 0.1.73 (#51551) 2021-06-07 10:04:03 +02:00
GitHub Action
7615af35d8 [ci skip] Translation update 2021-06-07 00:18:16 +00:00
Colin Robbins
c43bdbf7c8 Add lightwave state_class and unique_id properties (#51544)
* Add state_class and unique_id properties

* Update homeassistant/components/lightwave/sensor.py

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

* fix isort

* set class via attribute

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-06 20:10:16 +02:00
Malte Franken
fcb8ab23ab Improve log message when zone missing in geolocation trigger (#51522)
* log warning message if zone cannot be found

* improve log message

* add test case
2021-06-06 20:03:56 +02:00
J. Nick Koston
f221deef2d Ensure from __future__ import annotations in irobot_base (#51554) 2021-06-06 19:59:58 +02:00
drinfernoo
5bbf0ca6ab Add workaround for missing cleaning time in roomba (#51163) 2021-06-06 12:13:35 +02:00
Erik Montnemery
e560e623e9 Add color_mode white (#51411)
* Add color_mode white

* Include brightness in white parameter

* Reformat

* Improve test coverage
2021-06-06 11:13:18 +02:00
jan iversen
50001684aa Add retries/retry_on_empty configuration parameters to Modbus (#51412)
* Add retries/retry_on_empty configuration parameters.

* Please review comment.
2021-06-06 09:13:50 +02:00
Aaron Bach
6a419483de Bump aiorecollect to 1.0.5 (#51538) 2021-06-06 08:31:11 +02:00
GitHub Action
c81df50191 [ci skip] Translation update 2021-06-06 00:19:43 +00:00
J. Nick Koston
8c00c24234 Ensure host is always set with samsungtv SSDP discovery (#51527)
There was a case where self._host could have been None
before _async_set_unique_id_from_udn was called

Fixes #51186
2021-06-06 00:02:36 +02:00
Martin Hjelmare
984695e99d Clean mysensors on_unload (#51521)
* Clean mysensors on_unload

* Fix docstring
2021-06-05 20:02:32 +02:00
jan iversen
59b5f94569 Add fix delay after send/request to allow RS485 adapter to switch in modbus (#51417) 2021-06-05 14:41:32 +02:00
jan iversen
b8afb7dcfe Check initial connect() worked in modbus (#51470)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-06-05 14:39:09 +02:00
Ludovico de Nittis
62dd9d62cb Bump pyialarm to 1.8.1 (#51519) 2021-06-05 14:11:39 +02:00
Martin Hjelmare
e73cdfab2f Fix mysensors typing (#51518)
* Fix device

* Fix init

* Fix gateway

* Fix config flow

* Fix helpers

* Remove mysensors from typing ignore list
2021-06-05 13:43:39 +02:00
Martin Hjelmare
7a6d067eb4 Bump mcstatus to 6.0.0 (#51517) 2021-06-05 13:26:35 +02:00
Martin Hjelmare
b61c8ce034 Disable gpmdp integration (#51509) 2021-06-05 12:15:03 +02:00
J. Nick Koston
06c9a50869 Handle missing options in foreign_key for MSSQL (#51503) 2021-06-05 12:13:12 +02:00
Ron Klinkien
f2692d4eaa Bump garminconnect_aio to 0.1.4 (#51507) 2021-06-05 12:07:52 +02:00
Daniel Hjelseth Høyer
634f6ba77b Fix missing Tibber power production (#51505)
Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2021-06-05 11:50:56 +02:00
J. Nick Koston
12ac4109f4 Ensure ssdp can callback messages that do not have an ST (#51436)
* Ensure ssdp can callback messages that do not have an ST

Sonos sends unsolicited messages when the device reboots. We want
to capture these to ensure we can recover the subscriptions as soon
as the device reboots

* Update homeassistant/components/ssdp/__init__.py

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

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-06-05 09:23:51 +02:00
GitHub Action
909140a7c6 [ci skip] Translation update 2021-06-05 00:23:17 +00:00
J. Nick Koston
0cd0733438 Remove empty tests for ping now that the code in icmplib is used (#51454) 2021-06-05 01:20:41 +03:00
Felipe Martins Diel
89d90bfb1b Use a single job to ping all devices in the Broadlink integration (#51466) 2021-06-04 11:03:13 -10:00
uchagani
7bf45f7bf7 Bump islamic-prayer-times to 0.0.5 (#51174)
* Bump islamic-prayer-times to 0.0.5

* update manifest file

* update requirements_all
2021-06-04 20:45:08 +02:00
Paulus Schoutsen
1da9ac38e8 Merge pull request #51488 from home-assistant/rc 2021-06-04 10:50:36 -07:00
Paulus Schoutsen
eb2f5c28a9 Bumped version to 2021.6.2 2021-06-04 10:07:09 -07:00
Paulus Schoutsen
f5dd838409 Protect our user agent (#51486)
* Protect our user agent

* Fix expected error
2021-06-04 10:07:05 -07:00
Franck Nijhof
8f741e0c6f Upgrade elgato to 2.1.1 (#51483) 2021-06-04 10:07:04 -07:00
Simone Chemelli
6dcde1b2a6 Improve logging for SamsungTV (#51477) 2021-06-04 10:07:03 -07:00
Aidan Timson
d9c6c3719c Bump aiolyric to 1.0.7 (#51473) 2021-06-04 10:07:03 -07:00
Matthias Alphart
e10a4c2a91 Update xknx to version 0.18.4 (#51459) 2021-06-04 10:07:02 -07:00
Matthias Alphart
c8655c8e37 xknx 0.18.3 (#51277) 2021-06-04 10:07:01 -07:00
J. Nick Koston
42c74c1e14 Retry isy994 setup later if isy.initialize times out (#51453)
Maybe fixes https://forum.universal-devices.com/topic/26633-home-assistant-isy-component/?do=findComment&comment=312147
2021-06-04 10:06:13 -07:00
Florent Thoumie
756a4c2ea6 Update to iaqualink 0.3.90 (#51452) 2021-06-04 10:06:12 -07:00
Paulus Schoutsen
6f4302ff70 Hot fix version of Apply modbus interval patch (#51487) 2021-06-04 19:02:42 +02:00
Franck Nijhof
05241a7a68 Allow number/sensor entities in numeric state conditions/triggers (#51439) 2021-06-04 18:14:48 +02:00
Paulus Schoutsen
ede7932a57 Protect our user agent (#51486)
* Protect our user agent

* Fix expected error
2021-06-04 09:14:18 -07:00
jan iversen
5e067c2631 Allow unlimited scan_interval in modbus (#51471)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-06-04 18:06:44 +02:00
Franck Nijhof
e41e153220 Upgrade elgato to 2.1.1 (#51483) 2021-06-04 09:02:59 -07:00
Simone Chemelli
3d8804bbcf Improve logging for SamsungTV (#51477) 2021-06-04 09:02:39 -07:00
Aidan Timson
12f2482c9b Bump aiolyric to 1.0.7 (#51473) 2021-06-04 17:26:44 +02:00
J. Nick Koston
5fc1822b43 Retry isy994 setup later if isy.initialize times out (#51453)
Maybe fixes https://forum.universal-devices.com/topic/26633-home-assistant-isy-component/?do=findComment&comment=312147
2021-06-04 08:54:45 +02:00
Matthias Alphart
e5c70c8789 Update xknx to version 0.18.4 (#51459) 2021-06-04 08:34:16 +02:00
Florent Thoumie
68f6506ff9 Update to iaqualink 0.3.90 (#51452) 2021-06-04 08:32:01 +02:00
Dermot Duffy
cf954881f6 Address Hyperion camera post-merge code review (#51457) 2021-06-04 08:24:38 +02:00
Eduard van Valkenburg
07d6186fea Small fixes in SIA (#51401)
* fixes from comment in #51206

* reverted name to async_
2021-06-03 20:43:15 -04:00
Paulus Schoutsen
bf3a561149 Bump aiohue to 2.5.1 (#51447) 2021-06-03 17:16:32 -07:00
Paulus Schoutsen
1aa6266fb4 Merge pull request #51449 from home-assistant/rc 2021-06-03 17:09:29 -07:00
Paulus Schoutsen
a3c5022956 Bumped version to 2021.6.1 2021-06-03 15:45:09 -07:00
Bram Kragten
eb45714c16 Update frontend to 20210603.0 (#51442) 2021-06-03 15:44:37 -07:00
Raman Gupta
e8aa578acc Bump zwave-js-server-python to 0.26.1 (#51425) 2021-06-03 15:44:37 -07:00
Jc2k
08e58e9f7d Bump aiohomekit to 0.2.67 (fixes #51391) (#51418) 2021-06-03 15:44:36 -07:00
Philip Allgaier
46ad5eeb63 Fix shopping list "complete all" service name (#51406) 2021-06-03 15:44:35 -07:00
Daniel Hjelseth Høyer
3bbf1e7c83 Fix Tibber Pulse device name and sensor update (#51402) 2021-06-03 15:44:34 -07:00
Raman Gupta
4cf2f49d7e Fix no value error for heatit climate entities (#51392) 2021-06-03 15:44:34 -07:00
jjlawren
10a64f17ce Handle Sonos connection issues better when polling (#51376) 2021-06-03 15:44:06 -07:00
Michael
768d49d7a6 Fix last activity consideration for AVM Fritz!Tools device tracker (#51375) 2021-06-03 15:43:22 -07:00
Michael
a232f2ce7d Fix last activity consideration for AVM Fritz!Tools device tracker (#51375) 2021-06-03 15:42:59 -07:00
Bram Kragten
65f23c45a8 Update frontend to 20210603.0 (#51442) 2021-06-03 15:41:59 -07:00
Paulus Schoutsen
f3b2624be3 Pin jinja (#51434) 2021-06-03 23:12:39 +02:00
Jc2k
836ce442f7 Bump aiohomekit to 0.2.67 (fixes #51391) (#51418) 2021-06-03 10:51:09 -10:00
Raman Gupta
b3327e1656 Bump zwave-js-server-python to 0.26.1 (#51425) 2021-06-03 15:11:45 -04:00
J. Nick Koston
c1111afef8 Allow registering a callback to ssdp that matches any key value (#51382) 2021-06-03 08:26:37 -10:00
Thomas Schamm
53ae340900 Bumped to boschshcpy==0.2.19 (#51416)
* Bumped to boschshcpy==0.2.19

* update requirements
2021-06-03 18:34:28 +02:00
Thomas Schamm
ffe8b3e49b Add bosch shc platforms for sensor devices (#50720) 2021-06-03 14:39:42 +02:00
Erik Montnemery
a6902ffd8a Remove is_standby from SwitchEntity (#51400) 2021-06-03 14:21:52 +02:00
Philip Allgaier
470514cb08 Fix shopping list "complete all" service name (#51406) 2021-06-03 12:40:00 +02:00
Daniel Hjelseth Høyer
1062acfe9b Fix Tibber Pulse device name and sensor update (#51402) 2021-06-03 11:59:22 +02:00
Eduard van Valkenburg
e8762bdea1 Add binary sensor platform to SIA integration (#51206)
* add support for binary_sensor

* added default enabled for binary sensors

* fixed coverage and a import deleted

* disable pylint for line

* Apply suggestions from code review

* split binary sensor and used more attr fields

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2021-06-03 08:39:44 +02:00
uvjustin
55f158cf78 Fix HLS idle timer in stream (#51372) 2021-06-02 21:31:39 -07:00
jjlawren
2c9e6bd927 Handle Sonos connection issues better when polling (#51376) 2021-06-02 21:10:27 -07:00
Raman Gupta
ba6a0b5793 Fix no value error for heatit climate entities (#51392) 2021-06-02 21:07:47 -07:00
GitHub Action
7f6e20dcbc [ci skip] Translation update 2021-06-03 00:26:58 +00:00
Jan Bouwhuis
2222a121f4 Add support for fan speed percentage and preset modes to google_assistant integration (#50283)
* support relative fan speeds

* fan preset modes

* improve tests

* Revert relative speed code report zero percentage
2021-06-02 22:09:22 +02:00
definitio
132ee972bd Add media_player.group (#38855)
* Add media group

* Minor improvements

* Use the async api for all methods

* Improve type hints

* Add missing methods

* Add tests

* Rename HomeAssistantType —> HomeAssistant

* Add more tests

* Fix unknown state

* Make some callbacks

* Add more tests

* Fix unknown state properly

* Fix names for callbacks

* Fix stop service test

* Improve tests
2021-06-02 21:25:15 +02:00
Dermot Duffy
c057c9d9ab Add Hyperion camera feed (#46516)
* Initial Hyperion camera.

* Improve test coverage.

* Minor state fixes.

* Fix type annotation.

* May rebase and updates (mostly typing).

* Updates to use new camera typing improvements.

* Use new support for returning None from async_get_mjpeg_stream .

* Codereview feedback.

* Lint: Use AsyncGenerator from collections.abc .

* Update homeassistant/components/hyperion/camera.py

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2021-06-02 09:39:19 -07:00
J. Nick Koston
68714c2067 Update ping to use asyncio function in icmplib (#50808) 2021-06-02 06:10:33 -10:00
Daniel Hjelseth Høyer
31bd41582b Fix Tibber timestamps parsing (#51368) 2021-06-02 08:16:04 -07:00
Franck Nijhof
25c0739e22 Mark state final in BinarySensorEntity (#51234) 2021-06-02 14:32:25 +02:00
gadgetmobile
931ff70ebe Fix BleBox wLightBoxS and gateBox support (#51367)
Co-authored-by: bbx-jp <83213200+bbx-jp@users.noreply.github.com>
2021-06-02 14:02:37 +02:00
Guido Schmitz
3de29a7606 Add binary_sensor tests for devolo Home Control (#49843)
Co-authored-by: Markus Bong <Markus.Bong@devolo.de>
2021-06-02 13:59:35 +02:00
Erik Montnemery
1d9d9021de Do not attempt to unload non loaded config entries (#51356) 2021-06-02 10:00:24 +02:00
Franck Nijhof
d51fc5814a Define ToggleEntity entity attributes as class variables (#51231)
* Define ToggleEntity entity attributes as class variables

* Fix upcloud overriding state property

* Implement available state for upcloud, to compensate removed state
2021-06-02 08:53:55 +02:00
Aaron Bach
101864aab8 Bump pyiqvia to 1.0.0 (#51357) 2021-06-01 20:35:12 -07:00
jan iversen
10dccc6734 Move pymodbus test fixtures to test_init (#51244) 2021-06-02 00:00:44 +02:00
Martin Hjelmare
783e545a67 Bump hangups to 0.4.14 (#51355) 2021-06-01 22:55:22 +02:00
Franck Nijhof
5d33cd05a8 SolarEdge: Move coordinators out of sensor platform (#51348) 2021-06-01 22:50:32 +02:00
Bram Kragten
bee89a12ec Update frontend to 20210601.1 (#51354) 2021-06-01 13:35:13 -07:00
Paulus Schoutsen
ee2c950716 Merge system options into pref properties (#51347)
* Make system options future proof

* Update tests

* Add types
2021-06-01 22:34:31 +02:00
jjlawren
9e3ee73b8b Handle incomplete Sonos alarm event payloads (#51353) 2021-06-01 13:28:56 -07:00
Daniel Hjelseth Høyer
12b8672f84 Use entity class vars for Melcloud (#51351)
Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2021-06-01 22:21:07 +02:00
Franck Nijhof
fcdd8b11a6 Collection of changing entity properties to class attributes - 2 (#51345) 2021-06-01 12:43:55 -07:00
Eduard van Valkenburg
e5dff49440 Fix SIA event data func (#51339) 2021-06-01 20:32:17 +02:00
Martin Hjelmare
91b6f9d7d0 Bump zwave-js-server-python to 0.26.0 (#51341) 2021-06-01 19:26:54 +02:00
definitio
6a474e74e8 Fix Snapcast state after restoring snapshot (#51340) 2021-06-01 19:07:51 +02:00
Franck Nijhof
cdd1f6b2f0 Always load middle to handle forwarded proxy data (#51332) 2021-06-01 09:38:55 -07:00
Tobias Sauerwein
d975f9eb0a Fix Netatmo sensor logic (#51338) 2021-06-01 17:58:25 +02:00
Franck Nijhof
c5dc99c052 Fix time condition microsecond offset when using input helpers (#51337) 2021-06-01 17:57:23 +02:00
Erik Montnemery
63e16de6c0 Improve time condition trace (#51335) 2021-06-01 17:07:45 +02:00
Joakim Sørensen
fb281c6bde Add arch to payload (#51330) 2021-06-01 15:09:23 +02:00
Shay Levy
f3715cef6d Bump aioswitcher to 1.2.3 (#51324) 2021-06-01 13:48:53 +02:00
Paulus Schoutsen
bd0373388d Trusted networks auth provider warns if detects a requests with x-forwarded-for header while the http integration is not configured for reverse proxies (#51319)
* Trusted networks auth provider to require http integration configured for proxies to allow logging in with requests with x-forwarded-for header

* Make it a warning
2021-06-01 12:51:44 +02:00
Bram Kragten
94ae8396dd Update frontend to 20210601.0 (#51329) 2021-06-01 12:38:49 +02:00
Paulus Schoutsen
45e1473f83 Improve config validation for key_value_schemas (#49429) 2021-06-01 11:23:59 +02:00
Maciej Bieniek
ed9b199372 Fix exception after removing Shelly config entry and stopping HA (#51321)
* Fix device shutdown twice

* Change if logic
2021-06-01 11:41:34 +03:00
Raman Gupta
b91696c139 Switch to using entity class attributes where possible in zwave_js (#51207)
* Switch to using entity class attributes where possible in zwave_js

* fix

* revert docstring

* remove unused init

* Revert some changes based on feedback in #51181

* switch to class atributes
2021-06-01 10:26:22 +02:00
Franck Nijhof
6b0e57e641 Define SwitchEntity entity attributes as class variables (#51232) 2021-06-01 10:23:10 +02:00
Eugenio Panadero
3d45f00fad Bump aiopvpc to apply quickfix for new electricity price tariff (#51320)
Since 2021-06-01, the three PVPC price tariffs become one and only: '2.0 TD',
and the JSON schema from the official API (data source of this integration)
is slightly different.

This patch allows a no-pain jump between the old tariffs and the new one.
2021-06-01 09:45:37 +02:00
Daniel Rheinbay
3c452f8c9b Refactor yeelight integration to use only flows (#51255)
* Refactor light.py to use only flows.py, eliminating transitions.py

* Reformat yeelight source code using black
2021-06-01 09:04:49 +02:00
Matthias Alphart
549b0b0727 KNX: Support for XY-color lights (#51306)
* support for xy-color

* replace invalid name
2021-06-01 08:59:51 +02:00
Matthias Alphart
164e45f0a7 KNX: move some Schema to schema.py (#51307)
* create platform schema node from schema class

* move connection schema to schema.py

* rename SCHEMA to ENTITY_SCHEMA

* Final module level constants
2021-06-01 08:59:23 +02:00
Franck Nijhof
fb682665e2 Upgrade pylint to 2.8.3 (#51308) 2021-06-01 08:48:53 +02:00
AJ Schmidt
0e0da26852 update adext dependency (#51315) 2021-06-01 08:44:56 +02:00
GitHub Action
2a746acf3a [ci skip] Translation update 2021-06-01 00:30:06 +00:00
Paulus Schoutsen
f472219c68 Set up cloud semi-dependencies at start (#51313) 2021-06-01 01:35:31 +02:00
Paulus Schoutsen
354dd39f24 Updated frontend to 20210531.1 (#51314) 2021-06-01 01:35:08 +02:00
Paulus Schoutsen
4821484d2c Add system option to disable polling (#51299) 2021-05-31 15:36:40 -07:00
Joakim Sørensen
5d6b6deed4 Move version validation to resolver (#51311) 2021-05-31 15:32:03 -07:00
Jc2k
95362d4215 Bump aiohomekit to 0.2.66 (#51310) 2021-05-31 17:28:14 -05:00
Joakim Plate
6631a4e605 Philips TV ambilight support (#44867) 2021-05-31 14:39:28 -07:00
Ron Klinkien
a0b3d0863b Fix Garmin Connect integration with python-garminconnect-aio (#50865) 2021-05-31 14:38:33 -07:00
Robert Svensson
6ba2ee5cef Fix stream profiles not available as expected (#51305) 2021-05-31 14:35:33 -07:00
Jan Bouwhuis
7403ba1e81 Alexa fan preset_mode support (#50466)
* fan preset_modes

* process preset mode updates from alexa correctly

* add tests

* codecov patch additional tests
2021-05-31 20:58:01 +02:00
J. Nick Koston
0e7c2cddf7 Upgrade HAP-python to 3.5.0 (#51261)
* Upgrade HAP-python to 3.4.2

- Fixes for malformed event sending

- Performance improvements

* Bump

* update tests to point to async
2021-05-31 20:47:12 +02:00
Franck Nijhof
5a4add6437 Upgrade black to 21.5b2 (#51297) 2021-05-31 21:04:20 +03:00
Austin Drummond
d2623bf574 AppleTV typo in error notification (#51300)
An extraneous "f" was prefix at the beginning of the notification.

>An irrecoverable connection problem occurred when connecting to fApple TV. Please go to the Integrations page and reconfigure it.
2021-05-31 20:59:55 +03:00
Nikolai
52e7d57533 Processing of messages from channel by telegram_bot (#51274)
* Processing of messages from channel by telegram_bot

* formatted using Black

* refactor

* check allowed chat
2021-05-31 16:35:49 +02:00
Maciej Bieniek
c9178e58b5 Add support for state class for Airly sensor (#51285) 2021-05-31 16:00:58 +02:00
Franck Nijhof
edcae74330 Entity attributes + typing fix in deCONZ alarm control panel (#51241) 2021-05-31 14:54:42 +02:00
Salvatore Mazzarino
5377e5ed38 Update to pygtfs 0.1.6 (#51267)
* Update to pygtfs 0.1.6

Signed-off-by: Salvatore Mazzarino <dev@mazzarino.cz>

* run tasks: generate requirements
2021-05-31 14:45:56 +02:00
Joakim Sørensen
8ed8747225 Resolve addon repository slug for device registry (#51287)
* Resolve addon repository slug for device registry

* typo

* Adjust onboarding test

* Use /store
2021-05-31 14:06:11 +02:00
Pascal Vizeli
3d119fd4ab Revert "GRPC is fixed, don't need a workaround" (#51289)
This reverts commit 9d174e8a05.
2021-05-31 14:03:26 +02:00
Franck Nijhof
258b388f41 Collection of changing entity properties to class attributes (#51248)
* Collection of changing entity properties to class attributes

* Apply suggestions from code review

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

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2021-05-31 10:50:11 +02:00
Matthias Alphart
5acc3a1083 xknx 0.18.3 (#51277) 2021-05-31 09:58:48 +02:00
Erik Montnemery
532626b738 Move light helper get_supported_color_modes (#51269) 2021-05-31 09:47:58 +02:00
Erik Montnemery
04e9acc20a Simplify device condition code (#51266) 2021-05-31 09:47:30 +02:00
Erik Montnemery
489c73b4da Simplify device action code (#51263) 2021-05-31 09:47:15 +02:00
Raman Gupta
a8650f4e59 Add zwave_js node status sensor (#51181)
* Add zwave_js node status sensor

* fix import

* use parent class name property

* Use more entity class attributes

* Update homeassistant/components/zwave_js/sensor.py

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

* return static values in property method

* fix PR

* switch to class atributes

* create sensor platform task if needed

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-05-31 08:46:28 +02:00
Paulus Schoutsen
7654672dd0 Updated frontend to 20210531.0 (#51281) 2021-05-30 21:04:13 -07:00
jjlawren
e5309e89ea Skip processed Sonos alarm updates (#51217)
* Skip processed Sonos alarm updates

* Fix bad conflict merge
2021-05-30 21:03:53 -07:00
Tobias Sauerwein
9bd74961f0 Fix unnecessary API calls in Netatmo (#51260) 2021-05-30 20:55:45 -07:00
jjlawren
1a5d35d7bf Only debug log new Sonos SSDP discoveries (#51247)
* Only debug log new SSDP discoveries

* Use existing reference

* Remove from known on unseen

* Update homeassistant/components/sonos/speaker.py

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

Co-authored-by: J. Nick Koston <nick@koston.org>
2021-05-30 20:28:22 -05:00
GitHub Action
319071ba39 [ci skip] Translation update 2021-05-31 00:25:51 +00:00
Daniel Hjelseth Høyer
0ae64325ed Use entity class vars for Mill (#51264)
Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2021-05-30 17:58:55 +03:00
Matt Zimmerman
416d91ba85 Clean up SmartTub (#51257)
* fix type hint

* pylint

* Update homeassistant/components/smarttub/binary_sensor.py

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

* Update homeassistant/components/smarttub/binary_sensor.py

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

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-05-30 10:10:49 +02:00
Franck Nijhof
c317854e86 Small optimization in entity registry enabled deConz method (#51250) 2021-05-29 23:12:19 -05:00
J. Nick Koston
32dc62a996 Handle empty ssdp descriptions in the cache (#51253) 2021-05-29 22:50:48 -05:00
uvjustin
3ca7eb9440 Update HLS playlist in stream (#51191)
* Enable gzip encoding for playlist responses
* Add EXT-X-PROGRAM-DATE-TIME to playlist
* Add EXT-X-START to playlist
* Change EXT-X-VERSION from 7 to 6
* Move idle timer call to recv
* Refactor recv to remove cursor and return bool
* Rename STREAM_TIMEOUT to SOURCE_TIMEOUT
2021-05-30 11:41:23 +08:00
GitHub Action
2077efb207 [ci skip] Translation update 2021-05-30 00:24:18 +00:00
astronaut
ceadb0cba0 Add gui config option consider device unavailable (#51218)
* Add gui config option consider device unavailable

* Update tests
2021-05-29 19:13:09 -04:00
Franck Nijhof
d1f0ec8db8 Small tweaks to LaCrosse (#51249) 2021-05-29 23:08:25 +03:00
Ludovico de Nittis
ff6d05a200 Bump pyialarm to 1.7 (#51233) 2021-05-29 18:50:45 +02:00
Franck Nijhof
06e5314bc8 Cleanup commented code + comprehensions in iOS (#51238) 2021-05-29 17:28:32 +02:00
Franck Nijhof
99afa15f47 Cleanup unneeded variable assignment in ezviz (#51239) 2021-05-29 17:34:25 +03:00
jjlawren
3d2f696d73 Reorganize SonosSpeaker class for readability (#51222) 2021-05-29 09:08:46 -05:00
Erik Montnemery
27b9d7fed0 Fix flaky statistics tests (#51242) 2021-05-29 09:00:36 -05:00
J. Nick Koston
c5e5787e1d Replace sonos discovery thread with ssdp callback registration (#51033)
Co-authored-by: jjlawren <jjlawren@users.noreply.github.com>
2021-05-29 08:31:22 -05:00
Franck Nijhof
255e13930c Define CoverEntity entity attributes as class variables (#51236)
* Define CoverEntity entity attributes as class variables

* Fix supported features
2021-05-29 14:35:02 +02:00
Tobias Sauerwein
d66d7cbd37 Fix Netatmo data class update (#51215)
* Catch if data class entry is None

* Guard
2021-05-29 14:10:45 +02:00
J. Nick Koston
d1132270b4 Remove double schema validation in network (#51219) 2021-05-29 14:09:49 +02:00
Ville Skyttä
c2f5dcefa5 Use flow result type constants more (#51122) 2021-05-29 14:09:13 +02:00
Maciej Bieniek
b6716ecebd Add discovery by manufacturer to Nettigo Air Monitor integration (#51155) 2021-05-29 14:06:56 +02:00
Erik Montnemery
4d428b87cb Remove incorrect check in Alexa for SERVICE_ALARM_DISARM fail (#51224) 2021-05-29 14:06:02 +02:00
jjlawren
bd34059c11 Fix use of async in Sonos switch (#51210)
* Fix use of async in Sonos switch

* Simplify

* Convert to callback
2021-05-28 23:28:07 -05:00
jjlawren
84f0d3f961 Centralize Sonos subscription logic (#51172)
* Centralize Sonos subscription logic

* Clean up mocked Sonos Service instances, use subscription callback

* Use existing mocked attributes

* Use event dispatcher dict, move methods together, make update_alarms sync

* Create dispatcher dict once
2021-05-28 21:32:50 -05:00
J. Nick Koston
fb50cf9840 Add network and callback support to SSDP (#51019)
Co-authored-by: Ruslan Sayfutdinov <ruslan@sayfutdinov.com>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2021-05-28 21:18:59 -05:00
Nick Whyte
02cbb2025e Decrease nsw fuel request volume (#49552) 2021-05-28 20:53:20 -05:00
GitHub Action
8e87d638e1 [ci skip] Translation update 2021-05-29 00:21:56 +00:00
jjlawren
4b2831ddde Improve Sonos alarm logging (#51212) 2021-05-29 00:45:43 +02:00
Raman Gupta
19c16e079f Add separate ozone sensor for climacell (#51182) 2021-05-28 23:24:01 +02:00
Erik Montnemery
39c94e8daa Fix flaky statistics tests (#51214)
* Fix flaky statistics tests

* Tweak
2021-05-28 22:37:17 +02:00
jan iversen
538a189168 Adjust modbus climate to use address/input_type (#51202) 2021-05-28 17:57:14 +02:00
Brandon Rothweiler
88dce0ec8f Address late review of Mazda services (#51178)
* Add services for Mazda integration

* Address review comments

* Follow-up review comments

* Update dict access for send_poi service calls
2021-05-28 17:54:19 +02:00
Vilppu Vuorinen
99ee2bd0a3 Update to pymelcloud 2.5.3 (#51043)
Previous version of pymelcloud performs requests that are not permitted
for guest users. Bypassing these requests results only in less detailed
device info.
2021-05-28 16:48:30 +02:00
J. Nick Koston
b3d826f2e2 Fix samsungtv yaml import without configured name (#51204) 2021-05-28 16:06:17 +02:00
Martin Hjelmare
187374c11e Set Registry name parameter to Hashable type (#51203) 2021-05-28 15:29:11 +02:00
Bram Kragten
0fbdce5ca6 Update frontend to 20210528.0 (#51199) 2021-05-28 14:38:01 +02:00
Joakim Sørensen
076544a1b5 Revert "Bump config version to 2 for AVM Fritz Tools (#51176)" (#51193) 2021-05-28 14:00:16 +02:00
Álvaro Fernández Rojas
fe0771f7f1 Add missing outdoor temperature unit for Tado (#51197)
* Fix outdoor temperature unit for Tado

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

* tado: simplify if conditions

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2021-05-28 13:41:40 +02:00
Tobias Sauerwein
ac922916c1 Fix Netatmo sensor initialization (#51195) 2021-05-28 13:36:22 +02:00
Joakim Plate
b6cb123c4f Only run philips_js notify service while TV is turned on (#51196)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-05-28 13:32:26 +02:00
jan iversen
00507539c1 Change Cover to use address/input_type (#51154)
* Change Cover to use address/input_type.

* Flake.
2021-05-28 13:23:44 +02:00
Pascal Vizeli
ab2ea35b7d Update base image to 2021.05.0 (#51198) 2021-05-28 13:22:58 +02:00
Erik Montnemery
b339d73109 Weight sensor average statistics by state durations (#51150)
* Weight sensor average statistics by state durations

* Fix test
2021-05-28 13:16:52 +02:00
Franck Nijhof
17b2678aee Define media_player entity attributes as class variables (#51192) 2021-05-28 12:32:31 +02:00
jjlawren
39e62f9c90 Improve Sonos polling (#51170)
* Improve Sonos polling

Warn user if polling is being used
Provide callback IP:port to help user fix networking
Fix radio handling when polling (no event payload)
Clarify dispatch target to reflect polling action

* Lint

* Revert method removal
2021-05-28 12:07:58 +02:00
jan iversen
e45196f9c9 Remove "old" config from modbus binary_sensor (#51117) 2021-05-28 12:06:46 +02:00
Joakim Sørensen
81097dbe40 Use get with default for consider home (#51194) 2021-05-28 12:02:35 +02:00
jan iversen
5afd16ef5d Move modbus schema validators to validators.py (#51121) 2021-05-28 11:38:31 +02:00
jan iversen
47f016b340 Remove old config from cover, including tests (#51118)
* Remove old config and standardize new config.

* Add missing safeguard.
2021-05-28 11:29:37 +02:00
Michael
d200f1e504 Bump config version to 2 for AVM Fritz Tools (#51176) 2021-05-28 11:12:46 +02:00
Franck Nijhof
538a03ee0c Clean up Speedtest.net Sensors (#51124) 2021-05-28 11:10:01 +02:00
Erik Montnemery
837220cce4 Add deprecated backwards compatible history.LazyState (#51144) 2021-05-28 11:01:28 +02:00
dependabot[bot]
e41fbdc9eb Bump actions/cache from 2.1.5 to 2.1.6 (#51185)
Bumps [actions/cache](https://github.com/actions/cache) from 2.1.5 to 2.1.6.
- [Release notes](https://github.com/actions/cache/releases)
- [Commits](https://github.com/actions/cache/compare/v2.1.5...v2.1.6)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-28 10:42:22 +02:00
Franck Nijhof
0b15f3aa98 Define alarm_control_panel entity attributes as class variables (#51120)
* Define alarm_control_panel entity attributes as class variables

* Example Verisure

* Remove redundant AttributeError
2021-05-28 08:29:01 +02:00
Franck Nijhof
e9b09325c9 Use entity class vars in SolarEdge (#51123) 2021-05-28 08:24:55 +02:00
Tobias Sauerwein
eb66f8ef6d Fix Netatmo data class update (#51177) 2021-05-28 08:00:11 +02:00
uvjustin
6ad29aec2c Adjust segment duration calculation in stream (#51149)
* Calculate min segment duration internally

* Rename segments to sequences in StreamOutput

* Fix segment duration calculation in test_worker
2021-05-28 13:36:41 +08:00
jjlawren
e08de22737 Fix totalconnect test calling public host (#51138) 2021-05-27 21:30:37 -05:00
Raman Gupta
ca8d09e5e1 Add zwave_js.multicast_set_value service (#51115)
* Add zwave_js.multicast_set_value service

* comment

* Add test for multiple config entries validation

* additional validation test

* brevity

* wrap schema in vol.Schema

* Update homeassistant/components/zwave_js/services.py

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

* do node transform and multicast validation in schema validation

* move poll value entity validation into schema validation, pass helper functions dev and ent reg instead of retrieving it every time

* make validators nested functions since they don't neeed to be externally accessible

* Update homeassistant/components/zwave_js/services.py

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

* Remove errant ALLOW_EXTRA

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-05-27 21:57:35 -04:00
GitHub Action
93ada0a675 [ci skip] Translation update 2021-05-28 00:19:07 +00:00
Greg Dowling
02ac9a75b1 Bump pyroon to 0.0.37 (#51164) 2021-05-27 21:01:04 +02:00
Aaron David Schneider
f7f8672eea Add tests for sonos switch platform (#51142)
* add tests

* refactor async_added_to_hass

* fix tests and race condition

* use async_get

* typo
2021-05-27 19:56:59 +02:00
Franck Nijhof
7dff4d6ad7 Define climate entity attributes as class variables (#51006) 2021-05-27 17:39:43 +02:00
tkdrob
d1c4d0de49 Use bool annotations for setup entries (#51166) 2021-05-27 17:39:06 +02:00
Shay Levy
b6355bcb48 Add myself to Switcher codeowners (#51158) 2021-05-27 17:37:54 +02:00
tkdrob
c0656878db Normalize async_setup_entry (#51161) 2021-05-27 15:56:20 +02:00
Eduard van Valkenburg
701c4ee624 Update sia tests (#51151) 2021-05-27 15:35:17 +02:00
Franck Nijhof
d9eb1d85a2 Clean up DNS IP integration (#51143)
* Clean up DNS IP integration

* Commit missing change oops
2021-05-27 15:10:28 +03:00
Franck Nijhof
eb2b60434c Clean up Local IP integration (#51126) 2021-05-27 15:04:40 +03:00
ollo69
69e454fd49 Add missing function signature (#51153) 2021-05-27 14:52:05 +03:00
René Klomp
65f2fe9c01 Bump pysma version to 0.5.0 (#51098)
* Use new get_sensors method

* Update pysma requirement

* Update primary codeowner

* Update device_info handling

* Fix LEGACY_MAP

* Updated tests

* Fix pysma references

* Fix pylint raise-missing-from

* Better import of Sensors

* Remove software version related changes

* Revert codeowners change
2021-05-27 12:53:14 +02:00
Eduard van Valkenburg
cede36d91c Followup PR for SIA integration (#51108)
* Updates based on Martin's review

* fix strings and cleaned up constants
2021-05-27 10:55:47 +02:00
jjlawren
f0952d3ee8 Fix Sonos media position with radio sources (#51137) 2021-05-27 10:53:51 +02:00
jan iversen
8d365e8bf5 After merge, review. (#51139) 2021-05-27 08:28:31 +02:00
Anders Melchiorsen
fdfb84e8e2 Upgrade pysonos to 0.0.50 (#51125) 2021-05-27 08:13:10 +02:00
jjlawren
e4e3dc7fab Fix Sonos TV source attribute (#51131) 2021-05-26 22:12:43 -07:00
Raman Gupta
877d3e38b4 Fix zwave_js.set_value schema (#51114)
* fix zwave_js.set_value schema

* wrap all schemas in vol.Schema

* readd removed assertions
2021-05-27 00:27:35 -04:00
Joakim Sørensen
3e7729faf2 Handle blank string in location name for mobile app (#51130) 2021-05-27 06:04:05 +02:00
uvjustin
38e0cbe964 Change stream sequence number to start from 0 (#51101)
* Use constants for provider strings

* Add last_sequence property
2021-05-27 11:22:31 +08:00
GitHub Action
f45bc3abc7 [ci skip] Translation update 2021-05-27 00:17:03 +00:00
Franck Nijhof
d829df332d Bump version to 2021.7.0dev0 (#51116) 2021-05-26 20:18:29 +02:00
Yuriy Sannikov
6391d75919 Refactor ModbusRegisterSensor class to get hub and configuration (#50234)
* refactor ModbusRegisterSensor to match the ModbusSwitch interface

* Please pylint, mypy etc.

* Remove PLATFORM.

Co-authored-by: jan Iversen <jancasacondor@gmail.com>
2021-05-26 19:28:14 +02:00
2094 changed files with 59393 additions and 19890 deletions

View File

@@ -115,12 +115,14 @@ omit =
homeassistant/components/bmw_connected_drive/notify.py
homeassistant/components/bmw_connected_drive/sensor.py
homeassistant/components/bosch_shc/__init__.py
homeassistant/components/bosch_shc/const.py
homeassistant/components/bosch_shc/binary_sensor.py
homeassistant/components/bosch_shc/const.py
homeassistant/components/bosch_shc/entity.py
homeassistant/components/bosch_shc/sensor.py
homeassistant/components/braviatv/__init__.py
homeassistant/components/braviatv/const.py
homeassistant/components/braviatv/media_player.py
homeassistant/components/braviatv/remote.py
homeassistant/components/broadlink/__init__.py
homeassistant/components/broadlink/const.py
homeassistant/components/broadlink/remote.py
@@ -152,7 +154,7 @@ omit =
homeassistant/components/clicksend_tts/notify.py
homeassistant/components/cmus/media_player.py
homeassistant/components/co2signal/*
homeassistant/components/coinbase/*
homeassistant/components/coinbase/sensor.py
homeassistant/components/comed_hourly_pricing/sensor.py
homeassistant/components/comfoconnect/fan.py
homeassistant/components/concord232/alarm_control_panel.py
@@ -182,11 +184,9 @@ omit =
homeassistant/components/denonavr/media_player.py
homeassistant/components/denonavr/receiver.py
homeassistant/components/deutsche_bahn/sensor.py
homeassistant/components/devolo_home_control/binary_sensor.py
homeassistant/components/devolo_home_control/climate.py
homeassistant/components/devolo_home_control/const.py
homeassistant/components/devolo_home_control/cover.py
homeassistant/components/devolo_home_control/devolo_device.py
homeassistant/components/devolo_home_control/devolo_multi_level_switch.py
homeassistant/components/devolo_home_control/light.py
homeassistant/components/devolo_home_control/sensor.py
@@ -221,6 +221,7 @@ omit =
homeassistant/components/ecobee/__init__.py
homeassistant/components/ecobee/binary_sensor.py
homeassistant/components/ecobee/climate.py
homeassistant/components/ecobee/humidifier.py
homeassistant/components/ecobee/notify.py
homeassistant/components/ecobee/sensor.py
homeassistant/components/ecobee/weather.py
@@ -273,6 +274,7 @@ omit =
homeassistant/components/esphome/entry_data.py
homeassistant/components/esphome/fan.py
homeassistant/components/esphome/light.py
homeassistant/components/esphome/number.py
homeassistant/components/esphome/sensor.py
homeassistant/components/esphome/switch.py
homeassistant/components/essent/sensor.py
@@ -341,6 +343,7 @@ omit =
homeassistant/components/fritz/device_tracker.py
homeassistant/components/fritz/sensor.py
homeassistant/components/fritz/services.py
homeassistant/components/fritz/switch.py
homeassistant/components/fritzbox_callmonitor/__init__.py
homeassistant/components/fritzbox_callmonitor/const.py
homeassistant/components/fritzbox_callmonitor/base.py
@@ -541,15 +544,12 @@ omit =
homeassistant/components/lastfm/sensor.py
homeassistant/components/launch_library/const.py
homeassistant/components/launch_library/sensor.py
homeassistant/components/lcn/__init__.py
homeassistant/components/lcn/binary_sensor.py
homeassistant/components/lcn/climate.py
homeassistant/components/lcn/const.py
homeassistant/components/lcn/cover.py
homeassistant/components/lcn/helpers.py
homeassistant/components/lcn/light.py
homeassistant/components/lcn/scene.py
homeassistant/components/lcn/schemas.py
homeassistant/components/lcn/sensor.py
homeassistant/components/lcn/services.py
homeassistant/components/lcn/switch.py
@@ -613,6 +613,7 @@ omit =
homeassistant/components/meteoalarm/*
homeassistant/components/meteoclimatic/__init__.py
homeassistant/components/meteoclimatic/const.py
homeassistant/components/meteoclimatic/sensor.py
homeassistant/components/meteoclimatic/weather.py
homeassistant/components/metoffice/sensor.py
homeassistant/components/metoffice/weather.py
@@ -690,7 +691,7 @@ omit =
homeassistant/components/niko_home_control/light.py
homeassistant/components/nilu/air_quality.py
homeassistant/components/nissan_leaf/*
homeassistant/components/nmap_tracker/device_tracker.py
homeassistant/components/nmap_tracker/*
homeassistant/components/nmbs/sensor.py
homeassistant/components/notion/__init__.py
homeassistant/components/notion/binary_sensor.py
@@ -769,6 +770,7 @@ omit =
homeassistant/components/pcal9535a/*
homeassistant/components/pencom/switch.py
homeassistant/components/philips_js/__init__.py
homeassistant/components/philips_js/light.py
homeassistant/components/philips_js/media_player.py
homeassistant/components/philips_js/remote.py
homeassistant/components/pi_hole/sensor.py
@@ -846,6 +848,8 @@ omit =
homeassistant/components/ripple/sensor.py
homeassistant/components/rituals_perfume_genie/binary_sensor.py
homeassistant/components/rituals_perfume_genie/entity.py
homeassistant/components/rituals_perfume_genie/number.py
homeassistant/components/rituals_perfume_genie/select.py
homeassistant/components/rituals_perfume_genie/sensor.py
homeassistant/components/rituals_perfume_genie/switch.py
homeassistant/components/rituals_perfume_genie/__init__.py
@@ -921,9 +925,11 @@ omit =
homeassistant/components/slack/notify.py
homeassistant/components/sia/__init__.py
homeassistant/components/sia/alarm_control_panel.py
homeassistant/components/sia/binary_sensor.py
homeassistant/components/sia/const.py
homeassistant/components/sia/hub.py
homeassistant/components/sia/utils.py
homeassistant/components/sia/sia_entity_base.py
homeassistant/components/sinch/*
homeassistant/components/slide/*
homeassistant/components/sma/__init__.py
@@ -943,6 +949,7 @@ omit =
homeassistant/components/snmp/*
homeassistant/components/sochain/sensor.py
homeassistant/components/solaredge/__init__.py
homeassistant/components/solaredge/coordinator.py
homeassistant/components/solaredge/sensor.py
homeassistant/components/solaredge_local/sensor.py
homeassistant/components/solarlog/*
@@ -970,6 +977,7 @@ omit =
homeassistant/components/squeezebox/__init__.py
homeassistant/components/squeezebox/browse_media.py
homeassistant/components/squeezebox/media_player.py
homeassistant/components/ssdp/util.py
homeassistant/components/starline/*
homeassistant/components/starlingbank/sensor.py
homeassistant/components/steam_online/sensor.py
@@ -985,6 +993,7 @@ omit =
homeassistant/components/swiss_public_transport/sensor.py
homeassistant/components/swisscom/device_tracker.py
homeassistant/components/switchbot/switch.py
homeassistant/components/switcher_kis/sensor.py
homeassistant/components/switcher_kis/switch.py
homeassistant/components/switchmate/switch.py
homeassistant/components/syncthing/__init__.py
@@ -1206,6 +1215,7 @@ omit =
homeassistant/components/xmpp/notify.py
homeassistant/components/xs1/*
homeassistant/components/yale_smart_alarm/alarm_control_panel.py
homeassistant/components/yamaha_musiccast/__init__.py
homeassistant/components/yamaha_musiccast/media_player.py
homeassistant/components/yandex_transport/*
homeassistant/components/yeelightsunflower/light.py

View File

@@ -102,20 +102,20 @@ jobs:
version="$(python setup.py -V)"
- name: Login to DockerHub
uses: docker/login-action@v1.9.0
uses: docker/login-action@v1.10.0
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Login to GitHub Container Registry
uses: docker/login-action@v1.9.0
uses: docker/login-action@v1.10.0
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build base image
uses: home-assistant/builder@2021.05.0
uses: home-assistant/builder@2021.06.2
with:
args: |
$BUILD_ARGS \
@@ -154,20 +154,20 @@ jobs:
uses: actions/checkout@v2.3.4
- name: Login to DockerHub
uses: docker/login-action@v1.9.0
uses: docker/login-action@v1.10.0
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Login to GitHub Container Registry
uses: docker/login-action@v1.9.0
uses: docker/login-action@v1.10.0
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build base image
uses: home-assistant/builder@2021.05.0
uses: home-assistant/builder@2021.06.2
with:
args: |
$BUILD_ARGS \
@@ -217,13 +217,13 @@ jobs:
uses: actions/checkout@v2.3.4
- name: Login to DockerHub
uses: docker/login-action@v1.9.0
uses: docker/login-action@v1.10.0
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Login to GitHub Container Registry
uses: docker/login-action@v1.9.0
uses: docker/login-action@v1.10.0
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
@@ -307,5 +307,9 @@ jobs:
create_manifest "${docker_reg}" "latest" "${{ needs.init.outputs.version }}"
create_manifest "${docker_reg}" "beta" "${{ needs.init.outputs.version }}"
create_manifest "${docker_reg}" "rc" "${{ needs.init.outputs.version }}"
# Create series version tag (e.g. 2021.6)
v="${{ needs.init.outputs.version }}"
create_manifest "${docker_reg}" "${v%.*}" "${{ needs.init.outputs.version }}"
fi
done

View File

@@ -10,7 +10,7 @@ on:
pull_request: ~
env:
CACHE_VERSION: 1
CACHE_VERSION: 2
DEFAULT_PYTHON: 3.8
PRE_COMMIT_CACHE: ~/.cache/pre-commit
SQLALCHEMY_WARN_20: 1
@@ -41,7 +41,7 @@ jobs:
hashFiles('homeassistant/package_constraints.txt') }}"
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: >-
@@ -65,7 +65,7 @@ jobs:
hashFiles('.pre-commit-config.yaml') }}"
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: >-
@@ -92,7 +92,7 @@ jobs:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
@@ -104,7 +104,7 @@ jobs:
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: ${{ runner.os }}-${{ needs.prepare-base.outputs.pre-commit-key }}
@@ -132,7 +132,7 @@ jobs:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
@@ -144,7 +144,7 @@ jobs:
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: ${{ runner.os }}-${{ needs.prepare-base.outputs.pre-commit-key }}
@@ -172,7 +172,7 @@ jobs:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
@@ -184,7 +184,7 @@ jobs:
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: ${{ runner.os }}-${{ needs.prepare-base.outputs.pre-commit-key }}
@@ -234,7 +234,7 @@ jobs:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
@@ -246,7 +246,7 @@ jobs:
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: ${{ runner.os }}-${{ needs.prepare-base.outputs.pre-commit-key }}
@@ -277,7 +277,7 @@ jobs:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
@@ -289,7 +289,7 @@ jobs:
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: ${{ runner.os }}-${{ needs.prepare-base.outputs.pre-commit-key }}
@@ -320,7 +320,7 @@ jobs:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
@@ -332,7 +332,7 @@ jobs:
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: ${{ runner.os }}-${{ needs.prepare-base.outputs.pre-commit-key }}
@@ -360,7 +360,7 @@ jobs:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
@@ -372,7 +372,7 @@ jobs:
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: ${{ runner.os }}-${{ needs.prepare-base.outputs.pre-commit-key }}
@@ -403,7 +403,7 @@ jobs:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
@@ -415,7 +415,7 @@ jobs:
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: ${{ runner.os }}-${{ needs.prepare-base.outputs.pre-commit-key }}
@@ -454,7 +454,7 @@ jobs:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
@@ -466,7 +466,7 @@ jobs:
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: ${{ env.PRE_COMMIT_CACHE }}
key: ${{ runner.os }}-${{ needs.prepare-base.outputs.pre-commit-key }}
@@ -496,7 +496,7 @@ jobs:
uses: actions/checkout@v2.3.4
- name: Restore full Python ${{ matrix.python-version }} virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ matrix.python-version }}-${{
@@ -525,7 +525,7 @@ jobs:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore base Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
@@ -561,7 +561,7 @@ jobs:
hashFiles('homeassistant/package_constraints.txt') }}"
- name: Restore full Python ${{ matrix.python-version }} virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: >-
@@ -598,7 +598,7 @@ jobs:
uses: actions/checkout@v2.3.4
- name: Restore full Python ${{ matrix.python-version }} virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ matrix.python-version }}-${{
@@ -629,7 +629,7 @@ jobs:
uses: actions/checkout@v2.3.4
- name: Restore full Python ${{ matrix.python-version }} virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ matrix.python-version }}-${{
@@ -663,7 +663,7 @@ jobs:
uses: actions/checkout@v2.3.4
- name: Restore full Python ${{ matrix.python-version }} virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ matrix.python-version }}-${{
@@ -700,7 +700,7 @@ jobs:
-p no:sugar \
tests
- name: Upload coverage artifact
uses: actions/upload-artifact@v2.2.3
uses: actions/upload-artifact@v2.2.4
with:
name: coverage-${{ matrix.python-version }}-group${{ matrix.group }}
path: .coverage
@@ -721,7 +721,7 @@ jobs:
uses: actions/checkout@v2.3.4
- name: Restore full Python ${{ matrix.python-version }} virtual environment
id: cache-venv
uses: actions/cache@v2.1.5
uses: actions/cache@v2.1.6
with:
path: venv
key: ${{ runner.os }}-${{ matrix.python-version }}-${{
@@ -740,4 +740,4 @@ jobs:
coverage report --fail-under=94
coverage xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1.5.0
uses: codecov/codecov-action@v1.5.2

View File

@@ -45,13 +45,13 @@ jobs:
) > .env_file
- name: Upload env_file
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v2.2.4
with:
name: env_file
path: ./.env_file
- name: Upload requirements_diff
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v2.2.4
with:
name: requirements_diff
path: ./requirements_diff.txt
@@ -65,7 +65,6 @@ jobs:
matrix:
arch: ${{ fromJson(needs.init.outputs.architectures) }}
tag:
- "3.8-alpine3.12"
- "3.9-alpine3.13"
steps:
- name: Checkout the repository
@@ -82,7 +81,7 @@ jobs:
name: requirements_diff
- name: Build wheels
uses: home-assistant/wheels@2021.05.4
uses: home-assistant/wheels@2021.06.0
with:
tag: ${{ matrix.tag }}
arch: ${{ matrix.arch }}
@@ -106,7 +105,6 @@ jobs:
matrix:
arch: ${{ fromJson(needs.init.outputs.architectures) }}
tag:
- "3.8-alpine3.12"
- "3.9-alpine3.13"
steps:
- name: Checkout the repository
@@ -152,7 +150,7 @@ jobs:
done
- name: Build wheels
uses: home-assistant/wheels@2021.05.4
uses: home-assistant/wheels@2021.06.0
with:
tag: ${{ matrix.tag }}
arch: ${{ matrix.arch }}

View File

@@ -5,7 +5,7 @@ repos:
- id: pyupgrade
args: [--py38-plus]
- repo: https://github.com/psf/black
rev: 21.5b1
rev: 21.6b0
hooks:
- id: black
args:

View File

@@ -12,6 +12,7 @@ homeassistant.components.airly.*
homeassistant.components.aladdin_connect.*
homeassistant.components.alarm_control_panel.*
homeassistant.components.amazon_polly.*
homeassistant.components.ambee.*
homeassistant.components.ampio.*
homeassistant.components.automation.*
homeassistant.components.binary_sensor.*
@@ -24,15 +25,19 @@ homeassistant.components.canary.*
homeassistant.components.cover.*
homeassistant.components.device_automation.*
homeassistant.components.device_tracker.*
homeassistant.components.dnsip.*
homeassistant.components.dsmr.*
homeassistant.components.dunehd.*
homeassistant.components.elgato.*
homeassistant.components.fitbit.*
homeassistant.components.forecast_solar.*
homeassistant.components.fritzbox.*
homeassistant.components.frontend.*
homeassistant.components.geo_location.*
homeassistant.components.gios.*
homeassistant.components.group.*
homeassistant.components.history.*
homeassistant.components.homeassistant.triggers.event
homeassistant.components.http.*
homeassistant.components.huawei_lte.*
homeassistant.components.hyperion.*
@@ -41,24 +46,31 @@ homeassistant.components.integration.*
homeassistant.components.knx.*
homeassistant.components.kraken.*
homeassistant.components.light.*
homeassistant.components.local_ip.*
homeassistant.components.lock.*
homeassistant.components.mailbox.*
homeassistant.components.media_player.*
homeassistant.components.mysensors.*
homeassistant.components.nam.*
homeassistant.components.network.*
homeassistant.components.no_ip.*
homeassistant.components.notify.*
homeassistant.components.number.*
homeassistant.components.onewire.*
homeassistant.components.persistent_notification.*
homeassistant.components.pi_hole.*
homeassistant.components.proximity.*
homeassistant.components.recorder.purge
homeassistant.components.recorder.repack
homeassistant.components.recorder.statistics
homeassistant.components.remote.*
homeassistant.components.scene.*
homeassistant.components.select.*
homeassistant.components.sensor.*
homeassistant.components.slack.*
homeassistant.components.sonos.media_player
homeassistant.components.ssdp.*
homeassistant.components.stream.*
homeassistant.components.sun.*
homeassistant.components.switch.*
homeassistant.components.synology_dsm.*
@@ -66,10 +78,12 @@ homeassistant.components.systemmonitor.*
homeassistant.components.tcp.*
homeassistant.components.tts.*
homeassistant.components.upcloud.*
homeassistant.components.uptime.*
homeassistant.components.vacuum.*
homeassistant.components.water_heater.*
homeassistant.components.weather.*
homeassistant.components.websocket_api.*
homeassistant.components.zodiac.*
homeassistant.components.zeroconf.*
homeassistant.components.zone.*
homeassistant.components.zwave_js.*

View File

@@ -33,6 +33,7 @@ homeassistant/components/alarmdecoder/* @ajschmidt8
homeassistant/components/alexa/* @home-assistant/cloud @ochlocracy
homeassistant/components/almond/* @gcampax @balloob
homeassistant/components/alpha_vantage/* @fabaff
homeassistant/components/ambee/* @frenck
homeassistant/components/ambiclimate/* @danielhiversen
homeassistant/components/ambient_station/* @bachya
homeassistant/components/analytics/* @home-assistant/core @ludeeus
@@ -71,7 +72,7 @@ homeassistant/components/bmp280/* @belidzs
homeassistant/components/bmw_connected_drive/* @gerard33 @rikroe
homeassistant/components/bond/* @prystupa
homeassistant/components/bosch_shc/* @tschamm
homeassistant/components/braviatv/* @bieniu
homeassistant/components/braviatv/* @bieniu @Drafteed
homeassistant/components/broadlink/* @danielhiversen @felipediel
homeassistant/components/brother/* @bieniu
homeassistant/components/brunt/* @eavanvalkenburg
@@ -87,6 +88,7 @@ homeassistant/components/cisco_webex_teams/* @fbradyirl
homeassistant/components/climacell/* @raman325
homeassistant/components/cloud/* @home-assistant/cloud
homeassistant/components/cloudflare/* @ludeeus @ctalkington
homeassistant/components/coinbase/* @tombrien
homeassistant/components/color_extractor/* @GenericStudent
homeassistant/components/comfoconnect/* @michaelarnauts
homeassistant/components/compensation/* @Petro31
@@ -117,7 +119,7 @@ homeassistant/components/digital_ocean/* @fabaff
homeassistant/components/directv/* @ctalkington
homeassistant/components/discogs/* @thibmaek
homeassistant/components/doorbird/* @oblogic7 @bdraco
homeassistant/components/dsmr/* @Robbie1221
homeassistant/components/dsmr/* @Robbie1221 @frenck
homeassistant/components/dsmr_reader/* @depl0y
homeassistant/components/dunehd/* @bieniu
homeassistant/components/dwd_weather_warnings/* @runningman84 @stephan192 @Hummel95
@@ -146,7 +148,7 @@ homeassistant/components/ephember/* @ttroy50
homeassistant/components/epson/* @pszafer
homeassistant/components/epsonworkforce/* @ThaStealth
homeassistant/components/eq3btsmart/* @rytilahti
homeassistant/components/esphome/* @OttoWinter
homeassistant/components/esphome/* @OttoWinter @jesserockz
homeassistant/components/essent/* @TheLastProject
homeassistant/components/evohome/* @zxdavb
homeassistant/components/ezviz/* @RenierM26 @baqs
@@ -162,10 +164,12 @@ homeassistant/components/flo/* @dmulcahey
homeassistant/components/flock/* @fabaff
homeassistant/components/flume/* @ChrisMandich @bdraco
homeassistant/components/flunearyou/* @bachya
homeassistant/components/forecast_solar/* @klaasnicolaas @frenck
homeassistant/components/forked_daapd/* @uvjustin
homeassistant/components/fortios/* @kimfrellsen
homeassistant/components/foscam/* @skgsergio
homeassistant/components/freebox/* @hacf-fr @Quentame
homeassistant/components/freedompro/* @stefano055415
homeassistant/components/fritz/* @mammuth @AaronDavidSchneider @chemelli74
homeassistant/components/fritzbox/* @mib1185
homeassistant/components/fronius/* @nielstron
@@ -300,6 +304,7 @@ homeassistant/components/minecraft_server/* @elmurato
homeassistant/components/minio/* @tkislan
homeassistant/components/mobile_app/* @robbiet480
homeassistant/components/modbus/* @adamchengtkc @janiversen @vzahradnik
homeassistant/components/modern_forms/* @wonderslug
homeassistant/components/monoprice/* @etsinko @OnFreund
homeassistant/components/moon/* @fabaff
homeassistant/components/motion_blinds/* @starkillerOG
@@ -421,12 +426,12 @@ homeassistant/components/scrape/* @fabaff
homeassistant/components/screenlogic/* @dieselrabbit
homeassistant/components/script/* @home-assistant/core
homeassistant/components/search/* @home-assistant/core
homeassistant/components/select/* @home-assistant/core
homeassistant/components/sense/* @kbickar
homeassistant/components/sensibo/* @andrey-git
homeassistant/components/sentry/* @dcramer @frenck
homeassistant/components/serial/* @fabaff
homeassistant/components/seven_segments/* @fabaff
homeassistant/components/seventeentrack/* @bachya
homeassistant/components/sharkiq/* @ajmarks
homeassistant/components/shell_command/* @home-assistant/core
homeassistant/components/shelly/* @balloob @bieniu @thecode @chemelli74
@@ -477,11 +482,11 @@ homeassistant/components/subaru/* @G-Two
homeassistant/components/suez_water/* @ooii
homeassistant/components/sun/* @Swamp-Ig
homeassistant/components/supla/* @mwegrzynek
homeassistant/components/surepetcare/* @benleb
homeassistant/components/surepetcare/* @benleb @danielhiversen
homeassistant/components/swiss_hydrological_data/* @fabaff
homeassistant/components/swiss_public_transport/* @fabaff
homeassistant/components/switchbot/* @danielhiversen
homeassistant/components/switcher_kis/* @tomerfi
homeassistant/components/switcher_kis/* @tomerfi @thecode
homeassistant/components/switchmate/* @danielhiversen
homeassistant/components/syncthing/* @zhulik
homeassistant/components/syncthru/* @nielstron
@@ -566,7 +571,7 @@ homeassistant/components/xiaomi_miio/* @rytilahti @syssi @starkillerOG
homeassistant/components/xiaomi_tv/* @simse
homeassistant/components/xmpp/* @fabaff @flowolf
homeassistant/components/yale_smart_alarm/* @gjohansson-ST
homeassistant/components/yamaha_musiccast/* @jalmeroth
homeassistant/components/yamaha_musiccast/* @vigonotion @micha91
homeassistant/components/yandex_transport/* @rishatik92 @devbis
homeassistant/components/yeelight/* @rytilahti @zewelor @shenxn
homeassistant/components/yeelightsunflower/* @lindsaymarkward

View File

@@ -2,11 +2,11 @@
"image": "homeassistant/{arch}-homeassistant",
"shadow_repository": "ghcr.io/home-assistant",
"build_from": {
"aarch64": "ghcr.io/home-assistant/aarch64-homeassistant-base:2021.05.0",
"armhf": "ghcr.io/home-assistant/armhf-homeassistant-base:2021.05.0",
"armv7": "ghcr.io/home-assistant/armv7-homeassistant-base:2021.05.0",
"amd64": "ghcr.io/home-assistant/amd64-homeassistant-base:2021.05.0",
"i386": "ghcr.io/home-assistant/i386-homeassistant-base:2021.05.0"
"aarch64": "ghcr.io/home-assistant/aarch64-homeassistant-base:2021.06.2",
"armhf": "ghcr.io/home-assistant/armhf-homeassistant-base:2021.06.2",
"armv7": "ghcr.io/home-assistant/armv7-homeassistant-base:2021.06.2",
"amd64": "ghcr.io/home-assistant/amd64-homeassistant-base:2021.06.2",
"i386": "ghcr.io/home-assistant/i386-homeassistant-base:2021.06.2"
},
"labels": {
"io.hass.type": "core",

View File

@@ -81,6 +81,17 @@ class TrustedNetworksAuthProvider(AuthProvider):
"""Return trusted users per network."""
return cast(Dict[IPNetwork, Any], self.config[CONF_TRUSTED_USERS])
@property
def trusted_proxies(self) -> list[IPNetwork]:
"""Return trusted proxies in the system."""
if not self.hass.http:
return []
return [
ip_network(trusted_proxy)
for trusted_proxy in self.hass.http.trusted_proxies
]
@property
def support_mfa(self) -> bool:
"""Trusted Networks auth provider does not support MFA."""
@@ -178,6 +189,9 @@ class TrustedNetworksAuthProvider(AuthProvider):
):
raise InvalidAuthError("Not in trusted_networks")
if any(ip_addr in trusted_proxy for trusted_proxy in self.trusted_proxies):
raise InvalidAuthError("Can't allow access from a proxy server")
@callback
def async_validate_refresh_token(
self, refresh_token: RefreshToken, remote_ip: str | None = None

View File

@@ -1,10 +1,26 @@
{
"config": {
"abort": {
"reauth_successful": "\u05d4\u05d0\u05d9\u05de\u05d5\u05ea \u05de\u05d7\u05d3\u05e9 \u05d4\u05e6\u05dc\u05d9\u05d7",
"single_instance_allowed": "\u05ea\u05e6\u05d5\u05e8\u05ea\u05d5 \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4. \u05e8\u05e7 \u05ea\u05e6\u05d5\u05e8\u05d4 \u05d0\u05d7\u05ea \u05d0\u05e4\u05e9\u05e8\u05d9\u05ea."
},
"error": {
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4",
"invalid_auth": "\u05d0\u05d9\u05de\u05d5\u05ea \u05dc\u05d0 \u05d7\u05d5\u05e7\u05d9"
},
"step": {
"reauth_confirm": {
"data": {
"password": "\u05e1\u05d9\u05e1\u05de\u05d4",
"username": "\u05d3\u05d5\u05d0\"\u05dc"
}
},
"user": {
"data": {
"username": "\u05e9\u05dd \u05de\u05e9\u05ea\u05de\u05e9"
}
"password": "\u05e1\u05d9\u05e1\u05de\u05d4",
"username": "\u05d3\u05d5\u05d0\"\u05dc"
},
"title": "\u05d9\u05e9 \u05dc\u05de\u05dc\u05d0 \u05d0\u05ea \u05e4\u05e8\u05d8\u05d9 \u05d4\u05db\u05e0\u05d9\u05e1\u05d4 \u05e9\u05dc\u05da \u05dc\u05d0\u05d3\u05d5\u05d1\u05d9"
}
}
}

View File

@@ -16,13 +16,7 @@ from homeassistant.core import HomeAssistant
from homeassistant.helpers.aiohttp_client import async_get_clientsession
from homeassistant.helpers.update_coordinator import DataUpdateCoordinator, UpdateFailed
from .const import (
ATTR_FORECAST,
CONF_FORECAST,
COORDINATOR,
DOMAIN,
UNDO_UPDATE_LISTENER,
)
from .const import ATTR_FORECAST, CONF_FORECAST, DOMAIN
_LOGGER = logging.getLogger(__name__)
@@ -45,12 +39,9 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
)
await coordinator.async_config_entry_first_refresh()
undo_listener = entry.add_update_listener(update_listener)
entry.async_on_unload(entry.add_update_listener(update_listener))
hass.data.setdefault(DOMAIN, {})[entry.entry_id] = {
COORDINATOR: coordinator,
UNDO_UPDATE_LISTENER: undo_listener,
}
hass.data.setdefault(DOMAIN, {})[entry.entry_id] = coordinator
hass.config_entries.async_setup_platforms(entry, PLATFORMS)
@@ -61,8 +52,6 @@ async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Unload a config entry."""
unload_ok = await hass.config_entries.async_unload_platforms(entry, PLATFORMS)
hass.data[DOMAIN][entry.entry_id][UNDO_UPDATE_LISTENER]()
if unload_ok:
hass.data[DOMAIN].pop(entry.entry_id)

View File

@@ -3,6 +3,7 @@ from __future__ import annotations
from typing import Final
from homeassistant.components.sensor import ATTR_STATE_CLASS, STATE_CLASS_MEASUREMENT
from homeassistant.components.weather import (
ATTR_CONDITION_CLEAR_NIGHT,
ATTR_CONDITION_CLOUDY,
@@ -48,12 +49,10 @@ ATTR_LABEL: Final = "label"
ATTR_UNIT_IMPERIAL: Final = "unit_imperial"
ATTR_UNIT_METRIC: Final = "unit_metric"
CONF_FORECAST: Final = "forecast"
COORDINATOR: Final = "coordinator"
DOMAIN: Final = "accuweather"
MANUFACTURER: Final = "AccuWeather, Inc."
MAX_FORECAST_DAYS: Final = 4
NAME: Final = "AccuWeather"
UNDO_UPDATE_LISTENER: Final = "undo_update_listener"
CONDITION_CLASSES: Final[dict[str, list[int]]] = {
ATTR_CONDITION_CLEAR_NIGHT: [33, 34, 37],
@@ -235,6 +234,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: TEMP_CELSIUS,
ATTR_UNIT_IMPERIAL: TEMP_FAHRENHEIT,
ATTR_ENABLED: False,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"Ceiling": {
ATTR_DEVICE_CLASS: None,
@@ -243,6 +243,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: LENGTH_METERS,
ATTR_UNIT_IMPERIAL: LENGTH_FEET,
ATTR_ENABLED: True,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"CloudCover": {
ATTR_DEVICE_CLASS: None,
@@ -251,6 +252,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: PERCENTAGE,
ATTR_UNIT_IMPERIAL: PERCENTAGE,
ATTR_ENABLED: False,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"DewPoint": {
ATTR_DEVICE_CLASS: DEVICE_CLASS_TEMPERATURE,
@@ -259,6 +261,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: TEMP_CELSIUS,
ATTR_UNIT_IMPERIAL: TEMP_FAHRENHEIT,
ATTR_ENABLED: False,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"RealFeelTemperature": {
ATTR_DEVICE_CLASS: DEVICE_CLASS_TEMPERATURE,
@@ -267,6 +270,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: TEMP_CELSIUS,
ATTR_UNIT_IMPERIAL: TEMP_FAHRENHEIT,
ATTR_ENABLED: True,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"RealFeelTemperatureShade": {
ATTR_DEVICE_CLASS: DEVICE_CLASS_TEMPERATURE,
@@ -275,6 +279,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: TEMP_CELSIUS,
ATTR_UNIT_IMPERIAL: TEMP_FAHRENHEIT,
ATTR_ENABLED: False,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"Precipitation": {
ATTR_DEVICE_CLASS: None,
@@ -283,6 +288,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: LENGTH_MILLIMETERS,
ATTR_UNIT_IMPERIAL: LENGTH_INCHES,
ATTR_ENABLED: True,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"PressureTendency": {
ATTR_DEVICE_CLASS: "accuweather__pressure_tendency",
@@ -299,6 +305,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: UV_INDEX,
ATTR_UNIT_IMPERIAL: UV_INDEX,
ATTR_ENABLED: True,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"WetBulbTemperature": {
ATTR_DEVICE_CLASS: DEVICE_CLASS_TEMPERATURE,
@@ -307,6 +314,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: TEMP_CELSIUS,
ATTR_UNIT_IMPERIAL: TEMP_FAHRENHEIT,
ATTR_ENABLED: False,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"WindChillTemperature": {
ATTR_DEVICE_CLASS: DEVICE_CLASS_TEMPERATURE,
@@ -315,6 +323,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: TEMP_CELSIUS,
ATTR_UNIT_IMPERIAL: TEMP_FAHRENHEIT,
ATTR_ENABLED: False,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"Wind": {
ATTR_DEVICE_CLASS: None,
@@ -323,6 +332,7 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: SPEED_KILOMETERS_PER_HOUR,
ATTR_UNIT_IMPERIAL: SPEED_MILES_PER_HOUR,
ATTR_ENABLED: True,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"WindGust": {
ATTR_DEVICE_CLASS: None,
@@ -331,5 +341,6 @@ SENSOR_TYPES: Final[dict[str, SensorDescription]] = {
ATTR_UNIT_METRIC: SPEED_KILOMETERS_PER_HOUR,
ATTR_UNIT_IMPERIAL: SPEED_MILES_PER_HOUR,
ATTR_ENABLED: False,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
}

View File

@@ -4,7 +4,7 @@ from __future__ import annotations
from typing import TypedDict
class SensorDescription(TypedDict):
class SensorDescription(TypedDict, total=False):
"""Sensor description class."""
device_class: str | None
@@ -13,3 +13,4 @@ class SensorDescription(TypedDict):
unit_metric: str | None
unit_imperial: str | None
enabled: bool
state_class: str | None

View File

@@ -3,7 +3,7 @@ from __future__ import annotations
from typing import Any, cast
from homeassistant.components.sensor import SensorEntity
from homeassistant.components.sensor import ATTR_STATE_CLASS, SensorEntity
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import (
ATTR_ATTRIBUTION,
@@ -12,7 +12,7 @@ from homeassistant.const import (
CONF_NAME,
DEVICE_CLASS_TEMPERATURE,
)
from homeassistant.core import HomeAssistant
from homeassistant.core import HomeAssistant, callback
from homeassistant.helpers.entity import DeviceInfo
from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.typing import StateType
@@ -28,7 +28,6 @@ from .const import (
ATTR_UNIT_IMPERIAL,
ATTR_UNIT_METRIC,
ATTRIBUTION,
COORDINATOR,
DOMAIN,
FORECAST_SENSOR_TYPES,
MANUFACTURER,
@@ -46,9 +45,7 @@ async def async_setup_entry(
"""Add AccuWeather entities from a config_entry."""
name: str = entry.data[CONF_NAME]
coordinator: AccuWeatherDataUpdateCoordinator = hass.data[DOMAIN][entry.entry_id][
COORDINATOR
]
coordinator: AccuWeatherDataUpdateCoordinator = hass.data[DOMAIN][entry.entry_id]
sensors: list[AccuWeatherSensor] = []
for sensor in SENSOR_TYPES:
@@ -81,22 +78,18 @@ class AccuWeatherSensor(CoordinatorEntity, SensorEntity):
) -> None:
"""Initialize."""
super().__init__(coordinator)
self._sensor_data = _get_sensor_data(coordinator.data, forecast_day, kind)
if forecast_day is None:
self._description = SENSOR_TYPES[kind]
self._sensor_data: dict[str, Any]
if kind == "Precipitation":
self._sensor_data = coordinator.data["PrecipitationSummary"][kind]
else:
self._sensor_data = coordinator.data[kind]
else:
self._description = FORECAST_SENSOR_TYPES[kind]
self._sensor_data = coordinator.data[ATTR_FORECAST][forecast_day][kind]
self._unit_system = API_METRIC if coordinator.is_metric else API_IMPERIAL
self._name = name
self.kind = kind
self._device_class = None
self._attrs = {ATTR_ATTRIBUTION: ATTRIBUTION}
self.forecast_day = forecast_day
self._attr_state_class = self._description.get(ATTR_STATE_CLASS)
@property
def name(self) -> str:
@@ -182,3 +175,24 @@ class AccuWeatherSensor(CoordinatorEntity, SensorEntity):
def entity_registry_enabled_default(self) -> bool:
"""Return if the entity should be enabled when first added to the entity registry."""
return self._description[ATTR_ENABLED]
@callback
def _handle_coordinator_update(self) -> None:
"""Handle data update."""
self._sensor_data = _get_sensor_data(
self.coordinator.data, self.forecast_day, self.kind
)
self.async_write_ha_state()
def _get_sensor_data(
sensors: dict[str, Any], forecast_day: int | None, kind: str
) -> Any:
"""Get sensor data."""
if forecast_day is not None:
return sensors[ATTR_FORECAST][forecast_day][kind]
if kind == "Precipitation":
return sensors["PrecipitationSummary"][kind]
return sensors[kind]

View File

@@ -8,7 +8,7 @@ from accuweather.const import ENDPOINT
from homeassistant.components import system_health
from homeassistant.core import HomeAssistant, callback
from .const import COORDINATOR, DOMAIN
from .const import DOMAIN
@callback
@@ -21,8 +21,8 @@ def async_register(
async def system_health_info(hass: HomeAssistant) -> dict[str, Any]:
"""Get info for the info page."""
remaining_requests = list(hass.data[DOMAIN].values())[0][
COORDINATOR
remaining_requests = list(hass.data[DOMAIN].values())[
0
].accuweather.requests_remaining
return {

View File

@@ -1,9 +1,19 @@
{
"config": {
"abort": {
"single_instance_allowed": "\u05ea\u05e6\u05d5\u05e8\u05ea\u05d5 \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4. \u05e8\u05e7 \u05ea\u05e6\u05d5\u05e8\u05d4 \u05d0\u05d7\u05ea \u05d0\u05e4\u05e9\u05e8\u05d9\u05ea."
},
"error": {
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4",
"invalid_api_key": "\u05de\u05e4\u05ea\u05d7 API \u05dc\u05d0 \u05d7\u05d5\u05e7\u05d9"
},
"step": {
"user": {
"data": {
"longitude": "\u05e7\u05d5 \u05d0\u05d5\u05e8\u05da"
"api_key": "\u05de\u05e4\u05ea\u05d7 API",
"latitude": "\u05e7\u05d5 \u05e8\u05d5\u05d7\u05d1",
"longitude": "\u05e7\u05d5 \u05d0\u05d5\u05e8\u05da",
"name": "\u05e9\u05dd"
}
}
}

View File

@@ -13,6 +13,7 @@ from homeassistant.components.weather import (
ATTR_FORECAST_TIME,
ATTR_FORECAST_WIND_BEARING,
ATTR_FORECAST_WIND_SPEED,
Forecast,
WeatherEntity,
)
from homeassistant.config_entries import ConfigEntry
@@ -30,7 +31,6 @@ from .const import (
ATTR_FORECAST,
ATTRIBUTION,
CONDITION_CLASSES,
COORDINATOR,
DOMAIN,
MANUFACTURER,
NAME,
@@ -45,9 +45,7 @@ async def async_setup_entry(
"""Add a AccuWeather weather entity from a config_entry."""
name: str = entry.data[CONF_NAME]
coordinator: AccuWeatherDataUpdateCoordinator = hass.data[DOMAIN][entry.entry_id][
COORDINATOR
]
coordinator: AccuWeatherDataUpdateCoordinator = hass.data[DOMAIN][entry.entry_id]
async_add_entities([AccuWeatherEntity(name, coordinator)])
@@ -156,12 +154,12 @@ class AccuWeatherEntity(CoordinatorEntity, WeatherEntity):
return None
@property
def forecast(self) -> list[dict[str, Any]] | None:
def forecast(self) -> list[Forecast] | None:
"""Return the forecast array."""
if not self.coordinator.forecast:
return None
# remap keys from library to keys understood by the weather component
forecast = [
return [
{
ATTR_FORECAST_TIME: utc_from_timestamp(item["EpochDate"]).isoformat(),
ATTR_FORECAST_TEMP: item["TemperatureMax"]["Value"],
@@ -183,7 +181,6 @@ class AccuWeatherEntity(CoordinatorEntity, WeatherEntity):
}
for item in self.coordinator.data[ATTR_FORECAST]
]
return forecast
@staticmethod
def _calc_precipitation(day: dict[str, Any]) -> float:

View File

@@ -0,0 +1,14 @@
{
"config": {
"abort": {
"no_devices_found": "\u05dc\u05d0 \u05e0\u05de\u05e6\u05d0\u05d5 \u05de\u05db\u05e9\u05d9\u05e8\u05d9\u05dd \u05d1\u05e8\u05e9\u05ea"
},
"step": {
"user": {
"data": {
"id": "\u05de\u05d6\u05d4\u05d4 \u05de\u05d0\u05e8\u05d7"
}
}
}
}
}

View File

@@ -1,11 +1,20 @@
{
"config": {
"abort": {
"already_configured": "\u05e9\u05d9\u05e8\u05d5\u05ea \u05d6\u05d4 \u05db\u05d1\u05e8 \u05de\u05d5\u05d2\u05d3\u05e8"
},
"error": {
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4"
},
"step": {
"user": {
"data": {
"host": "Host",
"host": "\u05de\u05d0\u05e8\u05d7",
"password": "\u05e1\u05d9\u05e1\u05de\u05d4",
"port": "\u05e4\u05d5\u05e8\u05d8"
"port": "\u05e4\u05d5\u05e8\u05d8",
"ssl": "\u05e9\u05d9\u05de\u05d5\u05e9 \u05d1\u05d0\u05d9\u05e9\u05d5\u05e8 SSL",
"username": "\u05e9\u05dd \u05de\u05e9\u05ea\u05de\u05e9",
"verify_ssl": "\u05d0\u05d9\u05de\u05d5\u05ea \u05d0\u05d9\u05e9\u05d5\u05e8 SSL"
}
}
}

View File

@@ -33,6 +33,8 @@ async def async_setup_entry(hass, config_entry, async_add_entities):
class AdvantageAirZoneFilter(AdvantageAirEntity, BinarySensorEntity):
"""Advantage Air Filter."""
_attr_device_class = DEVICE_CLASS_PROBLEM
@property
def name(self):
"""Return the name."""
@@ -43,11 +45,6 @@ class AdvantageAirZoneFilter(AdvantageAirEntity, BinarySensorEntity):
"""Return a unique id."""
return f'{self.coordinator.data["system"]["rid"]}-{self.ac_key}-filter'
@property
def device_class(self):
"""Return the device class of the vent."""
return DEVICE_CLASS_PROBLEM
@property
def is_on(self):
"""Return if filter needs cleaning."""
@@ -57,6 +54,8 @@ class AdvantageAirZoneFilter(AdvantageAirEntity, BinarySensorEntity):
class AdvantageAirZoneMotion(AdvantageAirEntity, BinarySensorEntity):
"""Advantage Air Zone Motion."""
_attr_device_class = DEVICE_CLASS_MOTION
@property
def name(self):
"""Return the name."""
@@ -67,11 +66,6 @@ class AdvantageAirZoneMotion(AdvantageAirEntity, BinarySensorEntity):
"""Return a unique id."""
return f'{self.coordinator.data["system"]["rid"]}-{self.ac_key}-{self.zone_key}-motion'
@property
def device_class(self):
"""Return the device class of the vent."""
return DEVICE_CLASS_MOTION
@property
def is_on(self):
"""Return if motion is detect."""
@@ -81,6 +75,8 @@ class AdvantageAirZoneMotion(AdvantageAirEntity, BinarySensorEntity):
class AdvantageAirZoneMyZone(AdvantageAirEntity, BinarySensorEntity):
"""Advantage Air Zone MyZone."""
_attr_entity_registry_enabled_default = False
@property
def name(self):
"""Return the name."""
@@ -95,8 +91,3 @@ class AdvantageAirZoneMyZone(AdvantageAirEntity, BinarySensorEntity):
def is_on(self):
"""Return if this zone is the myZone."""
return self._zone["number"] == self._ac["myZone"]
@property
def entity_registry_enabled_default(self):
"""Return false to disable this entity by default."""
return False

View File

@@ -6,6 +6,7 @@ from homeassistant.components.climate.const import (
FAN_HIGH,
FAN_LOW,
FAN_MEDIUM,
HVAC_MODE_AUTO,
HVAC_MODE_COOL,
HVAC_MODE_DRY,
HVAC_MODE_FAN_ONLY,
@@ -31,9 +32,18 @@ ADVANTAGE_AIR_HVAC_MODES = {
"cool": HVAC_MODE_COOL,
"vent": HVAC_MODE_FAN_ONLY,
"dry": HVAC_MODE_DRY,
"myauto": HVAC_MODE_AUTO,
}
HASS_HVAC_MODES = {v: k for k, v in ADVANTAGE_AIR_HVAC_MODES.items()}
AC_HVAC_MODES = [
HVAC_MODE_OFF,
HVAC_MODE_COOL,
HVAC_MODE_HEAT,
HVAC_MODE_FAN_ONLY,
HVAC_MODE_DRY,
]
ADVANTAGE_AIR_FAN_MODES = {
"auto": FAN_AUTO,
"low": FAN_LOW,
@@ -43,13 +53,6 @@ ADVANTAGE_AIR_FAN_MODES = {
HASS_FAN_MODES = {v: k for k, v in ADVANTAGE_AIR_FAN_MODES.items()}
FAN_SPEEDS = {FAN_LOW: 30, FAN_MEDIUM: 60, FAN_HIGH: 100}
AC_HVAC_MODES = [
HVAC_MODE_OFF,
HVAC_MODE_COOL,
HVAC_MODE_HEAT,
HVAC_MODE_FAN_ONLY,
HVAC_MODE_DRY,
]
ADVANTAGE_AIR_SERVICE_SET_MYZONE = "set_myzone"
ZONE_HVAC_MODES = [HVAC_MODE_OFF, HVAC_MODE_FAN_ONLY]
@@ -130,6 +133,8 @@ class AdvantageAirAC(AdvantageAirClimateEntity):
@property
def hvac_modes(self):
"""Return the supported HVAC modes."""
if self._ac.get("myAutoModeEnabled"):
return AC_HVAC_MODES + [HVAC_MODE_AUTO]
return AC_HVAC_MODES
@property

View File

@@ -44,6 +44,8 @@ async def async_setup_entry(hass, config_entry, async_add_entities):
class AdvantageAirTimeTo(AdvantageAirEntity, SensorEntity):
"""Representation of Advantage Air timer control."""
_attr_unit_of_measurement = ADVANTAGE_AIR_SET_COUNTDOWN_UNIT
def __init__(self, instance, ac_key, action):
"""Initialize the Advantage Air timer control."""
super().__init__(instance, ac_key)
@@ -65,11 +67,6 @@ class AdvantageAirTimeTo(AdvantageAirEntity, SensorEntity):
"""Return the current value."""
return self._ac[self._time_key]
@property
def unit_of_measurement(self):
"""Return the unit of measurement."""
return ADVANTAGE_AIR_SET_COUNTDOWN_UNIT
@property
def icon(self):
"""Return a representative icon of the timer."""
@@ -86,6 +83,8 @@ class AdvantageAirTimeTo(AdvantageAirEntity, SensorEntity):
class AdvantageAirZoneVent(AdvantageAirEntity, SensorEntity):
"""Representation of Advantage Air Zone Vent Sensor."""
_attr_unit_of_measurement = PERCENTAGE
@property
def name(self):
"""Return the name."""
@@ -103,11 +102,6 @@ class AdvantageAirZoneVent(AdvantageAirEntity, SensorEntity):
return self._zone["value"]
return 0
@property
def unit_of_measurement(self):
"""Return the percent sign."""
return PERCENTAGE
@property
def icon(self):
"""Return a representative icon."""
@@ -119,6 +113,8 @@ class AdvantageAirZoneVent(AdvantageAirEntity, SensorEntity):
class AdvantageAirZoneSignal(AdvantageAirEntity, SensorEntity):
"""Representation of Advantage Air Zone wireless signal sensor."""
_attr_unit_of_measurement = PERCENTAGE
@property
def name(self):
"""Return the name."""
@@ -134,11 +130,6 @@ class AdvantageAirZoneSignal(AdvantageAirEntity, SensorEntity):
"""Return the current value of the wireless signal."""
return self._zone["rssi"]
@property
def unit_of_measurement(self):
"""Return the percent sign."""
return PERCENTAGE
@property
def icon(self):
"""Return a representative icon."""

View File

@@ -0,0 +1,20 @@
{
"config": {
"abort": {
"already_configured": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05d4\u05ea\u05e7\u05df \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4"
},
"error": {
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4"
},
"step": {
"user": {
"data": {
"ip_address": "\u05db\u05ea\u05d5\u05d1\u05ea IP",
"port": "\u05e4\u05ea\u05d7\u05d4"
},
"description": "\u05d4\u05ea\u05d7\u05d1\u05e8 \u05dc- API \u05e9\u05dc \u05d4\u05d8\u05d0\u05d1\u05dc\u05d8 \u05e9\u05dc\u05da \u05d4\u05de\u05d5\u05ea\u05e7\u05df \u05e2\u05dc \u05d4\u05e7\u05d9\u05e8.",
"title": "\u05d4\u05ea\u05d7\u05d1\u05e8"
}
}
}
}

View File

@@ -19,13 +19,13 @@ from .weather_update_coordinator import WeatherUpdateCoordinator
_LOGGER = logging.getLogger(__name__)
async def async_setup_entry(hass: HomeAssistant, config_entry: ConfigEntry):
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Set up AEMET OpenData as config entry."""
name = config_entry.data[CONF_NAME]
api_key = config_entry.data[CONF_API_KEY]
latitude = config_entry.data[CONF_LATITUDE]
longitude = config_entry.data[CONF_LONGITUDE]
station_updates = config_entry.options.get(CONF_STATION_UPDATES, True)
name = entry.data[CONF_NAME]
api_key = entry.data[CONF_API_KEY]
latitude = entry.data[CONF_LATITUDE]
longitude = entry.data[CONF_LONGITUDE]
station_updates = entry.options.get(CONF_STATION_UPDATES, True)
aemet = AEMET(api_key)
weather_coordinator = WeatherUpdateCoordinator(
@@ -35,30 +35,28 @@ async def async_setup_entry(hass: HomeAssistant, config_entry: ConfigEntry):
await weather_coordinator.async_config_entry_first_refresh()
hass.data.setdefault(DOMAIN, {})
hass.data[DOMAIN][config_entry.entry_id] = {
hass.data[DOMAIN][entry.entry_id] = {
ENTRY_NAME: name,
ENTRY_WEATHER_COORDINATOR: weather_coordinator,
}
hass.config_entries.async_setup_platforms(config_entry, PLATFORMS)
hass.config_entries.async_setup_platforms(entry, PLATFORMS)
config_entry.async_on_unload(config_entry.add_update_listener(async_update_options))
entry.async_on_unload(entry.add_update_listener(async_update_options))
return True
async def async_update_options(hass: HomeAssistant, config_entry: ConfigEntry) -> None:
async def async_update_options(hass: HomeAssistant, entry: ConfigEntry) -> None:
"""Update options."""
await hass.config_entries.async_reload(config_entry.entry_id)
await hass.config_entries.async_reload(entry.entry_id)
async def async_unload_entry(hass: HomeAssistant, config_entry: ConfigEntry):
async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry):
"""Unload a config entry."""
unload_ok = await hass.config_entries.async_unload_platforms(
config_entry, PLATFORMS
)
unload_ok = await hass.config_entries.async_unload_platforms(entry, PLATFORMS)
if unload_ok:
hass.data[DOMAIN].pop(config_entry.entry_id)
hass.data[DOMAIN].pop(entry.entry_id)
return unload_ok

View File

@@ -18,5 +18,14 @@
"title": "[void]"
}
}
},
"options": {
"step": {
"init": {
"data": {
"station_updates": "Sammeln von Daten von AEMET-Wetterstationen"
}
}
}
}
}

View File

@@ -0,0 +1,19 @@
{
"config": {
"abort": {
"already_configured": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05de\u05d9\u05e7\u05d5\u05dd \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4"
},
"error": {
"invalid_api_key": "\u05de\u05e4\u05ea\u05d7 API \u05dc\u05d0 \u05d7\u05d5\u05e7\u05d9"
},
"step": {
"user": {
"data": {
"api_key": "\u05de\u05e4\u05ea\u05d7 API",
"latitude": "\u05e7\u05d5 \u05e8\u05d5\u05d7\u05d1",
"longitude": "\u05e7\u05d5 \u05d0\u05d5\u05e8\u05da"
}
}
}
}
}

View File

@@ -18,5 +18,14 @@
"title": "AEMET OpenData"
}
}
},
"options": {
"step": {
"init": {
"data": {
"station_updates": "Zbieraj dane ze stacji pogodowych AEMET"
}
}
}
}
}

View File

@@ -3,10 +3,14 @@
"abort": {
"already_configured": "\u05d4\u05de\u05db\u05e9\u05d9\u05e8 \u05db\u05d1\u05e8 \u05de\u05d5\u05d2\u05d3\u05e8"
},
"error": {
"already_in_progress": "\u05d6\u05e8\u05d9\u05de\u05ea \u05d4\u05ea\u05e6\u05d5\u05e8\u05d4 \u05db\u05d1\u05e8 \u05de\u05ea\u05d1\u05e6\u05e2\u05ea",
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4"
},
"step": {
"user": {
"data": {
"host": "Host",
"host": "\u05de\u05d0\u05e8\u05d7",
"port": "\u05e4\u05d5\u05e8\u05d8"
}
}

View File

@@ -11,9 +11,11 @@ from airly import Airly
from airly.exceptions import AirlyError
import async_timeout
from homeassistant.components.air_quality import DOMAIN as AIR_QUALITY_PLATFORM
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import CONF_API_KEY, CONF_LATITUDE, CONF_LONGITUDE
from homeassistant.core import HomeAssistant
from homeassistant.helpers import entity_registry
from homeassistant.helpers.aiohttp_client import async_get_clientsession
from homeassistant.helpers.device_registry import async_get_registry
from homeassistant.helpers.update_coordinator import DataUpdateCoordinator, UpdateFailed
@@ -31,7 +33,7 @@ from .const import (
NO_AIRLY_SENSORS,
)
PLATFORMS = ["air_quality", "sensor"]
PLATFORMS = ["sensor"]
_LOGGER = logging.getLogger(__name__)
@@ -111,6 +113,15 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
hass.config_entries.async_setup_platforms(entry, PLATFORMS)
# Remove air_quality entities from registry if they exist
ent_reg = entity_registry.async_get(hass)
unique_id = f"{coordinator.latitude}-{coordinator.longitude}"
if entity_id := ent_reg.async_get_entity_id(
AIR_QUALITY_PLATFORM, DOMAIN, unique_id
):
_LOGGER.debug("Removing deprecated air_quality entity %s", entity_id)
ent_reg.async_remove(entity_id)
return True

View File

@@ -1,143 +0,0 @@
"""Support for the Airly air_quality service."""
from __future__ import annotations
from typing import Any
from homeassistant.components.air_quality import (
ATTR_AQI,
ATTR_PM_2_5,
ATTR_PM_10,
AirQualityEntity,
)
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import CONF_NAME
from homeassistant.core import HomeAssistant
from homeassistant.helpers.entity import DeviceInfo
from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.update_coordinator import CoordinatorEntity
from . import AirlyDataUpdateCoordinator
from .const import (
ATTR_API_ADVICE,
ATTR_API_CAQI,
ATTR_API_CAQI_DESCRIPTION,
ATTR_API_CAQI_LEVEL,
ATTR_API_PM10,
ATTR_API_PM10_LIMIT,
ATTR_API_PM10_PERCENT,
ATTR_API_PM25,
ATTR_API_PM25_LIMIT,
ATTR_API_PM25_PERCENT,
ATTRIBUTION,
DEFAULT_NAME,
DOMAIN,
LABEL_ADVICE,
MANUFACTURER,
)
LABEL_AQI_DESCRIPTION = f"{ATTR_AQI}_description"
LABEL_AQI_LEVEL = f"{ATTR_AQI}_level"
LABEL_PM_2_5_LIMIT = f"{ATTR_PM_2_5}_limit"
LABEL_PM_2_5_PERCENT = f"{ATTR_PM_2_5}_percent_of_limit"
LABEL_PM_10_LIMIT = f"{ATTR_PM_10}_limit"
LABEL_PM_10_PERCENT = f"{ATTR_PM_10}_percent_of_limit"
PARALLEL_UPDATES = 1
async def async_setup_entry(
hass: HomeAssistant, entry: ConfigEntry, async_add_entities: AddEntitiesCallback
) -> None:
"""Set up Airly air_quality entity based on a config entry."""
name = entry.data[CONF_NAME]
coordinator = hass.data[DOMAIN][entry.entry_id]
async_add_entities([AirlyAirQuality(coordinator, name)], False)
class AirlyAirQuality(CoordinatorEntity, AirQualityEntity):
"""Define an Airly air quality."""
coordinator: AirlyDataUpdateCoordinator
def __init__(self, coordinator: AirlyDataUpdateCoordinator, name: str) -> None:
"""Initialize."""
super().__init__(coordinator)
self._name = name
self._icon = "mdi:blur"
@property
def name(self) -> str:
"""Return the name."""
return self._name
@property
def icon(self) -> str:
"""Return the icon."""
return self._icon
@property
def air_quality_index(self) -> float | None:
"""Return the air quality index."""
return round_state(self.coordinator.data[ATTR_API_CAQI])
@property
def particulate_matter_2_5(self) -> float | None:
"""Return the particulate matter 2.5 level."""
return round_state(self.coordinator.data.get(ATTR_API_PM25))
@property
def particulate_matter_10(self) -> float | None:
"""Return the particulate matter 10 level."""
return round_state(self.coordinator.data.get(ATTR_API_PM10))
@property
def attribution(self) -> str:
"""Return the attribution."""
return ATTRIBUTION
@property
def unique_id(self) -> str:
"""Return a unique_id for this entity."""
return f"{self.coordinator.latitude}-{self.coordinator.longitude}"
@property
def device_info(self) -> DeviceInfo:
"""Return the device info."""
return {
"identifiers": {
(
DOMAIN,
f"{self.coordinator.latitude}-{self.coordinator.longitude}",
)
},
"name": DEFAULT_NAME,
"manufacturer": MANUFACTURER,
"entry_type": "service",
}
@property
def extra_state_attributes(self) -> dict[str, Any]:
"""Return the state attributes."""
attrs = {
LABEL_AQI_DESCRIPTION: self.coordinator.data[ATTR_API_CAQI_DESCRIPTION],
LABEL_ADVICE: self.coordinator.data[ATTR_API_ADVICE],
LABEL_AQI_LEVEL: self.coordinator.data[ATTR_API_CAQI_LEVEL],
}
if ATTR_API_PM25 in self.coordinator.data:
attrs[LABEL_PM_2_5_LIMIT] = self.coordinator.data[ATTR_API_PM25_LIMIT]
attrs[LABEL_PM_2_5_PERCENT] = round(
self.coordinator.data[ATTR_API_PM25_PERCENT]
)
if ATTR_API_PM10 in self.coordinator.data:
attrs[LABEL_PM_10_LIMIT] = self.coordinator.data[ATTR_API_PM10_LIMIT]
attrs[LABEL_PM_10_PERCENT] = round(
self.coordinator.data[ATTR_API_PM10_PERCENT]
)
return attrs
def round_state(state: float | None) -> float | None:
"""Round state."""
return round(state) if state else state

View File

@@ -3,6 +3,7 @@ from __future__ import annotations
from typing import Final
from homeassistant.components.sensor import ATTR_STATE_CLASS, STATE_CLASS_MEASUREMENT
from homeassistant.const import (
ATTR_DEVICE_CLASS,
ATTR_ICON,
@@ -23,16 +24,22 @@ ATTR_API_CAQI_DESCRIPTION: Final = "DESCRIPTION"
ATTR_API_CAQI_LEVEL: Final = "LEVEL"
ATTR_API_HUMIDITY: Final = "HUMIDITY"
ATTR_API_PM10: Final = "PM10"
ATTR_API_PM10_LIMIT: Final = "PM10_LIMIT"
ATTR_API_PM10_PERCENT: Final = "PM10_PERCENT"
ATTR_API_PM1: Final = "PM1"
ATTR_API_PM25: Final = "PM25"
ATTR_API_PM25_LIMIT: Final = "PM25_LIMIT"
ATTR_API_PM25_PERCENT: Final = "PM25_PERCENT"
ATTR_API_PRESSURE: Final = "PRESSURE"
ATTR_API_TEMPERATURE: Final = "TEMPERATURE"
ATTR_ADVICE: Final = "advice"
ATTR_DESCRIPTION: Final = "description"
ATTR_LABEL: Final = "label"
ATTR_LEVEL: Final = "level"
ATTR_LIMIT: Final = "limit"
ATTR_PERCENT: Final = "percent"
ATTR_UNIT: Final = "unit"
ATTR_VALUE: Final = "value"
SUFFIX_PERCENT: Final = "PERCENT"
SUFFIX_LIMIT: Final = "LIMIT"
ATTRIBUTION: Final = "Data provided by Airly"
CONF_USE_NEAREST: Final = "use_nearest"
@@ -45,28 +52,51 @@ MIN_UPDATE_INTERVAL: Final = 5
NO_AIRLY_SENSORS: Final = "There are no Airly sensors in this area yet."
SENSOR_TYPES: dict[str, SensorDescription] = {
ATTR_API_CAQI: {
ATTR_LABEL: ATTR_API_CAQI,
ATTR_UNIT: "CAQI",
ATTR_VALUE: round,
},
ATTR_API_PM1: {
ATTR_DEVICE_CLASS: None,
ATTR_ICON: "mdi:blur",
ATTR_LABEL: ATTR_API_PM1,
ATTR_UNIT: CONCENTRATION_MICROGRAMS_PER_CUBIC_METER,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_VALUE: round,
},
ATTR_API_PM25: {
ATTR_ICON: "mdi:blur",
ATTR_LABEL: "PM2.5",
ATTR_UNIT: CONCENTRATION_MICROGRAMS_PER_CUBIC_METER,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_VALUE: round,
},
ATTR_API_PM10: {
ATTR_ICON: "mdi:blur",
ATTR_LABEL: ATTR_API_PM10,
ATTR_UNIT: CONCENTRATION_MICROGRAMS_PER_CUBIC_METER,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_VALUE: round,
},
ATTR_API_HUMIDITY: {
ATTR_DEVICE_CLASS: DEVICE_CLASS_HUMIDITY,
ATTR_ICON: None,
ATTR_LABEL: ATTR_API_HUMIDITY.capitalize(),
ATTR_UNIT: PERCENTAGE,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_VALUE: lambda value: round(value, 1),
},
ATTR_API_PRESSURE: {
ATTR_DEVICE_CLASS: DEVICE_CLASS_PRESSURE,
ATTR_ICON: None,
ATTR_LABEL: ATTR_API_PRESSURE.capitalize(),
ATTR_UNIT: PRESSURE_HPA,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_VALUE: round,
},
ATTR_API_TEMPERATURE: {
ATTR_DEVICE_CLASS: DEVICE_CLASS_TEMPERATURE,
ATTR_ICON: None,
ATTR_LABEL: ATTR_API_TEMPERATURE.capitalize(),
ATTR_UNIT: TEMP_CELSIUS,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_VALUE: lambda value: round(value, 1),
},
}

View File

@@ -1,13 +1,15 @@
"""Type definitions for Airly integration."""
from __future__ import annotations
from typing import TypedDict
from typing import Callable, TypedDict
class SensorDescription(TypedDict):
class SensorDescription(TypedDict, total=False):
"""Sensor description class."""
device_class: str | None
icon: str | None
label: str
unit: str
state_class: str | None
value: Callable

View File

@@ -3,7 +3,7 @@ from __future__ import annotations
from typing import Any, cast
from homeassistant.components.sensor import SensorEntity
from homeassistant.components.sensor import ATTR_STATE_CLASS, SensorEntity
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import (
ATTR_ATTRIBUTION,
@@ -19,15 +19,27 @@ from homeassistant.helpers.update_coordinator import CoordinatorEntity
from . import AirlyDataUpdateCoordinator
from .const import (
ATTR_API_PM1,
ATTR_API_PRESSURE,
ATTR_ADVICE,
ATTR_API_ADVICE,
ATTR_API_CAQI,
ATTR_API_CAQI_DESCRIPTION,
ATTR_API_CAQI_LEVEL,
ATTR_API_PM10,
ATTR_API_PM25,
ATTR_DESCRIPTION,
ATTR_LABEL,
ATTR_LEVEL,
ATTR_LIMIT,
ATTR_PERCENT,
ATTR_UNIT,
ATTR_VALUE,
ATTRIBUTION,
DEFAULT_NAME,
DOMAIN,
MANUFACTURER,
SENSOR_TYPES,
SUFFIX_LIMIT,
SUFFIX_PERCENT,
)
PARALLEL_UPDATES = 1
@@ -60,46 +72,49 @@ class AirlySensor(CoordinatorEntity, SensorEntity):
) -> None:
"""Initialize."""
super().__init__(coordinator)
self._name = name
self._description = SENSOR_TYPES[kind]
self._description = description = SENSOR_TYPES[kind]
self._attr_device_class = description.get(ATTR_DEVICE_CLASS)
self._attr_icon = description.get(ATTR_ICON)
self._attr_name = f"{name} {description[ATTR_LABEL]}"
self._attr_state_class = description.get(ATTR_STATE_CLASS)
self._attr_unique_id = (
f"{coordinator.latitude}-{coordinator.longitude}-{kind.lower()}"
)
self._attr_unit_of_measurement = description.get(ATTR_UNIT)
self._attrs: dict[str, Any] = {ATTR_ATTRIBUTION: ATTRIBUTION}
self.kind = kind
self._state = None
self._unit_of_measurement = None
self._attrs = {ATTR_ATTRIBUTION: ATTRIBUTION}
@property
def name(self) -> str:
"""Return the name."""
return f"{self._name} {self._description[ATTR_LABEL]}"
@property
def state(self) -> StateType:
"""Return the state."""
self._state = self.coordinator.data[self.kind]
if self.kind in [ATTR_API_PM1, ATTR_API_PRESSURE]:
return round(cast(float, self._state))
return round(cast(float, self._state), 1)
state = self.coordinator.data[self.kind]
return cast(StateType, self._description[ATTR_VALUE](state))
@property
def extra_state_attributes(self) -> dict[str, Any]:
"""Return the state attributes."""
if self.kind == ATTR_API_CAQI:
self._attrs[ATTR_LEVEL] = self.coordinator.data[ATTR_API_CAQI_LEVEL]
self._attrs[ATTR_ADVICE] = self.coordinator.data[ATTR_API_ADVICE]
self._attrs[ATTR_DESCRIPTION] = self.coordinator.data[
ATTR_API_CAQI_DESCRIPTION
]
if self.kind == ATTR_API_PM25:
self._attrs[ATTR_LIMIT] = self.coordinator.data[
f"{ATTR_API_PM25}_{SUFFIX_LIMIT}"
]
self._attrs[ATTR_PERCENT] = round(
self.coordinator.data[f"{ATTR_API_PM25}_{SUFFIX_PERCENT}"]
)
if self.kind == ATTR_API_PM10:
self._attrs[ATTR_LIMIT] = self.coordinator.data[
f"{ATTR_API_PM10}_{SUFFIX_LIMIT}"
]
self._attrs[ATTR_PERCENT] = round(
self.coordinator.data[f"{ATTR_API_PM10}_{SUFFIX_PERCENT}"]
)
return self._attrs
@property
def icon(self) -> str | None:
"""Return the icon."""
return self._description[ATTR_ICON]
@property
def device_class(self) -> str | None:
"""Return the device_class."""
return self._description[ATTR_DEVICE_CLASS]
@property
def unique_id(self) -> str:
"""Return a unique_id for this entity."""
return f"{self.coordinator.latitude}-{self.coordinator.longitude}-{self.kind.lower()}"
@property
def device_info(self) -> DeviceInfo:
"""Return the device info."""
@@ -114,8 +129,3 @@ class AirlySensor(CoordinatorEntity, SensorEntity):
"manufacturer": MANUFACTURER,
"entry_type": "service",
}
@property
def unit_of_measurement(self) -> str | None:
"""Return the unit the value is expressed in."""
return self._description[ATTR_UNIT]

View File

@@ -1,10 +1,20 @@
{
"config": {
"abort": {
"already_configured": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05de\u05d9\u05e7\u05d5\u05dd \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4"
},
"error": {
"invalid_api_key": "\u05de\u05e4\u05ea\u05d7 API \u05dc\u05d0 \u05d7\u05d5\u05e7\u05d9"
},
"step": {
"user": {
"data": {
"longitude": "\u05e7\u05d5 \u05d0\u05d5\u05e8\u05da"
}
"api_key": "\u05de\u05e4\u05ea\u05d7 API",
"latitude": "\u05e7\u05d5 \u05e8\u05d5\u05d7\u05d1",
"longitude": "\u05e7\u05d5 \u05d0\u05d5\u05e8\u05da",
"name": "\u05e9\u05dd"
},
"title": "\u05d0\u05d5\u05d5\u05e8\u05d9\u05e8\u05d9"
}
}
}

View File

@@ -36,7 +36,7 @@ _LOGGER = logging.getLogger(__name__)
PLATFORMS = ["sensor"]
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry):
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Set up AirNow from a config entry."""
api_key = entry.data[CONF_API_KEY]
latitude = entry.data[CONF_LATITUDE]

View File

@@ -14,7 +14,8 @@
"data": {
"api_key": "API-Schl\u00fcssel",
"latitude": "Breitengrad",
"longitude": "L\u00e4ngengrad"
"longitude": "L\u00e4ngengrad",
"radius": "Stationsradius (Meilen; optional)"
},
"description": "Richten Sie die AirNow-Luftqualit\u00e4tsintegration ein. Um den API-Schl\u00fcssel zu generieren, besuchen Sie https://docs.airnowapi.org/account/request/.",
"title": "AirNow"

View File

@@ -0,0 +1,21 @@
{
"config": {
"abort": {
"already_configured": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05d4\u05ea\u05e7\u05df \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4"
},
"error": {
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4",
"invalid_auth": "\u05d0\u05d9\u05de\u05d5\u05ea \u05dc\u05d0 \u05d7\u05d5\u05e7\u05d9",
"unknown": "\u05e9\u05d2\u05d9\u05d0\u05d4 \u05d1\u05dc\u05ea\u05d9 \u05e6\u05e4\u05d5\u05d9\u05d4"
},
"step": {
"user": {
"data": {
"api_key": "\u05de\u05e4\u05ea\u05d7 API",
"latitude": "\u05e7\u05d5 \u05e8\u05d5\u05d7\u05d1",
"longitude": "\u05e7\u05d5 \u05d0\u05d5\u05e8\u05da"
}
}
}
}
}

View File

@@ -337,24 +337,12 @@ class AirVisualEntity(CoordinatorEntity):
"""Initialize."""
super().__init__(coordinator)
self._attrs = {ATTR_ATTRIBUTION: DEFAULT_ATTRIBUTION}
self._icon = None
self._unit = None
@property
def extra_state_attributes(self):
"""Return the device state attributes."""
return self._attrs
@property
def icon(self):
"""Return the icon."""
return self._icon
@property
def unit_of_measurement(self):
"""Return the unit the value is expressed in."""
return self._unit
async def async_added_to_hass(self):
"""Register callbacks."""

View File

@@ -1,6 +1,5 @@
"""Support for AirVisual Node/Pro units."""
from homeassistant.components.air_quality import AirQualityEntity
from homeassistant.const import CONCENTRATION_MICROGRAMS_PER_CUBIC_METER
from homeassistant.core import callback
from . import AirVisualEntity
@@ -34,8 +33,7 @@ class AirVisualNodeProSensor(AirVisualEntity, AirQualityEntity):
"""Initialize."""
super().__init__(airvisual)
self._icon = "mdi:chemical-weapon"
self._unit = CONCENTRATION_MICROGRAMS_PER_CUBIC_METER
self._attr_icon = "mdi:chemical-weapon"
@property
def air_quality_index(self):

View File

@@ -56,57 +56,32 @@ NODE_PRO_SENSORS = [
(SENSOR_KIND_TEMPERATURE, "Temperature", DEVICE_CLASS_TEMPERATURE, TEMP_CELSIUS),
]
POLLUTANT_LABELS = {
"co": "Carbon Monoxide",
"n2": "Nitrogen Dioxide",
"o3": "Ozone",
"p1": "PM10",
"p2": "PM2.5",
"s2": "Sulfur Dioxide",
}
@callback
def async_get_pollutant_label(symbol):
"""Get a pollutant's label based on its symbol."""
if symbol == "co":
return "Carbon Monoxide"
if symbol == "n2":
return "Nitrogen Dioxide"
if symbol == "o3":
return "Ozone"
if symbol == "p1":
return "PM10"
if symbol == "p2":
return "PM2.5"
if symbol == "s2":
return "Sulfur Dioxide"
return symbol
POLLUTANT_LEVELS = {
(0, 50): ("Good", "mdi:emoticon-excited"),
(51, 100): ("Moderate", "mdi:emoticon-happy"),
(101, 150): ("Unhealthy for sensitive groups", "mdi:emoticon-neutral"),
(151, 200): ("Unhealthy", "mdi:emoticon-sad"),
(201, 300): ("Very unhealthy", "mdi:emoticon-dead"),
(301, 1000): ("Hazardous", "mdi:biohazard"),
}
@callback
def async_get_pollutant_level_info(value):
"""Return a verbal pollutant level (and associated icon) for a numeric value."""
if 0 <= value <= 50:
return ("Good", "mdi:emoticon-excited")
if 51 <= value <= 100:
return ("Moderate", "mdi:emoticon-happy")
if 101 <= value <= 150:
return ("Unhealthy for sensitive groups", "mdi:emoticon-neutral")
if 151 <= value <= 200:
return ("Unhealthy", "mdi:emoticon-sad")
if 201 <= value <= 300:
return ("Very Unhealthy", "mdi:emoticon-dead")
return ("Hazardous", "mdi:biohazard")
@callback
def async_get_pollutant_unit(symbol):
"""Get a pollutant's unit based on its symbol."""
if symbol == "co":
return CONCENTRATION_PARTS_PER_MILLION
if symbol == "n2":
return CONCENTRATION_PARTS_PER_BILLION
if symbol == "o3":
return CONCENTRATION_PARTS_PER_BILLION
if symbol == "p1":
return CONCENTRATION_MICROGRAMS_PER_CUBIC_METER
if symbol == "p2":
return CONCENTRATION_MICROGRAMS_PER_CUBIC_METER
if symbol == "s2":
return CONCENTRATION_PARTS_PER_BILLION
return None
POLLUTANT_UNITS = {
"co": CONCENTRATION_PARTS_PER_MILLION,
"n2": CONCENTRATION_PARTS_PER_BILLION,
"o3": CONCENTRATION_PARTS_PER_BILLION,
"p1": CONCENTRATION_MICROGRAMS_PER_CUBIC_METER,
"p2": CONCENTRATION_MICROGRAMS_PER_CUBIC_METER,
"s2": CONCENTRATION_PARTS_PER_BILLION,
}
async def async_setup_entry(hass, config_entry, async_add_entities):
@@ -154,12 +129,13 @@ class AirVisualGeographySensor(AirVisualEntity, SensorEntity):
}
)
self._config_entry = config_entry
self._icon = icon
self._kind = kind
self._locale = locale
self._name = name
self._state = None
self._unit = unit
self._attr_icon = icon
self._attr_unit_of_measurement = unit
@property
def available(self):
@@ -196,16 +172,20 @@ class AirVisualGeographySensor(AirVisualEntity, SensorEntity):
if self._kind == SENSOR_KIND_LEVEL:
aqi = data[f"aqi{self._locale}"]
self._state, self._icon = async_get_pollutant_level_info(aqi)
[(self._state, self._attr_icon)] = [
(name, icon)
for (floor, ceiling), (name, icon) in POLLUTANT_LEVELS.items()
if floor <= aqi <= ceiling
]
elif self._kind == SENSOR_KIND_AQI:
self._state = data[f"aqi{self._locale}"]
elif self._kind == SENSOR_KIND_POLLUTANT:
symbol = data[f"main{self._locale}"]
self._state = async_get_pollutant_label(symbol)
self._state = POLLUTANT_LABELS[symbol]
self._attrs.update(
{
ATTR_POLLUTANT_SYMBOL: symbol,
ATTR_POLLUTANT_UNIT: async_get_pollutant_unit(symbol),
ATTR_POLLUTANT_UNIT: POLLUTANT_UNITS[symbol],
}
)
@@ -244,16 +224,12 @@ class AirVisualNodeProSensor(AirVisualEntity, SensorEntity):
"""Initialize."""
super().__init__(coordinator)
self._device_class = device_class
self._kind = kind
self._name = name
self._state = None
self._unit = unit
@property
def device_class(self):
"""Return the device class."""
return self._device_class
self._attr_device_class = device_class
self._attr_unit_of_measurement = unit
@property
def device_info(self):

View File

@@ -1,12 +1,37 @@
{
"config": {
"abort": {
"reauth_successful": "\u05d4\u05d0\u05d9\u05de\u05d5\u05ea \u05de\u05d7\u05d3\u05e9 \u05d4\u05e6\u05dc\u05d9\u05d7"
},
"error": {
"invalid_api_key": "\u05de\u05e4\u05ea\u05d7 API \u05dc\u05d0 \u05d7\u05d5\u05e7\u05d9 \u05e1\u05d5\u05e4\u05e7"
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4",
"general_error": "\u05e9\u05d2\u05d9\u05d0\u05d4 \u05d1\u05dc\u05ea\u05d9 \u05e6\u05e4\u05d5\u05d9\u05d4",
"invalid_api_key": "\u05de\u05e4\u05ea\u05d7 API \u05dc\u05d0 \u05d7\u05d5\u05e7\u05d9 \u05e1\u05d5\u05e4\u05e7",
"location_not_found": "\u05d4\u05de\u05d9\u05e7\u05d5\u05dd \u05dc\u05d0 \u05e0\u05de\u05e6\u05d0"
},
"step": {
"geography_by_coords": {
"data": {
"api_key": "\u05de\u05e4\u05ea\u05d7 API",
"latitude": "\u05e7\u05d5 \u05e8\u05d5\u05d7\u05d1",
"longitude": "\u05e7\u05d5 \u05d0\u05d5\u05e8\u05da"
}
},
"geography_by_name": {
"data": {
"api_key": "\u05de\u05e4\u05ea\u05d7 API"
}
},
"node_pro": {
"data": {
"ip_address": "\u05de\u05d0\u05e8\u05d7",
"password": "\u05e1\u05d9\u05e1\u05de\u05d4"
},
"description": "\u05e2\u05e7\u05d5\u05d1 \u05d0\u05d7\u05e8 \u05d9\u05d7\u05d9\u05d3\u05ea AirVisual \u05d0\u05d9\u05e9\u05d9\u05ea. \u05e0\u05d9\u05ea\u05df \u05dc\u05d0\u05d7\u05d6\u05e8 \u05d0\u05ea \u05d4\u05e1\u05d9\u05e1\u05de\u05d4 \u05de\u05de\u05e9\u05e7 \u05d4\u05de\u05e9\u05ea\u05de\u05e9 \u05e9\u05dc \u05d4\u05d9\u05d7\u05d9\u05d3\u05d4."
},
"reauth_confirm": {
"data": {
"api_key": "\u05de\u05e4\u05ea\u05d7 API"
}
}
}

View File

@@ -1,7 +1,6 @@
"""Component to interface with an alarm control panel."""
from __future__ import annotations
from abc import abstractmethod
from datetime import timedelta
import logging
from typing import Any, Final, final
@@ -113,20 +112,25 @@ async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
class AlarmControlPanelEntity(Entity):
"""An abstract class for alarm control entities."""
_attr_changed_by: str | None = None
_attr_code_arm_required: bool = True
_attr_code_format: str | None = None
_attr_supported_features: int
@property
def code_format(self) -> str | None:
"""Regex for code format or None if no code is required."""
return None
return self._attr_code_format
@property
def changed_by(self) -> str | None:
"""Last change triggered by."""
return None
return self._attr_changed_by
@property
def code_arm_required(self) -> bool:
"""Whether the code is required for arm actions."""
return True
return self._attr_code_arm_required
def alarm_disarm(self, code: str | None = None) -> None:
"""Send disarm command."""
@@ -177,9 +181,9 @@ class AlarmControlPanelEntity(Entity):
await self.hass.async_add_executor_job(self.alarm_arm_custom_bypass, code)
@property
@abstractmethod
def supported_features(self) -> int:
"""Return the list of supported features."""
return self._attr_supported_features
@final
@property

View File

@@ -8,7 +8,6 @@ import voluptuous as vol
from homeassistant.const import (
ATTR_CODE,
ATTR_ENTITY_ID,
ATTR_SUPPORTED_FEATURES,
CONF_CODE,
CONF_DEVICE_ID,
CONF_DOMAIN,
@@ -23,6 +22,7 @@ from homeassistant.const import (
from homeassistant.core import Context, HomeAssistant
from homeassistant.helpers import entity_registry
import homeassistant.helpers.config_validation as cv
from homeassistant.helpers.entity import get_supported_features
from homeassistant.helpers.typing import ConfigType
from . import ATTR_CODE_ARM_REQUIRED, DOMAIN
@@ -62,59 +62,24 @@ async def async_get_actions(
if entry.domain != DOMAIN:
continue
state = hass.states.get(entry.entity_id)
supported_features = get_supported_features(hass, entry.entity_id)
# We need a state or else we can't populate the HVAC and preset modes.
if state is None:
continue
supported_features = state.attributes[ATTR_SUPPORTED_FEATURES]
base_action = {
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
}
# Add actions for each entity that belongs to this integration
if supported_features & SUPPORT_ALARM_ARM_AWAY:
actions.append(
{
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: "arm_away",
}
)
actions.append({**base_action, CONF_TYPE: "arm_away"})
if supported_features & SUPPORT_ALARM_ARM_HOME:
actions.append(
{
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: "arm_home",
}
)
actions.append({**base_action, CONF_TYPE: "arm_home"})
if supported_features & SUPPORT_ALARM_ARM_NIGHT:
actions.append(
{
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: "arm_night",
}
)
actions.append(
{
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: "disarm",
}
)
actions.append({**base_action, CONF_TYPE: "arm_night"})
actions.append({**base_action, CONF_TYPE: "disarm"})
if supported_features & SUPPORT_ALARM_TRIGGER:
actions.append(
{
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: "trigger",
}
)
actions.append({**base_action, CONF_TYPE: "trigger"})
return actions
@@ -147,6 +112,8 @@ async def async_get_action_capabilities(
hass: HomeAssistant, config: ConfigType
) -> dict[str, vol.Schema]:
"""List action capabilities."""
# We need to refer to the state directly because ATTR_CODE_ARM_REQUIRED is not a
# capability attribute
state = hass.states.get(config[CONF_ENTITY_ID])
code_required = state.attributes.get(ATTR_CODE_ARM_REQUIRED) if state else False

View File

@@ -13,7 +13,6 @@ from homeassistant.components.alarm_control_panel.const import (
)
from homeassistant.const import (
ATTR_ENTITY_ID,
ATTR_SUPPORTED_FEATURES,
CONF_CONDITION,
CONF_DEVICE_ID,
CONF_DOMAIN,
@@ -29,6 +28,7 @@ from homeassistant.const import (
from homeassistant.core import HomeAssistant
from homeassistant.helpers import condition, config_validation as cv, entity_registry
from homeassistant.helpers.config_validation import DEVICE_CONDITION_BASE_SCHEMA
from homeassistant.helpers.entity import get_supported_features
from homeassistant.helpers.typing import ConfigType, TemplateVarsType
from . import DOMAIN
@@ -70,70 +70,29 @@ async def async_get_conditions(
if entry.domain != DOMAIN:
continue
state = hass.states.get(entry.entity_id)
# We need a state or else we can't populate the different armed conditions
if state is None:
continue
supported_features = state.attributes[ATTR_SUPPORTED_FEATURES]
supported_features = get_supported_features(hass, entry.entity_id)
# Add conditions for each entity that belongs to this integration
base_condition = {
CONF_CONDITION: "device",
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
}
conditions += [
{
CONF_CONDITION: "device",
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: CONDITION_DISARMED,
},
{
CONF_CONDITION: "device",
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: CONDITION_TRIGGERED,
},
{**base_condition, CONF_TYPE: CONDITION_DISARMED},
{**base_condition, CONF_TYPE: CONDITION_TRIGGERED},
]
if supported_features & SUPPORT_ALARM_ARM_HOME:
conditions.append(
{
CONF_CONDITION: "device",
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: CONDITION_ARMED_HOME,
}
)
conditions.append({**base_condition, CONF_TYPE: CONDITION_ARMED_HOME})
if supported_features & SUPPORT_ALARM_ARM_AWAY:
conditions.append(
{
CONF_CONDITION: "device",
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: CONDITION_ARMED_AWAY,
}
)
conditions.append({**base_condition, CONF_TYPE: CONDITION_ARMED_AWAY})
if supported_features & SUPPORT_ALARM_ARM_NIGHT:
conditions.append(
{
CONF_CONDITION: "device",
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: CONDITION_ARMED_NIGHT,
}
)
conditions.append({**base_condition, CONF_TYPE: CONDITION_ARMED_NIGHT})
if supported_features & SUPPORT_ALARM_ARM_CUSTOM_BYPASS:
conditions.append(
{
CONF_CONDITION: "device",
CONF_DEVICE_ID: device_id,
CONF_DOMAIN: DOMAIN,
CONF_ENTITY_ID: entry.entity_id,
CONF_TYPE: CONDITION_ARMED_CUSTOM_BYPASS,
}
{**base_condition, CONF_TYPE: CONDITION_ARMED_CUSTOM_BYPASS}
)
return conditions

View File

@@ -11,10 +11,9 @@ from homeassistant.components.alarm_control_panel.const import (
SUPPORT_ALARM_ARM_NIGHT,
)
from homeassistant.components.automation import AutomationActionType
from homeassistant.components.device_automation import TRIGGER_BASE_SCHEMA
from homeassistant.components.device_automation import DEVICE_TRIGGER_BASE_SCHEMA
from homeassistant.components.homeassistant.triggers import state as state_trigger
from homeassistant.const import (
ATTR_SUPPORTED_FEATURES,
CONF_DEVICE_ID,
CONF_DOMAIN,
CONF_ENTITY_ID,
@@ -30,6 +29,7 @@ from homeassistant.const import (
)
from homeassistant.core import CALLBACK_TYPE, HomeAssistant
from homeassistant.helpers import config_validation as cv, entity_registry
from homeassistant.helpers.entity import get_supported_features
from homeassistant.helpers.typing import ConfigType
from . import DOMAIN
@@ -41,7 +41,7 @@ TRIGGER_TYPES: Final[set[str]] = BASIC_TRIGGER_TYPES | {
"armed_night",
}
TRIGGER_SCHEMA: Final = TRIGGER_BASE_SCHEMA.extend(
TRIGGER_SCHEMA: Final = DEVICE_TRIGGER_BASE_SCHEMA.extend(
{
vol.Required(CONF_ENTITY_ID): cv.entity_id,
vol.Required(CONF_TYPE): vol.In(TRIGGER_TYPES),
@@ -62,13 +62,7 @@ async def async_get_triggers(
if entry.domain != DOMAIN:
continue
entity_state = hass.states.get(entry.entity_id)
# We need a state or else we can't populate the HVAC and preset modes.
if entity_state is None:
continue
supported_features = entity_state.attributes[ATTR_SUPPORTED_FEATURES]
supported_features = get_supported_features(hass, entry.entity_id)
# Add triggers for each entity that belongs to this integration
base_trigger = {

View File

@@ -16,40 +16,58 @@
"device_path": "Ger\u00e4tepfad",
"host": "Host",
"port": "Port"
}
},
"title": "Verbindungseinstellungen konfigurieren"
},
"user": {
"data": {
"protocol": "Protokoll"
}
},
"title": "W\u00e4hlen Sie das AlarmDecoder-Protokoll"
}
}
},
"options": {
"error": {
"int": "Das Feld unten muss eine ganze Zahl sein.",
"loop_range": "RF Loop muss eine ganze Zahl zwischen 1 und 4 sein.",
"loop_rfid": "RF Loop kann nicht ohne RF Serial verwendet werden.",
"relay_inclusive": "Relaisadresse und Relaiskanal sind abh\u00e4ngig voneinander und m\u00fcssen zusammen aufgenommen werden."
},
"step": {
"arm_settings": {
"data": {
"alt_night_mode": "Alternativer Nachtmodus"
}
"alt_night_mode": "Alternativer Nachtmodus",
"auto_bypass": "Automatischer Bypass bei Scharfschaltung",
"code_arm_required": "Code f\u00fcr Scharfschaltung erforderlich"
},
"title": "AlarmDecoder konfigurieren"
},
"init": {
"data": {
"edit_select": "Bearbeiten"
},
"description": "Was m\u00f6chtest du bearbeiten?"
"description": "Was m\u00f6chtest du bearbeiten?",
"title": "AlarmDecoder konfigurieren"
},
"zone_details": {
"data": {
"zone_loop": "RF Loop",
"zone_name": "Zonenname",
"zone_relayaddr": "Relais-Adresse",
"zone_relaychan": "Relaiskanal",
"zone_rfid": "RF Serial",
"zone_type": "Zonentyp"
}
},
"description": "Geben Sie Details f\u00fcr Zone {zone_number} ein. Um Zone {zone_number} zu l\u00f6schen, lassen Sie Zonenname leer.",
"title": "AlarmDecoder konfigurieren"
},
"zone_select": {
"data": {
"zone_number": "Zonennummer"
},
"description": "Gib die die Zonennummer ein, die du hinzuf\u00fcgen, bearbeiten oder entfernen m\u00f6chtest."
"description": "Gib die die Zonennummer ein, die du hinzuf\u00fcgen, bearbeiten oder entfernen m\u00f6chtest.",
"title": "AlarmDecoder konfigurieren"
}
}
}

View File

@@ -0,0 +1,41 @@
{
"config": {
"abort": {
"already_configured": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05d4\u05ea\u05e7\u05df \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4"
},
"error": {
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4"
},
"step": {
"protocol": {
"data": {
"device_path": "\u05e0\u05ea\u05d9\u05d1 \u05d4\u05ea\u05e7\u05df",
"host": "\u05de\u05d0\u05e8\u05d7",
"port": "\u05e4\u05ea\u05d7\u05d4"
}
},
"user": {
"data": {
"protocol": "\u05e4\u05e8\u05d5\u05d8\u05d5\u05e7\u05d5\u05dc"
}
}
}
},
"options": {
"error": {
"relay_inclusive": "\u05db\u05ea\u05d5\u05d1\u05ea \u05de\u05de\u05e1\u05e8 \u05d5\u05e2\u05e8\u05d5\u05e5 \u05de\u05de\u05e1\u05e8 \u05d4\u05dd \u05ea\u05dc\u05d5\u05d9\u05d9 \u05e7\u05d5\u05d3 \u05d5\u05d9\u05e9 \u05dc\u05db\u05dc\u05d5\u05dc \u05d0\u05d5\u05ea\u05dd \u05d9\u05d7\u05d3."
},
"step": {
"init": {
"data": {
"edit_select": "\u05e2\u05e8\u05d5\u05da"
}
},
"zone_details": {
"data": {
"zone_relaychan": "\u05e2\u05e8\u05d5\u05e5 \u05de\u05de\u05e1\u05e8"
}
}
}
}
}

View File

@@ -1155,8 +1155,6 @@ class AlexaPowerLevelController(AlexaCapability):
if self.entity.domain == fan.DOMAIN:
return self.entity.attributes.get(fan.ATTR_PERCENTAGE) or 0
return None
class AlexaSecurityPanelController(AlexaCapability):
"""Implements Alexa.SecurityPanelController.
@@ -1304,6 +1302,12 @@ class AlexaModeController(AlexaCapability):
if mode in (fan.DIRECTION_FORWARD, fan.DIRECTION_REVERSE, STATE_UNKNOWN):
return f"{fan.ATTR_DIRECTION}.{mode}"
# Fan preset_mode
if self.instance == f"{fan.DOMAIN}.{fan.ATTR_PRESET_MODE}":
mode = self.entity.attributes.get(fan.ATTR_PRESET_MODE, None)
if mode in self.entity.attributes.get(fan.ATTR_PRESET_MODES, None):
return f"{fan.ATTR_PRESET_MODE}.{mode}"
# Cover Position
if self.instance == f"{cover.DOMAIN}.{cover.ATTR_POSITION}":
# Return state instead of position when using ModeController.
@@ -1342,6 +1346,17 @@ class AlexaModeController(AlexaCapability):
)
return self._resource.serialize_capability_resources()
# Fan preset_mode
if self.instance == f"{fan.DOMAIN}.{fan.ATTR_PRESET_MODE}":
self._resource = AlexaModeResource(
[AlexaGlobalCatalog.SETTING_PRESET], False
)
for preset_mode in self.entity.attributes.get(fan.ATTR_PRESET_MODES, []):
self._resource.add_mode(
f"{fan.ATTR_PRESET_MODE}.{preset_mode}", [preset_mode]
)
return self._resource.serialize_capability_resources()
# Cover Position Resources
if self.instance == f"{cover.DOMAIN}.{cover.ATTR_POSITION}":
self._resource = AlexaModeResource(

View File

@@ -535,6 +535,7 @@ class FanCapabilities(AlexaEntity):
if supported & fan.SUPPORT_SET_SPEED:
yield AlexaPercentageController(self.entity)
yield AlexaPowerLevelController(self.entity)
# The use of legacy speeds is deprecated in the schema, support will be removed after a quarter (2021.7)
yield AlexaRangeController(
self.entity, instance=f"{fan.DOMAIN}.{fan.ATTR_SPEED}"
)
@@ -542,6 +543,10 @@ class FanCapabilities(AlexaEntity):
yield AlexaToggleController(
self.entity, instance=f"{fan.DOMAIN}.{fan.ATTR_OSCILLATING}"
)
if supported & fan.SUPPORT_PRESET_MODE:
yield AlexaModeController(
self.entity, instance=f"{fan.DOMAIN}.{fan.ATTR_PRESET_MODE}"
)
if supported & fan.SUPPORT_DIRECTION:
yield AlexaModeController(
self.entity, instance=f"{fan.DOMAIN}.{fan.ATTR_DIRECTION}"

View File

@@ -62,7 +62,6 @@ from .errors import (
AlexaInvalidDirectiveError,
AlexaInvalidValueError,
AlexaSecurityPanelAuthorizationRequired,
AlexaSecurityPanelUnauthorizedError,
AlexaTempRangeError,
AlexaUnsupportedThermostatModeError,
AlexaVideoActionNotPermittedForContentError,
@@ -927,11 +926,9 @@ async def async_api_disarm(hass, config, directive, context):
if payload["authorization"]["type"] == "FOUR_DIGIT_PIN":
data["code"] = value
if not await hass.services.async_call(
await hass.services.async_call(
entity.domain, SERVICE_ALARM_DISARM, data, blocking=True, context=context
):
msg = "Invalid Code"
raise AlexaSecurityPanelUnauthorizedError(msg)
)
response.add_context_property(
{
@@ -961,6 +958,16 @@ async def async_api_set_mode(hass, config, directive, context):
service = fan.SERVICE_SET_DIRECTION
data[fan.ATTR_DIRECTION] = direction
# Fan preset_mode
elif instance == f"{fan.DOMAIN}.{fan.ATTR_PRESET_MODE}":
preset_mode = mode.split(".")[1]
if preset_mode in entity.attributes.get(fan.ATTR_PRESET_MODES):
service = fan.SERVICE_SET_PRESET_MODE
data[fan.ATTR_PRESET_MODE] = preset_mode
else:
msg = f"Entity '{entity.entity_id}' does not support Preset '{preset_mode}'"
raise AlexaInvalidValueError(msg)
# Cover Position
elif instance == f"{cover.DOMAIN}.{cover.ATTR_POSITION}":
position = mode.split(".")[1]

View File

@@ -11,9 +11,9 @@ import async_timeout
from pyalmond import AbstractAlmondWebAuth, AlmondLocalAuth, WebAlmondAPI
import voluptuous as vol
from homeassistant import config_entries
from homeassistant.auth.const import GROUP_ID_ADMIN
from homeassistant.components import conversation
from homeassistant.config_entries import SOURCE_IMPORT, ConfigEntry
from homeassistant.const import (
CONF_CLIENT_ID,
CONF_CLIENT_SECRET,
@@ -94,14 +94,14 @@ async def async_setup(hass, config):
hass.async_create_task(
hass.config_entries.flow.async_init(
DOMAIN,
context={"source": config_entries.SOURCE_IMPORT},
context={"source": SOURCE_IMPORT},
data={"type": TYPE_LOCAL, "host": conf[CONF_HOST]},
)
)
return True
async def async_setup_entry(hass: HomeAssistant, entry: config_entries.ConfigEntry):
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Set up Almond config entry."""
websession = aiohttp_client.async_get_clientsession(hass)
@@ -150,7 +150,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: config_entries.ConfigEnt
async def _configure_almond_for_ha(
hass: HomeAssistant, entry: config_entries.ConfigEntry, api: WebAlmondAPI
hass: HomeAssistant, entry: ConfigEntry, api: WebAlmondAPI
):
"""Configure Almond to connect to HA."""
try:
@@ -248,7 +248,7 @@ class AlmondAgent(conversation.AbstractConversationAgent):
"""Almond conversation agent."""
def __init__(
self, hass: HomeAssistant, api: WebAlmondAPI, entry: config_entries.ConfigEntry
self, hass: HomeAssistant, api: WebAlmondAPI, entry: ConfigEntry
) -> None:
"""Initialize the agent."""
self.hass = hass

View File

@@ -0,0 +1,15 @@
{
"config": {
"abort": {
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4",
"missing_configuration": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05e8\u05db\u05d9\u05d1 \u05dc\u05d0 \u05e0\u05e7\u05d1\u05e2\u05d4. \u05e0\u05d0 \u05e2\u05e7\u05d5\u05d1 \u05d0\u05d7\u05e8 \u05d4\u05ea\u05d9\u05e2\u05d5\u05d3.",
"no_url_available": "\u05d0\u05d9\u05df \u05db\u05ea\u05d5\u05d1\u05ea \u05d0\u05ea\u05e8 \u05d6\u05de\u05d9\u05e0\u05d4. \u05e7\u05d1\u05dc\u05ea \u05de\u05d9\u05d3\u05e2 \u05e2\u05dc \u05e9\u05d2\u05d9\u05d0\u05d4 \u05d6\u05d5, [\u05e2\u05d9\u05d9\u05df \u05d1\u05e1\u05e2\u05d9\u05e3 \u05d4\u05e2\u05d6\u05e8\u05d4] ({docs_url})",
"single_instance_allowed": "\u05ea\u05e6\u05d5\u05e8\u05ea\u05d5 \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4. \u05e8\u05e7 \u05ea\u05e6\u05d5\u05e8\u05d4 \u05d0\u05d7\u05ea \u05d0\u05e4\u05e9\u05e8\u05d9\u05ea."
},
"step": {
"pick_implementation": {
"title": "\u05d1\u05d7\u05e8 \u05e9\u05d9\u05d8\u05ea \u05d0\u05d9\u05de\u05d5\u05ea"
}
}
}
}

View File

@@ -0,0 +1,71 @@
"""Support for Ambee."""
from __future__ import annotations
from ambee import AirQuality, Ambee, AmbeeAuthenticationError, Pollen
from homeassistant.components.sensor import DOMAIN as SENSOR_DOMAIN
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import CONF_API_KEY, CONF_LATITUDE, CONF_LONGITUDE
from homeassistant.core import HomeAssistant
from homeassistant.exceptions import ConfigEntryAuthFailed
from homeassistant.helpers.update_coordinator import DataUpdateCoordinator
from .const import DOMAIN, LOGGER, SCAN_INTERVAL, SERVICE_AIR_QUALITY, SERVICE_POLLEN
PLATFORMS = (SENSOR_DOMAIN,)
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Set up Ambee from a config entry."""
hass.data.setdefault(DOMAIN, {}).setdefault(entry.entry_id, {})
client = Ambee(
api_key=entry.data[CONF_API_KEY],
latitude=entry.data[CONF_LATITUDE],
longitude=entry.data[CONF_LONGITUDE],
)
async def update_air_quality() -> AirQuality:
"""Update method for updating Ambee Air Quality data."""
try:
return await client.air_quality()
except AmbeeAuthenticationError as err:
raise ConfigEntryAuthFailed from err
air_quality: DataUpdateCoordinator[AirQuality] = DataUpdateCoordinator(
hass,
LOGGER,
name=f"{DOMAIN}_{SERVICE_AIR_QUALITY}",
update_interval=SCAN_INTERVAL,
update_method=update_air_quality,
)
await air_quality.async_config_entry_first_refresh()
hass.data[DOMAIN][entry.entry_id][SERVICE_AIR_QUALITY] = air_quality
async def update_pollen() -> Pollen:
"""Update method for updating Ambee Pollen data."""
try:
return await client.pollen()
except AmbeeAuthenticationError as err:
raise ConfigEntryAuthFailed from err
pollen: DataUpdateCoordinator[Pollen] = DataUpdateCoordinator(
hass,
LOGGER,
name=f"{DOMAIN}_{SERVICE_POLLEN}",
update_interval=SCAN_INTERVAL,
update_method=update_pollen,
)
await pollen.async_config_entry_first_refresh()
hass.data[DOMAIN][entry.entry_id][SERVICE_POLLEN] = pollen
hass.config_entries.async_setup_platforms(entry, PLATFORMS)
return True
async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Unload Ambee config entry."""
unload_ok = await hass.config_entries.async_unload_platforms(entry, PLATFORMS)
if unload_ok:
del hass.data[DOMAIN][entry.entry_id]
return unload_ok

View File

@@ -0,0 +1,115 @@
"""Config flow to configure the Ambee integration."""
from __future__ import annotations
from typing import Any
from ambee import Ambee, AmbeeAuthenticationError, AmbeeError
import voluptuous as vol
from homeassistant.config_entries import ConfigEntry, ConfigFlow
from homeassistant.const import CONF_API_KEY, CONF_LATITUDE, CONF_LONGITUDE, CONF_NAME
from homeassistant.data_entry_flow import FlowResult
from homeassistant.helpers.aiohttp_client import async_get_clientsession
import homeassistant.helpers.config_validation as cv
from .const import DOMAIN
class AmbeeFlowHandler(ConfigFlow, domain=DOMAIN):
"""Config flow for Ambee."""
VERSION = 1
entry: ConfigEntry | None = None
async def async_step_user(
self, user_input: dict[str, Any] | None = None
) -> FlowResult:
"""Handle a flow initialized by the user."""
errors = {}
if user_input is not None:
session = async_get_clientsession(self.hass)
try:
client = Ambee(
api_key=user_input[CONF_API_KEY],
latitude=user_input[CONF_LATITUDE],
longitude=user_input[CONF_LONGITUDE],
session=session,
)
await client.air_quality()
except AmbeeAuthenticationError:
errors["base"] = "invalid_api_key"
except AmbeeError:
errors["base"] = "cannot_connect"
else:
return self.async_create_entry(
title=user_input[CONF_NAME],
data={
CONF_API_KEY: user_input[CONF_API_KEY],
CONF_LATITUDE: user_input[CONF_LATITUDE],
CONF_LONGITUDE: user_input[CONF_LONGITUDE],
},
)
return self.async_show_form(
step_id="user",
data_schema=vol.Schema(
{
vol.Required(CONF_API_KEY): str,
vol.Optional(
CONF_NAME, default=self.hass.config.location_name
): str,
vol.Optional(
CONF_LATITUDE, default=self.hass.config.latitude
): cv.latitude,
vol.Optional(
CONF_LONGITUDE, default=self.hass.config.longitude
): cv.longitude,
}
),
errors=errors,
)
async def async_step_reauth(self, data: dict[str, Any]) -> FlowResult:
"""Handle initiation of re-authentication with Ambee."""
self.entry = self.hass.config_entries.async_get_entry(self.context["entry_id"])
return await self.async_step_reauth_confirm()
async def async_step_reauth_confirm(
self, user_input: dict[str, Any] | None = None
) -> FlowResult:
"""Handle re-authentication with Ambee."""
errors = {}
if user_input is not None and self.entry:
session = async_get_clientsession(self.hass)
client = Ambee(
api_key=user_input[CONF_API_KEY],
latitude=self.entry.data[CONF_LATITUDE],
longitude=self.entry.data[CONF_LONGITUDE],
session=session,
)
try:
await client.air_quality()
except AmbeeAuthenticationError:
errors["base"] = "invalid_api_key"
except AmbeeError:
errors["base"] = "cannot_connect"
else:
self.hass.config_entries.async_update_entry(
self.entry,
data={
**self.entry.data,
CONF_API_KEY: user_input[CONF_API_KEY],
},
)
self.hass.async_create_task(
self.hass.config_entries.async_reload(self.entry.entry_id)
)
return self.async_abort(reason="reauth_successful")
return self.async_show_form(
step_id="reauth_confirm",
data_schema=vol.Schema({vol.Required(CONF_API_KEY): str}),
errors=errors,
)

View File

@@ -0,0 +1,212 @@
"""Constants for the Ambee integration."""
from __future__ import annotations
from datetime import timedelta
import logging
from typing import Final
from homeassistant.components.sensor import ATTR_STATE_CLASS, STATE_CLASS_MEASUREMENT
from homeassistant.const import (
ATTR_DEVICE_CLASS,
ATTR_ICON,
ATTR_NAME,
ATTR_UNIT_OF_MEASUREMENT,
CONCENTRATION_MICROGRAMS_PER_CUBIC_METER,
CONCENTRATION_PARTS_PER_BILLION,
CONCENTRATION_PARTS_PER_CUBIC_METER,
CONCENTRATION_PARTS_PER_MILLION,
DEVICE_CLASS_CO,
)
from .models import AmbeeSensor
DOMAIN: Final = "ambee"
LOGGER = logging.getLogger(__package__)
SCAN_INTERVAL = timedelta(hours=1)
ATTR_ENABLED_BY_DEFAULT: Final = "enabled_by_default"
ATTR_ENTRY_TYPE: Final = "entry_type"
ENTRY_TYPE_SERVICE: Final = "service"
DEVICE_CLASS_AMBEE_RISK: Final = "ambee__risk"
SERVICE_AIR_QUALITY: Final = "air_quality"
SERVICE_POLLEN: Final = "pollen"
SERVICES: dict[str, str] = {
SERVICE_AIR_QUALITY: "Air Quality",
SERVICE_POLLEN: "Pollen",
}
SENSORS: dict[str, dict[str, AmbeeSensor]] = {
SERVICE_AIR_QUALITY: {
"particulate_matter_2_5": {
ATTR_NAME: "Particulate Matter < 2.5 μm",
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_MICROGRAMS_PER_CUBIC_METER,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"particulate_matter_10": {
ATTR_NAME: "Particulate Matter < 10 μm",
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_MICROGRAMS_PER_CUBIC_METER,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"sulphur_dioxide": {
ATTR_NAME: "Sulphur Dioxide (SO2)",
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_BILLION,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"nitrogen_dioxide": {
ATTR_NAME: "Nitrogen Dioxide (NO2)",
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_BILLION,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"ozone": {
ATTR_NAME: "Ozone",
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_BILLION,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"carbon_monoxide": {
ATTR_NAME: "Carbon Monoxide (CO)",
ATTR_DEVICE_CLASS: DEVICE_CLASS_CO,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_MILLION,
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
"air_quality_index": {
ATTR_NAME: "Air Quality Index (AQI)",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
},
},
SERVICE_POLLEN: {
"grass": {
ATTR_NAME: "Grass Pollen",
ATTR_ICON: "mdi:grass",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
},
"tree": {
ATTR_NAME: "Tree Pollen",
ATTR_ICON: "mdi:tree",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
},
"weed": {
ATTR_NAME: "Weed Pollen",
ATTR_ICON: "mdi:sprout",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
},
"grass_risk": {
ATTR_NAME: "Grass Pollen Risk",
ATTR_ICON: "mdi:grass",
ATTR_DEVICE_CLASS: DEVICE_CLASS_AMBEE_RISK,
},
"tree_risk": {
ATTR_NAME: "Tree Pollen Risk",
ATTR_ICON: "mdi:tree",
ATTR_DEVICE_CLASS: DEVICE_CLASS_AMBEE_RISK,
},
"weed_risk": {
ATTR_NAME: "Weed Pollen Risk",
ATTR_ICON: "mdi:sprout",
ATTR_DEVICE_CLASS: DEVICE_CLASS_AMBEE_RISK,
},
"grass_poaceae": {
ATTR_NAME: "Poaceae Grass Pollen",
ATTR_ICON: "mdi:grass",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"tree_alder": {
ATTR_NAME: "Alder Tree Pollen",
ATTR_ICON: "mdi:tree",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"tree_birch": {
ATTR_NAME: "Birch Tree Pollen",
ATTR_ICON: "mdi:tree",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"tree_cypress": {
ATTR_NAME: "Cypress Tree Pollen",
ATTR_ICON: "mdi:tree",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"tree_elm": {
ATTR_NAME: "Elm Tree Pollen",
ATTR_ICON: "mdi:tree",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"tree_hazel": {
ATTR_NAME: "Hazel Tree Pollen",
ATTR_ICON: "mdi:tree",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"tree_oak": {
ATTR_NAME: "Oak Tree Pollen",
ATTR_ICON: "mdi:tree",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"tree_pine": {
ATTR_NAME: "Pine Tree Pollen",
ATTR_ICON: "mdi:tree",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"tree_plane": {
ATTR_NAME: "Plane Tree Pollen",
ATTR_ICON: "mdi:tree",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"tree_poplar": {
ATTR_NAME: "Poplar Tree Pollen",
ATTR_ICON: "mdi:tree",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"weed_chenopod": {
ATTR_NAME: "Chenopod Weed Pollen",
ATTR_ICON: "mdi:sprout",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"weed_mugwort": {
ATTR_NAME: "Mugwort Weed Pollen",
ATTR_ICON: "mdi:sprout",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"weed_nettle": {
ATTR_NAME: "Nettle Weed Pollen",
ATTR_ICON: "mdi:sprout",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
"weed_ragweed": {
ATTR_NAME: "Ragweed Weed Pollen",
ATTR_ICON: "mdi:sprout",
ATTR_STATE_CLASS: STATE_CLASS_MEASUREMENT,
ATTR_UNIT_OF_MEASUREMENT: CONCENTRATION_PARTS_PER_CUBIC_METER,
ATTR_ENABLED_BY_DEFAULT: False,
},
},
}

View File

@@ -0,0 +1,10 @@
{
"domain": "ambee",
"name": "Ambee",
"config_flow": true,
"documentation": "https://www.home-assistant.io/integrations/ambee",
"requirements": ["ambee==0.3.0"],
"codeowners": ["@frenck"],
"quality_scale": "platinum",
"iot_class": "cloud_polling"
}

View File

@@ -0,0 +1,15 @@
"""Models helper class for the Ambee integration."""
from __future__ import annotations
from typing import TypedDict
class AmbeeSensor(TypedDict, total=False):
"""Represent an Ambee Sensor."""
device_class: str
enabled_by_default: bool
icon: str
name: str
state_class: str
unit_of_measurement: str

View File

@@ -0,0 +1,99 @@
"""Support for Ambee sensors."""
from __future__ import annotations
from homeassistant.components.sensor import (
ATTR_STATE_CLASS,
DOMAIN as SENSOR_DOMAIN,
SensorEntity,
)
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import (
ATTR_DEVICE_CLASS,
ATTR_ICON,
ATTR_IDENTIFIERS,
ATTR_MANUFACTURER,
ATTR_NAME,
ATTR_UNIT_OF_MEASUREMENT,
)
from homeassistant.core import HomeAssistant
from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.typing import StateType
from homeassistant.helpers.update_coordinator import (
CoordinatorEntity,
DataUpdateCoordinator,
)
from .const import (
ATTR_ENABLED_BY_DEFAULT,
ATTR_ENTRY_TYPE,
DOMAIN,
ENTRY_TYPE_SERVICE,
SENSORS,
SERVICES,
)
from .models import AmbeeSensor
async def async_setup_entry(
hass: HomeAssistant,
entry: ConfigEntry,
async_add_entities: AddEntitiesCallback,
) -> None:
"""Set up Ambee sensors based on a config entry."""
async_add_entities(
AmbeeSensorEntity(
coordinator=hass.data[DOMAIN][entry.entry_id][service_key],
entry_id=entry.entry_id,
sensor_key=sensor_key,
sensor=sensor,
service_key=service_key,
service=SERVICES[service_key],
)
for service_key, service_sensors in SENSORS.items()
for sensor_key, sensor in service_sensors.items()
)
class AmbeeSensorEntity(CoordinatorEntity, SensorEntity):
"""Defines an Ambee sensor."""
def __init__(
self,
*,
coordinator: DataUpdateCoordinator,
entry_id: str,
sensor_key: str,
sensor: AmbeeSensor,
service_key: str,
service: str,
) -> None:
"""Initialize Ambee sensor."""
super().__init__(coordinator=coordinator)
self._sensor_key = sensor_key
self._service_key = service_key
self.entity_id = f"{SENSOR_DOMAIN}.{service_key}_{sensor_key}"
self._attr_device_class = sensor.get(ATTR_DEVICE_CLASS)
self._attr_entity_registry_enabled_default = sensor.get(
ATTR_ENABLED_BY_DEFAULT, True
)
self._attr_icon = sensor.get(ATTR_ICON)
self._attr_name = sensor.get(ATTR_NAME)
self._attr_state_class = sensor.get(ATTR_STATE_CLASS)
self._attr_unique_id = f"{entry_id}_{service_key}_{sensor_key}"
self._attr_unit_of_measurement = sensor.get(ATTR_UNIT_OF_MEASUREMENT)
self._attr_device_info = {
ATTR_IDENTIFIERS: {(DOMAIN, f"{entry_id}_{service_key}")},
ATTR_NAME: service,
ATTR_MANUFACTURER: "Ambee",
ATTR_ENTRY_TYPE: ENTRY_TYPE_SERVICE,
}
@property
def state(self) -> StateType:
"""Return the state of the sensor."""
value = getattr(self.coordinator.data, self._sensor_key)
if isinstance(value, str):
return value.lower()
return value # type: ignore[no-any-return]

View File

@@ -0,0 +1,28 @@
{
"config": {
"step": {
"user": {
"description": "Set up Ambee to integrate with Home Assistant.",
"data": {
"api_key": "[%key:common::config_flow::data::api_key%]",
"latitude": "[%key:common::config_flow::data::latitude%]",
"longitude": "[%key:common::config_flow::data::longitude%]",
"name": "[%key:common::config_flow::data::name%]"
}
},
"reauth_confirm": {
"data": {
"description": "Re-authenticate with your Ambee account.",
"api_key": "[%key:common::config_flow::data::api_key%]"
}
}
},
"error": {
"cannot_connect": "[%key:common::config_flow::error::cannot_connect%]",
"invalid_api_key": "[%key:common::config_flow::error::invalid_api_key%]"
},
"abort": {
"reauth_successful": "[%key:common::config_flow::abort::reauth_successful%]"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"low": "Low",
"moderate": "Moderate",
"high": "High",
"very high": "Very High"
}
}
}

View File

@@ -0,0 +1,28 @@
{
"config": {
"abort": {
"reauth_successful": "Re-autenticaci\u00f3 realitzada correctament"
},
"error": {
"cannot_connect": "Ha fallat la connexi\u00f3",
"invalid_api_key": "Clau API inv\u00e0lida"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "Clau API",
"description": "Torna a autenticar-te amb el compte d'Ambee."
}
},
"user": {
"data": {
"api_key": "Clau API",
"latitude": "Latitud",
"longitude": "Longitud",
"name": "Nom"
},
"description": "Configura Ambee per a integrar-lo amb Home Assistant."
}
}
}
}

View File

@@ -0,0 +1,28 @@
{
"config": {
"abort": {
"reauth_successful": "Die erneute Authentifizierung war erfolgreich"
},
"error": {
"cannot_connect": "Verbindung fehlgeschlagen",
"invalid_api_key": "Ung\u00fcltiger API-Schl\u00fcssel"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "API-Schl\u00fcssel",
"description": "Authentifiziere dich erneut mit deinem Ambee-Konto."
}
},
"user": {
"data": {
"api_key": "API-Schl\u00fcssel",
"latitude": "Breitengrad",
"longitude": "L\u00e4ngengrad",
"name": "Name"
},
"description": "Richte Ambee f\u00fcr die Integration mit Home Assistant ein."
}
}
}
}

View File

@@ -0,0 +1,28 @@
{
"config": {
"abort": {
"reauth_successful": "Re-authentication was successful"
},
"error": {
"cannot_connect": "Failed to connect",
"invalid_api_key": "Invalid API key"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "API Key",
"description": "Re-authenticate with your Ambee account."
}
},
"user": {
"data": {
"api_key": "API Key",
"latitude": "Latitude",
"longitude": "Longitude",
"name": "Name"
},
"description": "Set up Ambee to integrate with Home Assistant."
}
}
}
}

View File

@@ -0,0 +1,14 @@
{
"config": {
"step": {
"reauth_confirm": {
"data": {
"description": "Vuelva a autenticarse con su cuenta de Ambee."
}
},
"user": {
"description": "Configure Ambee para que se integre con Home Assistant."
}
}
}
}

View File

@@ -0,0 +1,28 @@
{
"config": {
"abort": {
"reauth_successful": "Taastuvastamine \u00f5nnestus"
},
"error": {
"cannot_connect": "\u00dchendumine nurjus",
"invalid_api_key": "Vale API v\u00f5ti"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "API v\u00f5ti",
"description": "Taastuvasta Ambee konto"
}
},
"user": {
"data": {
"api_key": "API v\u00f5ti",
"latitude": "Laiuskraad",
"longitude": "Pikkuskraad",
"name": "Nimi"
},
"description": "Seadista Ambee sidumine Home Assistantiga."
}
}
}
}

View File

@@ -0,0 +1,26 @@
{
"config": {
"abort": {
"reauth_successful": "\u05d4\u05d0\u05d9\u05de\u05d5\u05ea \u05de\u05d7\u05d3\u05e9 \u05d4\u05e6\u05dc\u05d9\u05d7"
},
"error": {
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4",
"invalid_api_key": "\u05de\u05e4\u05ea\u05d7 API \u05dc\u05d0 \u05d7\u05d5\u05e7\u05d9"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "\u05de\u05e4\u05ea\u05d7 API"
}
},
"user": {
"data": {
"api_key": "\u05de\u05e4\u05ea\u05d7 API",
"latitude": "\u05e7\u05d5 \u05e8\u05d5\u05d7\u05d1",
"longitude": "\u05e7\u05d5 \u05d0\u05d5\u05e8\u05da",
"name": "\u05e9\u05dd"
}
}
}
}
}

View File

@@ -0,0 +1,26 @@
{
"config": {
"abort": {
"reauth_successful": "Az \u00fajrahiteles\u00edt\u00e9s sikeres volt"
},
"error": {
"cannot_connect": "Sikertelen csatlakoz\u00e1s",
"invalid_api_key": "\u00c9rv\u00e9nytelen API kulcs"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "API kulcs"
}
},
"user": {
"data": {
"api_key": "API kulcs",
"latitude": "Sz\u00e9less\u00e9g",
"longitude": "Hossz\u00fas\u00e1g",
"name": "N\u00e9v"
}
}
}
}
}

View File

@@ -0,0 +1,28 @@
{
"config": {
"abort": {
"reauth_successful": "La nuova autenticazione \u00e8 stata eseguita correttamente"
},
"error": {
"cannot_connect": "Impossibile connettersi",
"invalid_api_key": "Chiave API non valida"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "Chiave API",
"description": "Riautenticati con il tuo account Ambee."
}
},
"user": {
"data": {
"api_key": "Chiave API",
"latitude": "Latitudine",
"longitude": "Logitudine",
"name": "Nome"
},
"description": "Configura Ambee per l'integrazione con Home Assistant."
}
}
}
}

View File

@@ -0,0 +1,28 @@
{
"config": {
"abort": {
"reauth_successful": "Herauthenticatie was succesvol"
},
"error": {
"cannot_connect": "Kan geen verbinding maken",
"invalid_api_key": "Ongeldige API-sleutel"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "API-sleutel",
"description": "Verifieer opnieuw met uw Ambee-account."
}
},
"user": {
"data": {
"api_key": "API-sleutel",
"latitude": "Breedtegraad",
"longitude": "Lengtegraad",
"name": "Naam"
},
"description": "Stel Ambee in om te integreren met Home Assistant."
}
}
}
}

View File

@@ -0,0 +1,28 @@
{
"config": {
"abort": {
"reauth_successful": "Godkjenning p\u00e5 nytt var vellykket"
},
"error": {
"cannot_connect": "Tilkobling mislyktes",
"invalid_api_key": "Ugyldig API-n\u00f8kkel"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "API-n\u00f8kkel",
"description": "Autentiser p\u00e5 nytt med Ambee-kontoen din."
}
},
"user": {
"data": {
"api_key": "API-n\u00f8kkel",
"latitude": "Breddegrad",
"longitude": "Lengdegrad",
"name": "Navn"
},
"description": "Sett opp Ambee for \u00e5 integrere med Home Assistant."
}
}
}
}

View File

@@ -0,0 +1,28 @@
{
"config": {
"abort": {
"reauth_successful": "Ponowne uwierzytelnienie powiod\u0142o si\u0119"
},
"error": {
"cannot_connect": "Nie mo\u017cna nawi\u0105za\u0107 po\u0142\u0105czenia",
"invalid_api_key": "Nieprawid\u0142owy klucz API"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "Klucz API",
"description": "Ponownie uwierzytelnij za pomoc\u0105 konta Ambee."
}
},
"user": {
"data": {
"api_key": "Klucz API",
"latitude": "Szeroko\u015b\u0107 geograficzna",
"longitude": "D\u0142ugo\u015b\u0107 geograficzna",
"name": "Nazwa"
},
"description": "Skonfiguruj Ambee, aby zintegrowa\u0107 go z Home Assistantem."
}
}
}
}

View File

@@ -0,0 +1,28 @@
{
"config": {
"abort": {
"reauth_successful": "\u041f\u043e\u0432\u0442\u043e\u0440\u043d\u0430\u044f \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0430 \u0443\u0441\u043f\u0435\u0448\u043d\u043e."
},
"error": {
"cannot_connect": "\u041d\u0435 \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f.",
"invalid_api_key": "\u041d\u0435\u0432\u0435\u0440\u043d\u044b\u0439 \u043a\u043b\u044e\u0447 API."
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "\u041a\u043b\u044e\u0447 API",
"description": "\u0422\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u0430\u044f \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f \u0443\u0447\u0435\u0442\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438 Ambee."
}
},
"user": {
"data": {
"api_key": "\u041a\u043b\u044e\u0447 API",
"latitude": "\u0428\u0438\u0440\u043e\u0442\u0430",
"longitude": "\u0414\u043e\u043b\u0433\u043e\u0442\u0430",
"name": "\u041d\u0430\u0437\u0432\u0430\u043d\u0438\u0435"
},
"description": "\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u0442\u0435 Home Assistant \u0434\u043b\u044f \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u0438 \u0441 Ambee."
}
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "Alt",
"low": "Baix",
"moderate": "Moderat",
"very high": "Molt alt"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "Hoch",
"low": "Niedrig",
"moderate": "M\u00e4\u00dfig",
"very high": "Sehr hoch"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "High",
"low": "Low",
"moderate": "Moderate",
"very high": "Very High"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "Alto",
"low": "Bajo",
"moderate": "Moderado",
"very high": "Muy alto"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "K\u00f5rge",
"low": "Madal",
"moderate": "M\u00f5\u00f5dukas",
"very high": "V\u00e4ga k\u00f5rge"
}
}
}

View File

@@ -0,0 +1,9 @@
{
"state": {
"ambee__risk": {
"high": "Magas",
"low": "Alacsony",
"very high": "Nagyon magas"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "Alto",
"low": "Basso",
"moderate": "Moderato",
"very high": "Molto alto"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "Hoog",
"low": "Laag",
"moderate": "Matig",
"very high": "Zeer hoog"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "H\u00f8y",
"low": "Lav",
"moderate": "Moderat",
"very high": "Veldig h\u00f8y"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "Wysoki",
"low": "Niski",
"moderate": "Umiarkowany",
"very high": "Bardzo wysoki"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "\u0412\u044b\u0441\u043e\u043a\u0438\u0439",
"low": "\u041d\u0438\u0437\u043a\u0438\u0439",
"moderate": "\u0423\u043c\u0435\u0440\u0435\u043d\u043d\u044b\u0439",
"very high": "\u041e\u0447\u0435\u043d\u044c \u0432\u044b\u0441\u043e\u043a\u0438\u0439"
}
}
}

View File

@@ -0,0 +1,10 @@
{
"state": {
"ambee__risk": {
"high": "\u9ad8",
"low": "\u4f4e",
"moderate": "\u4e2d",
"very high": "\u6975\u9ad8"
}
}
}

View File

@@ -0,0 +1,28 @@
{
"config": {
"abort": {
"reauth_successful": "\u91cd\u65b0\u8a8d\u8b49\u6210\u529f"
},
"error": {
"cannot_connect": "\u9023\u7dda\u5931\u6557",
"invalid_api_key": "API \u5bc6\u9470\u7121\u6548"
},
"step": {
"reauth_confirm": {
"data": {
"api_key": "API \u5bc6\u9470",
"description": "\u91cd\u65b0\u8a8d\u8b49 Ambee \u5e33\u865f\u3002"
}
},
"user": {
"data": {
"api_key": "API \u5bc6\u9470",
"latitude": "\u7def\u5ea6",
"longitude": "\u7d93\u5ea6",
"name": "\u540d\u7a31"
},
"description": "\u8a2d\u5b9a Ambee \u4ee5\u6574\u5408\u81f3 Home Assistant\u3002"
}
}
}
}

View File

@@ -0,0 +1,11 @@
{
"config": {
"abort": {
"already_configured": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05d7\u05e9\u05d1\u05d5\u05df \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4",
"missing_configuration": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05e8\u05db\u05d9\u05d1 \u05dc\u05d0 \u05e0\u05e7\u05d1\u05e2\u05d4. \u05e0\u05d0 \u05e2\u05e7\u05d5\u05d1 \u05d0\u05d7\u05e8 \u05d4\u05ea\u05d9\u05e2\u05d5\u05d3."
},
"create_entry": {
"default": "\u05d0\u05d5\u05de\u05ea \u05d1\u05d4\u05e6\u05dc\u05d7\u05d4"
}
}
}

View File

@@ -1,6 +1,10 @@
{
"config": {
"abort": {
"already_configured": "\u05e9\u05d9\u05e8\u05d5\u05ea \u05d6\u05d4 \u05db\u05d1\u05e8 \u05de\u05d5\u05d2\u05d3\u05e8"
},
"error": {
"invalid_key": "\u05de\u05e4\u05ea\u05d7 API \u05dc\u05d0 \u05d7\u05d5\u05e7\u05d9",
"no_devices": "\u05dc\u05d0 \u05e0\u05de\u05e6\u05d0\u05d5 \u05d4\u05ea\u05e7\u05df \u05d1\u05d7\u05e9\u05d1\u05d5\u05df"
},
"step": {

View File

@@ -3,8 +3,8 @@
"name": "Android TV",
"documentation": "https://www.home-assistant.io/integrations/androidtv",
"requirements": [
"adb-shell[async]==0.3.1",
"androidtv[async]==0.0.59",
"adb-shell[async]==0.3.4",
"androidtv[async]==0.0.60",
"pure-python-adb[async]==0.3.0.dev0"
],
"codeowners": ["@JeffLIrion"],

View File

@@ -270,7 +270,7 @@ class AppleTVManager:
self.hass.components.persistent_notification.create(
"An irrecoverable connection problem occurred when connecting to "
f"`f{name}`. Please go to the Integrations page and reconfigure it",
f"`{name}`. Please go to the Integrations page and reconfigure it",
title=NOTIFICATION_TITLE,
notification_id=NOTIFICATION_ID,
)

View File

@@ -16,7 +16,7 @@
"no_usable_service": "Es wurde ein Ger\u00e4t gefunden, aber es konnte keine M\u00f6glichkeit gefunden werden, eine Verbindung zu diesem Ger\u00e4t herzustellen. Wenn diese Meldung weiterhin erscheint, versuche, die IP-Adresse anzugeben oder den Apple TV neu zu starten.",
"unknown": "Unerwarteter Fehler"
},
"flow_title": "Apple TV: {name}",
"flow_title": "{name}",
"step": {
"confirm": {
"description": "Es wird der Apple TV mit dem Namen \" {name} \" zu Home Assistant hinzugef\u00fcgt. \n\n ** Um den Vorgang abzuschlie\u00dfen, m\u00fcssen m\u00f6glicherweise mehrere PIN-Codes eingegeben werden. ** \n\n Bitte beachte, dass der Apple TV mit dieser Integration * nicht * ausgeschalten werden kann. Nur der Media Player in Home Assistant wird ausgeschaltet!",

View File

@@ -0,0 +1,29 @@
{
"config": {
"abort": {
"already_configured_device": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05d4\u05ea\u05e7\u05df \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4",
"already_in_progress": "\u05d6\u05e8\u05d9\u05de\u05ea \u05d4\u05ea\u05e6\u05d5\u05e8\u05d4 \u05db\u05d1\u05e8 \u05de\u05ea\u05d1\u05e6\u05e2\u05ea",
"no_devices_found": "\u05dc\u05d0 \u05e0\u05de\u05e6\u05d0\u05d5 \u05de\u05db\u05e9\u05d9\u05e8\u05d9\u05dd \u05d1\u05e8\u05e9\u05ea",
"unknown": "\u05e9\u05d2\u05d9\u05d0\u05d4 \u05d1\u05dc\u05ea\u05d9 \u05e6\u05e4\u05d5\u05d9\u05d4"
},
"error": {
"already_configured": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05d4\u05ea\u05e7\u05df \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4",
"invalid_auth": "\u05d0\u05d9\u05de\u05d5\u05ea \u05dc\u05d0 \u05d7\u05d5\u05e7\u05d9",
"no_devices_found": "\u05dc\u05d0 \u05e0\u05de\u05e6\u05d0\u05d5 \u05de\u05db\u05e9\u05d9\u05e8\u05d9\u05dd \u05d1\u05e8\u05e9\u05ea",
"unknown": "\u05e9\u05d2\u05d9\u05d0\u05d4 \u05d1\u05dc\u05ea\u05d9 \u05e6\u05e4\u05d5\u05d9\u05d4"
},
"flow_title": "{name}",
"step": {
"pair_with_pin": {
"data": {
"pin": "\u05e7\u05d5\u05d3 PIN"
}
},
"user": {
"data": {
"device_input": "\u05d4\u05ea\u05e7\u05df"
}
}
}
}
}

View File

@@ -12,7 +12,7 @@
"no_devices_found": "Nem tal\u00e1lhat\u00f3 eszk\u00f6z a h\u00e1l\u00f3zaton",
"unknown": "V\u00e1ratlan hiba t\u00f6rt\u00e9nt"
},
"flow_title": "Apple TV: {name}",
"flow_title": "{name}",
"step": {
"confirm": {
"title": "Apple TV sikeresen hozz\u00e1adva"

View File

@@ -7,7 +7,7 @@ from arcam.fmj import ConnectionFailed
from arcam.fmj.client import Client
import async_timeout
from homeassistant import config_entries
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import CONF_HOST, CONF_PORT, EVENT_HOMEASSISTANT_STOP
from homeassistant.core import HomeAssistant
import homeassistant.helpers.config_validation as cv
@@ -51,7 +51,7 @@ async def async_setup(hass: HomeAssistant, config: ConfigType):
return True
async def async_setup_entry(hass: HomeAssistant, entry: config_entries.ConfigEntry):
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Set up config entry."""
entries = hass.data[DOMAIN_DATA_ENTRIES]
tasks = hass.data[DOMAIN_DATA_TASKS]

View File

@@ -4,7 +4,7 @@ from __future__ import annotations
import voluptuous as vol
from homeassistant.components.automation import AutomationActionType
from homeassistant.components.device_automation import TRIGGER_BASE_SCHEMA
from homeassistant.components.device_automation import DEVICE_TRIGGER_BASE_SCHEMA
from homeassistant.const import (
ATTR_ENTITY_ID,
CONF_DEVICE_ID,
@@ -20,7 +20,7 @@ from homeassistant.helpers.typing import ConfigType
from .const import DOMAIN, EVENT_TURN_ON
TRIGGER_TYPES = {"turn_on"}
TRIGGER_SCHEMA = TRIGGER_BASE_SCHEMA.extend(
TRIGGER_SCHEMA = DEVICE_TRIGGER_BASE_SCHEMA.extend(
{
vol.Required(CONF_ENTITY_ID): cv.entity_id,
vol.Required(CONF_TYPE): vol.In(TRIGGER_TYPES),
@@ -56,7 +56,7 @@ async def async_attach_trigger(
automation_info: dict,
) -> CALLBACK_TYPE:
"""Attach a trigger."""
trigger_id = automation_info.get("trigger_id") if automation_info else None
trigger_data = automation_info.get("trigger_data", {}) if automation_info else {}
job = HassJob(action)
if config[CONF_TYPE] == "turn_on":
@@ -69,9 +69,9 @@ async def async_attach_trigger(
job,
{
"trigger": {
**trigger_data,
**config,
"description": f"{DOMAIN} - {entity_id}",
"id": trigger_id,
}
},
event.context,

View File

@@ -5,7 +5,6 @@
"already_in_progress": "[%key:common::config_flow::abort::already_in_progress%]",
"cannot_connect": "[%key:common::config_flow::error::cannot_connect%]"
},
"error": {},
"flow_title": "{host}",
"step": {
"confirm": {

View File

@@ -5,7 +5,7 @@
"already_in_progress": "Der Konfigurationsablauf wird bereits ausgef\u00fchrt",
"cannot_connect": "Verbindung fehlgeschlagen"
},
"flow_title": "Arcam FMJ auf {host}",
"flow_title": "{host}",
"step": {
"confirm": {
"description": "M\u00f6chtest du Arcam FMJ auf `{host}` zum Home Assistant hinzuf\u00fcgen?"

View File

@@ -0,0 +1,22 @@
{
"config": {
"abort": {
"already_configured": "\u05ea\u05e6\u05d5\u05e8\u05ea \u05d4\u05d4\u05ea\u05e7\u05df \u05db\u05d1\u05e8 \u05e0\u05e7\u05d1\u05e2\u05d4",
"already_in_progress": "\u05d6\u05e8\u05d9\u05de\u05ea \u05d4\u05ea\u05e6\u05d5\u05e8\u05d4 \u05db\u05d1\u05e8 \u05de\u05ea\u05d1\u05e6\u05e2\u05ea",
"cannot_connect": "\u05d4\u05d4\u05ea\u05d7\u05d1\u05e8\u05d5\u05ea \u05e0\u05db\u05e9\u05dc\u05d4"
},
"flow_title": "{host}",
"step": {
"confirm": {
"description": "\u05d4\u05d0\u05dd \u05d1\u05e8\u05e6\u05d5\u05e0\u05da \u05dc\u05d4\u05d5\u05e1\u05d9\u05e3 \u05d0\u05ea Arcam FMJ \u05d1- '{host}' \u05dc-Home Assistant?"
},
"user": {
"data": {
"host": "\u05de\u05d0\u05e8\u05d7",
"port": "\u05e4\u05ea\u05d7\u05d4"
},
"description": "\u05d0\u05e0\u05d0 \u05d4\u05d6\u05df \u05d0\u05ea \u05e9\u05dd \u05d4\u05de\u05d0\u05e8\u05d7 \u05d0\u05d5 \u05d0\u05ea \u05db\u05ea\u05d5\u05d1\u05ea \u05d4-IP \u05e9\u05dc \u05d4\u05d4\u05ea\u05e7\u05df."
}
}
}
}

View File

@@ -5,6 +5,7 @@
"already_in_progress": "A konfigur\u00e1ci\u00f3 m\u00e1r folyamatban van.",
"cannot_connect": "Sikertelen csatlakoz\u00e1s"
},
"flow_title": "{host}",
"step": {
"user": {
"data": {

View File

@@ -5,6 +5,10 @@
"already_in_progress": "Il flusso di configurazione \u00e8 gi\u00e0 in corso",
"cannot_connect": "Impossibile connettersi"
},
"error": {
"one": "Pi\u00f9",
"other": "Altri"
},
"flow_title": "{host}",
"step": {
"confirm": {

View File

@@ -111,7 +111,7 @@ async def async_setup(hass, config):
return True
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry):
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Set up AsusWrt platform."""
# import options from yaml if empty

Some files were not shown because too many files have changed in this diff Show More