Compare commits

...

2033 Commits

Author SHA1 Message Date
Paulus Schoutsen
88e3e73bb4 Merge pull request #32964 from home-assistant/rc
0.107.1
2020-03-18 22:14:25 -07:00
Paulus Schoutsen
3aa1bcbb77 Fix mobile app test 2020-03-18 22:13:49 -07:00
Paulus Schoutsen
f973b35cef Bumped version to 0.107.1 2020-03-18 18:19:33 -07:00
Paulus Schoutsen
4e08aa8b05 Fix zone config (#32963)
* Fix zone config

* Add zone as dependency again to device tracker

* Fix tests
2020-03-18 18:18:57 -07:00
Paulus Schoutsen
8e917ccf73 Add device automation as frontend dependency (#32962) 2020-03-18 18:17:11 -07:00
Bram Kragten
0b62011626 Updated frontend to 20200318.1 (#32957) 2020-03-18 18:17:11 -07:00
Franck Nijhof
d520a02b8c Merge pull request #32932 from home-assistant/rc
0.107.0
2020-03-18 15:35:44 +01:00
SukramJ
1e469b39ad Fix flaky tests for HMIPC (#32806) 2020-03-18 14:44:29 +01:00
Franck Nijhof
c2f615839d Bumped version to 0.107.0 2020-03-18 13:31:02 +01:00
Bram Kragten
657bf33e32 Updated frontend to 20200318.0 (#32931) 2020-03-18 13:27:21 +01:00
Paulus Schoutsen
0ca87007fd Bumped version to 0.107.0b8 2020-03-17 17:56:18 -07:00
Paulus Schoutsen
d0d9d853f2 Fix hassio panel load (#32922)
* Fix loading hassio panel

* Remove blacklist
2020-03-17 17:55:57 -07:00
Hans Oischinger
8348878e7e Introduce safe scan_interval for vicare (#32915) 2020-03-17 17:55:56 -07:00
Paulus Schoutsen
b70be5f2f2 Blacklist auto_backup (#32912)
* Blacklist auto_backup

* Mock with a set
2020-03-17 17:55:55 -07:00
Bram Kragten
fddb565e4c Fix input text reload (#32911)
* Fix input text reload

* FIx schema instead
2020-03-17 17:55:54 -07:00
Rami Mosleh
f3e6820042 Fix setting up options due to config data freeze (#32872) 2020-03-17 17:55:54 -07:00
Paulus Schoutsen
ae98f13181 Bumped version to 0.107.0b7 2020-03-17 10:36:59 -07:00
Paulus Schoutsen
ab38e7d98a Bump cast to 4.2.0 (#32906) 2020-03-17 10:35:39 -07:00
brubaked
9797b09d44 Changed Sensor icons to be more emotionally sensitive (#32904)
The existing sensor icons, while descriptive - dead = dead - are perhaps too matter of fact and don't accurately convey the tragedy. I changed emoticon-dead-outline to emoticon-cry-outline, as I think it better conveys the reality of the situation along with the emotions tied to the statistic.
2020-03-17 10:35:39 -07:00
Quentame
4908d4358c Bump iCloud to 0.9.5 (#32901) 2020-03-17 10:35:38 -07:00
Paulus Schoutsen
67d728fc50 Make zone dependency of device tracker an after dep (#32880)
* Make zone dependency of device tracker an after dep

* Fix test
2020-03-17 10:34:34 -07:00
Jason Lachowsky
912409ed0c Corrected minor misspellings (#32857) 2020-03-17 10:32:01 -07:00
Paolo Tuninetto
ac8c889b0f Add default port to samsung tv (#32820)
* Default port for websocket tv

* Update config entry

* move bridge creation

* fix indent

* remove loop
2020-03-17 10:32:00 -07:00
Quentame
67a721d39b Fix iCloud init while pending (#32750)
* Fix iCloud init while pending

Continue if device is pending while setup
Create devices and fetch 15s if pending, otherwise determine interval to fetch.

* Add retried_fetch guard
2020-03-17 10:32:00 -07:00
Paulus Schoutsen
d196fd136d Bumped version to 0.107.0b6 2020-03-16 14:53:13 -07:00
Bram Kragten
4f78674a4c Updated frontend to 20200316.1 (#32878) 2020-03-16 14:53:05 -07:00
Bram Kragten
a7aca10668 Lovelace: storage key based on id instead of url_path (#32873)
* Fix storage key based on url_path

* Fix test
2020-03-16 14:53:04 -07:00
Paulus Schoutsen
03b1c6ddee Remove group as a dependency from entity integrations (#32870)
* remove group dependency

* Update device sun light trigger

* Add zone dep back to device tracker
2020-03-16 14:53:03 -07:00
David F. Mulcahey
661f1b69f2 Bump ZHA quirks to 0.0.37 (#32867) 2020-03-16 14:53:03 -07:00
Bram Kragten
ccb34083fe Add lovelace reload service for yaml resources (#32865)
* Lovelace add reload service for yaml resources

* Clean up imports

* Comments
2020-03-16 14:53:02 -07:00
Bram Kragten
7f6b3c1130 Bumped version to 0.107.0b5 2020-03-16 13:59:27 +01:00
Bram Kragten
f2c3f76b8e Updated frontend to 20200316.0 (#32866) 2020-03-16 13:49:50 +01:00
Pascal Vizeli
b6a3bcf87f Update pyozw 0.1.9 (#32864) 2020-03-16 13:49:49 +01:00
Tom Harris
65423bb62b Bump insteonplm to 0.16.8 (#32847) 2020-03-16 13:49:48 +01:00
Kit Klein
104665d849 Ignore the ignored konnected config entries (#32845)
* ignore the ignored konnected config entries

* key off data instead of source
2020-03-16 13:49:47 +01:00
Alan Tse
fb1ba86b08 Bump teslajsonpy to 0.5.1 (#32827) 2020-03-16 13:49:47 +01:00
David Bonnes
cee72724b6 Ensure unique_ids for all evohome thermostats (#32604)
* initial commit

* small tweak
2020-03-16 13:49:46 +01:00
Paulus Schoutsen
a3d74651a8 Bumped version to 0.107.0b4 2020-03-15 11:56:56 -07:00
Paulus Schoutsen
d88275d6d2 Make sure panel_custom won't crash on invalid data (#32835)
* Make sure panel_custom won't crash on invalid data

* Add a test
2020-03-15 11:52:54 -07:00
SukramJ
42998f898b Add SF transition to HmIP-BSL and remove obsolete code in HMIPC (#32833) 2020-03-15 11:52:53 -07:00
Daniel Høyer Iversen
875671cc2b Add Netatmo Home Coach as model (#32829) 2020-03-15 11:52:53 -07:00
Bram Kragten
3b84b6e6d5 Require a hyphen in lovelace dashboard url (#32816)
* Require a hyphen in lovelace dashboard url

* Keep storage dashboards working

* register during startup again

* Update homeassistant/components/lovelace/dashboard.py

Co-Authored-By: Paulus Schoutsen <balloob@gmail.com>

* Comments

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2020-03-15 11:52:52 -07:00
Chris Talkington
3b1fb2f416 Remove extra logging from directv init. (#32809) 2020-03-15 11:52:51 -07:00
Chris Talkington
226a0bcaad Fix directv location of unknown error string (#32807)
* Update strings.json

* Update en.json
2020-03-15 11:52:50 -07:00
Greg
57dd45318d Bump eagle_reader API version to v0.2.4 (#32789) 2020-03-15 11:52:50 -07:00
Franck Nijhof
e666485ea9 Fix brightness_pct in light device turn_on action (#32787) 2020-03-15 11:52:49 -07:00
Aidan Timson
b5c8b5b91f Fix onvif error with non ptz cameras (#32783) 2020-03-15 11:52:48 -07:00
David F. Mulcahey
706607f1d2 Fix handling of attribute reports in ZHA sensors and binary sensors (#32776)
* Update sensor tests.

* Update light tests.

* Update binary_sensor tests.

* Update cover tests.

* Update device tracker tests.

* Update fan tests.

* Update lock tests.

* Update switch tests.

* add sensor attr to sensors

* add sensor attr to binary sensors

* cleanup extra var

Co-authored-by: Alexei Chetroi <alexei.chetroi@outlook.com>
2020-03-15 11:52:47 -07:00
Steven Looman
0788bbd629 Add log message on timeout and update less often for upnp devices (#32740)
* Catch asyncio.TimeoutError, show a proper message instead

* Throttle updates to max once per 30s

* Change code owner

* Fix CODEOWNERS + linting

* Warn on connection timeout
2020-03-15 11:52:46 -07:00
Chris Talkington
1b622925a1 Optimize directv client initialization (#32706)
* Optimize directv client initialization.

* Update config_flow.py

* Update media_player.py

* Update media_player.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update test_media_player.py

* Update __init__.py

* Update media_player.py

* Update test_media_player.py

* Update media_player.py

* Update test_media_player.py

* Update config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update __init__.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_media_player.py

* Update test_media_player.py

* Update __init__.py

* Update __init__.py

* Update __init__.py
2020-03-15 11:52:45 -07:00
Slava
86c4fa0fc5 Add brightness state to emulated hue when devices support only color temp and brightness (#31834) 2020-03-15 11:52:45 -07:00
Jc2k
e365dc398b Fix homekit_controller beta connectivity issues (#32810) 2020-03-14 15:43:09 -04:00
Bram Kragten
dfd29e6d73 Bumped version to 0.107.0b3 2020-03-13 22:23:34 +01:00
Bram Kragten
6780bded7e Updated frontend to 20200313.0 (#32777) 2020-03-13 22:19:22 +01:00
Paulus Schoutsen
56686dd14c Bumped version to 0.107.0b2 2020-03-13 12:16:55 -07:00
Bram Kragten
7268bcd9be Check if panel url used and delay dashboard reg till start (#32771)
* Check if panel url used and delay dashboard reg till start

* move storage_dashboard_changed

* fix tests
2020-03-13 12:16:49 -07:00
J. Nick Koston
4f78e04315 Bump py-august to 0.25.0 (#32769)
Fixes a bug in the conversion to async where code validation failed.
2020-03-13 12:16:49 -07:00
Austin Mroczek
7bdac8ef2e Bump total-connect-client to 0.54.1 #32758) 2020-03-13 12:16:48 -07:00
Paulus Schoutsen
a66f4ca4ec Bumped version to 0.107.0b1 2020-03-12 17:02:38 -07:00
Bram Kragten
3345d85dca Updated frontend to 20200312.0 (#32741) 2020-03-12 17:02:29 -07:00
Raman Gupta
9ad776e55d Set self._current_app to None when vizio device is off (#32725) 2020-03-12 17:02:29 -07:00
escoand
2f2a908573 Fix legacy Samsung TV (#32719)
* Update bridge.py

* Update test_init.py
2020-03-12 17:02:28 -07:00
J. Nick Koston
9f76a8c12d Resolve Home Assistant fails to start when Sense integration i… (#32716)
* Bump sense_energy 0.7.1 which also fixes throwing ConfigEntryNotReady
2020-03-12 17:02:27 -07:00
Raman Gupta
fe6ca522e8 Update Vizio source property to only return current app if i… (#32713)
* only return current app for source if current app is set

* check for None specifically

* make sure current app isn't called for speaker
2020-03-12 17:02:26 -07:00
Paulus Schoutsen
c46d0e4a49 Sonos idle (#32712)
* Sonos idle

* F-string

* Add to properties

* Fixes
2020-03-12 17:02:26 -07:00
Aaron Bach
8db426e5da Broaden exception handling for IQVIA (#32708) 2020-03-12 17:02:25 -07:00
Franck Nijhof
bfacd9a1c3 Remove deprecated hide_if_away from device trackers (#32705) 2020-03-12 17:02:24 -07:00
Barry Williams
943c7ee11a If device has volume disabled, the volume will be None. However in these (#32702)
instances whenever the volume was requested a division calculation was made
resulting in a TypeError. The volume adjustment from `0-100` to `0-1` is now
calculated during the `update()` method.
2020-03-12 17:02:23 -07:00
Franck Nijhof
71155f548f Bumped version to 0.107.0b0 2020-03-11 20:54:27 +01:00
Chris Talkington
180bcad477 Add codeowner for roku. (#32695) 2020-03-11 12:52:27 -07:00
Quentame
01dc81d8fb Fetch iCloud family devices only when wanted (#32644)
* Fetch iCloud family devices only when wanted

* Review: form data_schema as init schema
2020-03-11 20:43:37 +01:00
Chris Talkington
cea5cac6e2 Update directpy==0.7 for directv. (#32694) 2020-03-11 20:33:02 +01:00
Chris Talkington
bb666b9ac6 Add config flow to directv (#32162)
* initial work on config flow.

* more work on config flow.

* work on config flow and add tests. other cleanup.

* cleanup tests.

* fix test.

* isort

* Update .coveragerc

* Update test_init.py

* Update test_init.py

* Update test_init.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* correct upnp serial format.

* improve config flow coverage.

* review tweaks.

* further review tweaks

* simplify dtv data gathering job

* lint

* black

* Update test_init.py

* Update test_init.py

* Simplify exception handling.

* Simplify exception handling.

* Update media_player.py

* Update test_media_player.py

* Update test_media_player.py

* Update test_media_player.py

* Update test_media_player.py

* Update test_media_player.py

* fix failing test.

* restore change made during debug.

* isort.

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-11 12:28:38 -07:00
Bram Kragten
c9a9bd16fe Updated frontend to 20200311.1 (#32691) 2020-03-11 12:18:11 -07:00
chiefdragon
3e8728ad5f Fix issue #23758 - Restore Canary sensors and ensure alarm con… (#32627)
* Fixed missing Canary sensors and Canary alarm control panel that was not updating correctly

* Resolved pylinting warnings in original tests
2020-03-11 11:58:42 -07:00
Paulus Schoutsen
d28d1ff657 Add JSON benchmark (#32690)
* Add JSON benchmark

* Fix logbook benchmarks

* Move logbook import back
2020-03-11 11:50:16 -07:00
jjlawren
44c7743351 Rewrite and add Plex tests (#32633)
* Rewrite and add Plex tests

* Remove unnecessary mocks

* Explicitly import constants for readability
2020-03-11 09:37:02 -07:00
Erik Montnemery
f7ddbc7e1e Remove duplicated config from MQTT tests (#32689) 2020-03-11 09:34:19 -07:00
Florian Werner
5216dc0ae1 Fix rate of change calculation of statistics sensor (#32597)
* Fix rate of change of statistics sensor

* Fix test
2020-03-11 09:33:00 -07:00
Alexei Chetroi
440c837eb6 Allow sw_version update of a device registry entry. (#32630) 2020-03-11 09:31:02 -07:00
Jc2k
ffe8b94d75 Simplfy homekit_controller characteristic writes (#32683) 2020-03-11 09:27:20 -07:00
Penny Wood
c56530a712 Connect to more recent versions of IZone (#32552)
* Update to new version of python-izone

* Improve disconnection handling.

* Update requirements-all

* Lint fix
2020-03-11 09:26:16 -07:00
cgtobi
50c32d57f5 Remove Netatmo binary sensor (#32673)
* Clean up for access scope review

* Remove deleted from coverage omit list
2020-03-11 09:25:19 -07:00
Robert Svensson
015e779d56 UniFi - Client tracker schedules update on disconnect event (#32655) 2020-03-11 09:24:52 -07:00
Franck Nijhof
01d0e70f44 Merge branch 'master' into dev 2020-03-11 17:03:36 +01:00
Bram Kragten
4c4e5f3fa9 Fix demos (#32086)
* Fixes for demos

* Update vacuum.py

* Comment

* Fix tests
2020-03-11 08:16:22 -07:00
David F. Mulcahey
7127492767 Additional ZHA cleanup (#32678)
* fix double device loading in tests

* change imports

* None is default
2020-03-11 13:37:28 +01:00
Jc2k
365578d053 Update homekit_controller to use CharacteristicPermissions constants (#32679) 2020-03-11 12:34:19 +00:00
Jc2k
647d137daa Refactor homekit_controller entity update to work more like update coordinator (#32670)
* Clean up use of get_characteristic_types

* Get rid of get_hk_char_value helper

* Get rid of _update_fn callbacks

* Call async_write_has_state directly as async_state_changed doesnt do anything any more
2020-03-11 07:40:47 -04:00
David F. Mulcahey
4248893007 Clean up custom polling in ZHA device and light (#32653)
* cleanup timer handle when device is removed

* separate unavailable times for mains vs battery

* better name

* remove light refresh handle when removing light

* remove unused parallel updates

* don't steal HA const for different purpose

* don't flood network every hour for lights

* update test to test both intervals

* add test for light refresh interval

* fix tests

* update test

* put parallel updates back for now...

* fix async_schedule_update_ha_state usage

* review comment

* review comment

* update test - review conversation

* review comments

* await count not call count

* flip some state
2020-03-11 07:17:53 -04:00
Bram Kragten
99109d162b Updated frontend to 20200311.0 (#32675) 2020-03-11 12:10:00 +01:00
Diogo Gomes
16336bf902 Add entity_service calibrate_meter to utility_meter (#32658)
* add calibrate service
2020-03-11 09:42:22 +01:00
Chris Talkington
69b19d54e8 Add codeowner for directv. (#32661) 2020-03-11 07:43:44 +01:00
Paul Madden
61acf944c0 Use bomradarloop v0.1.4 (#32660) 2020-03-11 07:27:07 +01:00
jjlawren
836b077bcc Bump python-ecobee-api to 0.2.2 (#32667) 2020-03-11 07:26:50 +01:00
Jc2k
1b5c9e922d Bump aiohomekit for more reconnect fixes (#32657) 2020-03-10 20:38:06 -04:00
J. Nick Koston
048f9e7daa Throw ConfigEntryNotReady when august servers are offline or u… (#32635)
* Throw ConfigEntryNotReady when august servers are offline

* august has tests now and its nearing 100%

* Adjust per review

* define in init
2020-03-10 17:10:00 -07:00
J. Nick Koston
ae147fd9c7 Lock operation sensors for August (#32593)
* adkj

* reduce

* Convert august to async

Async io was added to py-august 0.24

* Fix lint

* Lock operation sensors for august

* Tracking lock operation method allows user presence detection at the lock

* revert lock changes

* fix activity count merge conflict reversion

* Fix revert that come back with the conflict
2020-03-10 17:09:49 -07:00
cgtobi
b9a9a92145 Refactor netatmo webhooks (#32195)
* Start webhook implementation

* Add webhook implementation

* Bump pyatmo 3.2.5

* Fire event after data evaluation

* Setup webhooks after components

* Fix logging

* Wrap non async call

* Wrap non async call

* Add smoke detector and door tag webhook support

* Catch when webhook registration fails

* Log to debug

* Fix persons lookup

* Add dependency

* Remove false requirements

* Fix requirements

* Replace netatmo events by a single one

* Slim down code

* Clean up code

* Address review vomments

* Undo attribute removal

* Bump pyatmo to v3.3.0

* Only create webhook id once and reuse

* Store and reuse cloudhook url

* Wait for hass core to be up and running

* Register webhook once HA is ready

* Delay webhook registration
2020-03-10 17:08:59 -07:00
springstan
ba0aaeeddb Use f-strings in integrations starting with "M" (#32271)
* Use f-strings in integrations starting with "M"

* Format mqtt light init with black

* Fix lint error

* Fix pylint error

* Restore constants

* Update homeassistant/components/mqtt/discovery.py

* Update homeassistant/components/mqtt/discovery.py

* Update homeassistant/components/mqtt/discovery.py

* Update homeassistant/components/mqtt/discovery.py

* Format with Black
2020-03-10 23:34:54 +01:00
Bram Kragten
bbe0f75336 input_datetime guard for unexpected state on restore (#32652)
* input_datetime guard for unexpected state

If state is a time and has_date = true, or the other way around, restore state would error

* Update __init__.py

* Add test
2020-03-10 15:15:11 -07:00
Gerard
765882fc4d Fix bmw connected drive door_lock_state attribute error (#32074)
* Fix for door_lock_state attribute error

* Updates based on review comments

* Remove update_time

* Remove update time in lock

* Remove update time in sensor

* Remove unused variable

* Change return for device_state_attributes
2020-03-10 23:05:35 +01:00
J. Nick Koston
908ae23738 Add griddy integration (#32591)
* Add griddy integration

* Griddy is a wholesale power provider in Texas

* Supports all four load zones in Texas

* Provides real time power price which is useful for automations to handle demand response

* Update homeassistant/components/griddy/sensor.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Update homeassistant/components/griddy/config_flow.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Add ability request updated via entity update service.

* Improve error message about already configured

* Remove DEVICE_CLASS_POWER since we do not have a device class for cost

* remove setdefault that was left from previous refactor

* More detail on data naming

* Bump translation for testing

* git add the config flow tests

* s/PlatformNotReady/ConfigEntryNotReady/

* Review items

* git add the other missing file

* Patch griddypower

* reduce

* adjust target

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-10 23:00:30 +01:00
Aaron Bach
21cff003f8 Add options flow for AirVisual (#32634)
* Add options flow for AirVisual

* Code review

Co-Authored-By: Robert Svensson <Kane610@users.noreply.github.com>

Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>
2020-03-10 14:16:25 -06:00
Paulus Schoutsen
2c1da182e2 Merge pull request #32650 from home-assistant/rc
0.106.6
2020-03-10 13:01:35 -07:00
Paulus Schoutsen
39bdb562d3 Bumped version to 0.106.6 2020-03-10 11:50:54 -07:00
Paulus Schoutsen
1d1f8df509 Upgrade to coronavirus 1.1.0 (#32648) 2020-03-10 11:49:26 -07:00
Maikel Punie
ccb8b6b9c8 Update python-velbus to fix a missing data file (#32580) 2020-03-10 11:49:25 -07:00
Paulus Schoutsen
c0dcd9c674 Send messages conforming new facebook policy (#32516) 2020-03-10 11:49:24 -07:00
Quentame
6062854666 Get pending iCloud devices when available + request again when needs an update (#32400)
* Fetch iCloud devices again if the status is pending

* Remove "No iCloud device found" double check

* fix default api_devices value

* Remove useless unitialisation declarations
2020-03-10 11:49:11 -07:00
Paulus Schoutsen
a3c55b5e96 Upgrade to coronavirus 1.1.0 (#32648) 2020-03-10 11:47:07 -07:00
Paulus Schoutsen
89fc430eec Check against Switch attr not being None (#32647) 2020-03-10 11:28:11 -07:00
Vilppu Vuorinen
b2bb9cf134 Add support for MELCloud Air-to-Water devices (#32078)
* Add support for melcloud Air-to-Water devices

* Add water_heater entity for the water heater component.

* Add individual climate entities for 0-2 supported radiator zones.

* Add sensors for zone room temperatures, outdoor temperature and tank
temperature.

* Update .coveragerc

* Use device_state_attributes

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Apply suggestions from code review

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Complete state_attributes -> device_state_attributes migration

* Move constants to top of file

* Remove async_turn_on/off

* Drop mac from ATW unique_ids

* Add MAC to device_info connections

* Remove redundant ABC inheritance

* Update homeassistant/components/melcloud/water_heater.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-03-10 11:00:07 -07:00
Robert Svensson
16d7f84be7 UniFi - Fix block functionality (#32625)
* Fix block functionality

* Remove unrelated changes

* Bump dependency to v15

* Run requirement script
2020-03-10 18:27:25 +01:00
Paulus Schoutsen
0a25e86fab Use callback instead of async methods in Timer (#32638) 2020-03-10 08:01:52 -04:00
Jc2k
c11a462f51 Clean up homekit_controller entity setup (#32628) 2020-03-10 12:06:44 +01:00
Paolo Tuninetto
a8758ed3a1 Add support for newer SamsungTV models (#31537)
* Added support for newer SamsungTV models

* Fixed legacy port

* store token in HA config directory

* Change token name

* rebasing and exception handling

* implement update

* fix error creating mediaplayer

* Debug logging

* Increase timeout

* Restore update timeout

* Store token_file path in config_entry

* Introduction of samsung bridge class

* Added bridge class functions

* Code cleanup

* more fixes

* Begin testing

* samsungtvws 1.2.0

* Config flow tests 0.1

* Fixed some mediaplayer tests

* Fixed fixture in media player

* use of constants and turn off

* more media player tests

* samsungtvws 1.3.1 and other fixes

* WS tv update rewritten

* more tests

* test_init

* fixed tests

* removed reset mock

* tests reset mock

* close_remote and tests

* deprecate port config

* deprecate port config 2

* deprecate port config 3

* save token only if needed

* cleanup

* better websocket protocol detection

* config removal
2020-03-10 11:48:09 +01:00
Quentame
2e802c88f8 Add devices check to iCloud config flow (#31950)
* Add devices check to iCloud config flow

* Some test rename

* Bump pyicloud to catch KeyError
2020-03-10 11:42:04 +01:00
Michaël Arnauts
8c52e2c923 Revert "Breakout tado zone code into a single place (#32564)" (#32639)
This reverts commit c2b03332a0.
2020-03-10 09:32:56 +01:00
Paul Enright
ac9c9377c2 Add tests for workday sensor (#31832)
* Workday Fix

* fix pylint errors

* Update binary_sensor.py

* Update test_binary_sensor.py

Added tests to match the document new configuration examples
2020-03-10 08:53:06 +01:00
Robert Chmielowiec
11eee43fc7 Remove facebook broadcast api (#32517)
* Remove facebook broadcast api

* Update notify.py

* Revert API Version change
2020-03-10 08:21:04 +01:00
Georgi Gardev
aed15761de Sonos: Return URI as media_content_id (#32626) 2020-03-10 08:17:07 +01:00
Erik Montnemery
324dfe07b4 Clear discovery topic for MQTT device triggers (#32617) 2020-03-09 21:59:38 -07:00
Thomas Hollstegge
f3c07a5653 Alexa: Add support for starting and cancelling timers (#32616) 2020-03-09 21:59:06 -07:00
Aaron Bach
f4561891ae Ensure AirVisual import config flow checks API key correctness (#32624)
* Add small improvements to AirVisual config flow tests

* Code review comments

* Code review comments
2020-03-09 21:39:42 -06:00
J. Nick Koston
c2b03332a0 Breakout tado zone code into a single place (#32564)
* Breakout tado zone code into a single place

* Resolve various incorrect states and add tests for known tado zone states

* Fix home and away presets

* Upgrade to PyTado 0.4.0 which improves http performance and fixes setting fan speed.

* Write state instead of calling for an update

* adjust codeowners

* Add tests for michael's tado and fix heatingPower.value

* Guards are much cleaner

* Adjust per review

* Remove hass passing
2020-03-09 17:44:34 -07:00
J. Nick Koston
3a680bf7b7 Add a commit interval setting to recorder (#32596)
* Add a commit interval setting to recorder

* Make the default every 1s instead of immediate

* See attached py-spy flamegraphs for why 1s

* This avoids disk thrashing during event storms

* Make Home Assistant significantly more responsive on busy systems

* remove debug

* Add commit forces for tests that expect commits to be immediate

* Add commit forces for tests that expect commits to be immediate

* make sure _trigger_db_commit is in the right place (all effective "wait_recording_done" calls)

* De-duplicate wait_recording_done code
2020-03-09 17:43:26 -07:00
Paulus Schoutsen
8a46d93be4 Upgrade hass_nabucasa to 0.32.2 (#32522)
* Upgrade hass_nabucasa to 32.1

* Fix tests

* Update hass-nabucasa to 0.32.2

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-03-09 17:42:26 -07:00
Alexei Chetroi
87b770be08 Add PollControl cluster support to ZHA (#32618)
* Poll control channel

Set check-in interval to 55min.
Set long-poll interval to 6s.

* Update tests.

* Don't use magic numbers.
2020-03-09 19:55:25 -04:00
Aaron Bach
9a3c58213b Validate WWLLN window size in config schema (#32621)
* Validate WWLLN window size in config schema

* Cleanup

* Clean up imports

* Fix tests
2020-03-09 17:18:39 -06:00
Paulus Schoutsen
d4615fd432 Freeze config entry data (#32615)
* Freeze config entry data

* Fix mutating entry.data

* Fix config entry options tests
2020-03-09 14:07:50 -07:00
J. Nick Koston
3318e65948 Convert august to async (#32586)
* Convert august to async

Async io was added to py-august 0.24

* Fix lint
2020-03-09 13:54:05 -07:00
marengaz
09512e9f8b Reflect new repo name (#32611) 2020-03-09 12:46:52 -07:00
Maciej Bieniek
96a0aa3d2b Add new sensors to Brother integration (#32466)
* Add new sensors

* Suggested change
2020-03-09 11:54:43 -07:00
Erik Montnemery
4bb9f1800d Deduplicate MQTT mixin tests (#32563)
* Deduplicate MQTT mixin tests

* Remove test of not yet merged function
2020-03-09 09:40:00 -07:00
Alexei Chetroi
743833e5f3 Bump up ZHA dependencies. (#32609)
* Bump up ZHA dependencies.

* Update tests to match library changes.
2020-03-09 12:39:41 -04:00
David Nielsen
988b400a9c Fix TypeError Exception in AlexaSpeaker (#32318)
* alexa/capabilities.py: Fix TypeError Exception

    - Remove division by zero try/catch -- there is no division
    - Handle TypeError exception when current_volume = None
    - Simplify math and return logic

* Add test for Alexa.Speaker's valid volume range
2020-03-09 09:38:31 -07:00
Jc2k
19faf06ce7 homekit_controller fixes from testing with an LG TV: (#32610)
* Bump aiohomekit to get better reconnection handling and cleaner shutdowns.
 * Read the ACTIVE characteristic and set ok/problem state

Also gets test coverage to 100%.
2020-03-09 12:19:17 -04:00
Thomas Hollstegge
22b5690607 Alexa: Support vacuums without turn_on/turn_off feature (#32570)
* Alexa: Support vacuums without turn_on/turn_off feature
2020-03-09 11:58:47 -04:00
lewei50
e1d6964589 Add IamMeter integration (#30465)
* Update .coveragerc

* Update requirements_all.txt

* Create manifest.json

* Add files via upload

* add codeowner

* add codeowner.

* Update sensor.py

* Update sensor.py

* remove unused import.

* Update manifest.json

* Update sensor.py

* modify requirements_all.txt.

* order imports.

* Update sensor.py

* Use DataUpdateCoordinator rewrite code

* set should_poll to False

* remove unused code 'serial'.

* add available prop

* Update homeassistant/components/iammeter/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Update homeassistant/components/iammeter/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Update homeassistant/components/iammeter/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Update homeassistant/components/iammeter/sensor.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/iammeter/sensor.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/iammeter/sensor.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update sensor.py

* Update sensor.py

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-03-09 08:39:39 -07:00
ochlocracy
fa4f27f78e Remove AlexaPowerController from device_class garage covers in… (#32607) 2020-03-09 08:25:33 -07:00
Franck Nijhof
c0c5c33b20 Fix Withings timezone test (#32602) 2020-03-09 13:45:39 +01:00
Mans Matulewicz
a6e0ab2b3a Add thinkingcleaner optional host param (#32542)
* adding support for optional host param

as thinkingcleaner backend was having issues (again)
-> https://www.thinkingsync.com/

* Update switch.py

* Update sensor.py

* Update switch.py

* Update sensor.py

* Update switch.py

* Update switch.py

* Update sensor.py
2020-03-09 12:56:26 +01:00
Kris Bennett
f7f6c47973 Add Steam game ID and screenshot paths as attributes (#32005)
* Update Steam intergration to list screenshot paths and Steam game ID

* Steam entity_picture now changed to game art when in-game

* Steam - changing API endpoints to constants

* Steam - formatting code for lint

* Update sensor.py

*Removing entity_picture image switching based on current playing game

* Steam - tidying up code

* Update homeassistant/components/steam_online/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-03-09 11:38:24 +01:00
Dave T
df86668dfc Correct grammatical error in CUSTOM_WARNING (#32569) 2020-03-09 09:40:08 +01:00
jey burrows
5ace7de171 Bump rflink to 0.0.52 (#32588) 2020-03-09 09:35:54 +01:00
seanvictory
0dd0b2fa03 Add support for Ubee Router DVW32CB (#32406)
* Update PyUbee to 0.9

Adds support for Ubee Router DVW32CB

* Add support for Ubee Router DVW32CB

* Update pyubee to 0.9

Adds support for router DVW32CB
2020-03-09 09:04:53 +01:00
Oliver
963b5db763 Bump denonavr to 0.8.0 (#32578) 2020-03-08 23:43:12 +01:00
Josef Schlehofer
f54c50fae3 Upgrade youtube_dl to version 2020.03.08 (#32581) 2020-03-08 23:37:58 +01:00
Quentame
8a878bbe72 Bump pyicloud to 0.9.3 (#32582) 2020-03-08 23:32:14 +01:00
Maikel Punie
4fbc404c47 Update python-velbus to fix a missing data file (#32580) 2020-03-08 19:10:05 +01:00
Daniel Høyer Iversen
b5118c41a6 Add Tibber retry (#32554)
* Add retry setup to Tibber

* tibber lib

* update comment

* update comment

* increase delay for every try

* Update homeassistant/components/tibber/__init__.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-03-08 12:20:33 +01:00
Anders Melchiorsen
17215709e1 Simplify logbook duplicate handling (#32572) 2020-03-07 20:27:51 -08:00
J. Nick Koston
a0787cd9be Bump zeroconf to 0.24.5 (#32573)
* Bump zeroconf to 0.24.5

* Empty commit to force ci re-run
2020-03-08 08:52:27 +05:30
Alexei Chetroi
7e781946fa Refactor ZHA device keep alive checker (#32561)
* Refactor zha core device _check_available().
Make it async, so we don't run it in a sync worker.

* Use random keep alive interval for zha device pings.
* Update tests.
2020-03-07 13:52:45 -05:00
David F. Mulcahey
732457745f Add guard to ZHA device triggers (#32559) 2020-03-07 12:59:18 -05:00
Ivan Belokobylskiy
1f510389b8 Fix Yandex transport after API change (#32500)
* Update Yandex transport after API change (home-assistant#32431)

* Update mocked response for test (home-assistant#32431)

* Codestyle fixes (home-assistant#32431)
2020-03-07 18:26:35 +01:00
shred86
ae2e6f9d2a Fix unnecessary method call (#32549) 2020-03-07 16:13:39 +01:00
David F. Mulcahey
e52542c4d7 Allow multiple attribute reads in ZHA (#32498)
* multi attribute reads for lights

* catch specific exceptions

* get attributes

* fix mains powered update

* add guards and use get_attributes

* use debug for read failures

* cleanup

* update return value for read_attributes

* fix on with timed off
2020-03-07 07:33:59 -05:00
Alexei Chetroi
dd91b51435 Make ZHA Scene channel an eventable channel. (#32546) 2020-03-06 17:32:26 -05:00
Raman Gupta
28a5fca7f4 fix step name in strings.json for vizio (#32536) 2020-03-06 10:56:15 -08:00
Tom Schneider
8f2567f30d Add config_flow to shopping_list (#32388)
* Add config_flow to shopping_list

* Fix pylint unused import error

* Use _abort_if_unique_id_configured

* Remove SHOPPING_LIST const

* Use const.py for DOMAIN and CONF_TYPE

* Fix tests

* Remove unchanged variable _errors

* Revert CONF_TYPE (wrong usage)

* Use consts in test

* Remove import check

* Remove data={}

* Remove parameters and default values

* Re-add data={}, because it's needed

* Unique ID checks and reverts for default parameters

* remove pylint comment

* Remove block till done

* Address change requests

* Update homeassistant/components/shopping_list/strings.json

Co-Authored-By: Quentame <polletquentin74@me.com>

* Update homeassistant/components/shopping_list/strings.json

Co-Authored-By: Quentame <polletquentin74@me.com>

* Update tests/components/shopping_list/test_config_flow.py

Co-Authored-By: Quentame <polletquentin74@me.com>

* Update tests/components/shopping_list/test_config_flow.py

Co-Authored-By: Quentame <polletquentin74@me.com>

* Update tests/components/shopping_list/test_config_flow.py

Co-Authored-By: Quentame <polletquentin74@me.com>

* Update tests/components/shopping_list/test_config_flow.py

Co-Authored-By: Quentame <polletquentin74@me.com>

* Only test config_flow

* Generate translations

* Move data to end

* @asyncio.coroutine --> async def, yield from --> await

* @asyncio.coroutine --> async def, yield from --> await (tests)

* Remove init in config flow

* remove if not hass.config_entries.async_entries(DOMAIN)

* Add DOMAIN not in config

* Fix tests

* Update homeassistant/components/shopping_list/config_flow.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Fix tests

* Update homeassistant/components/shopping_list/__init__.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

Co-authored-by: Quentame <polletquentin74@me.com>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-03-06 10:17:30 -08:00
Rami Mosleh
e1cc2acdf9 Specify rtsp_transport for Onvif Camera (#31918)
* specify rtsp_transport for onvif camera

* remove used variable

* Update homeassistant/components/stream/__init__.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* change options to stream_options

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-06 09:59:57 -08:00
Bram Kragten
ac945242dc Updated frontend to 20200306.0 (#32532) 2020-03-06 17:42:19 +01:00
Jc2k
2879081772 Implement source switching for homekit_controller televisions (#32526) 2020-03-06 15:47:40 +00:00
olijouve
0d667c1bd9 Add more onvif PTZ move modes (#30152)
* Adding support for PTZ move modes

Adding support for other PTZ move modes.
Onvif intergration used to only support RelativeMove where it should also supports AbsoluteMove, ContinuousMove and Stop.
For exemple Goke GK7102 based IP camera only support ContinuousMove mode.

This commit add those new modes with avaibility to select mode and params in service call.

* Adding support for PTZ move modes

Adding support for other PTZ move modes.
Onvif intergration used to only support RelativeMove where it should also supports AbsoluteMove, ContinuousMove and Stop.
For exemple Goke GK7102 based IP camera only support ContinuousMove mode.

Update service helper for new avaibility to select mode and params in service call.

* RelativeMode as default move_mode to avoid breakchange

RelativeMode as default move_mode to avoid breakchange

* add missing attribute

add missing continuous_duration attribute

* change service attribute label for continuous_duration

* update description

fix wrong assertion for move_mode attr description

* Update services.yaml

* Update services.yaml

fix wrong wording for move_mode

* Update camera.py

Using defined constants instead of  raw strings in conditions

* Update camera.py

Replace integer to floating point in logger debug PTZ values

* Update services.yaml

* Update services.yaml

* Update camera.py

* Update camera.py

* use dict[key] for required schema keys and keys with default schema values

* remove async for setup_ptz method

* lint error

* remove unecessary PTZ_NONE = "NONE"

changed request by @MartinHjelmare

* addressing @ MartinHjelmare comments

- Remove None in defaluts and dicts
- Replace long if blocks

* remove NONE

* lint issue

* Update camera.py

* Fix lint error - typo

* rename onvif_ptz service to just ptz

* rename onvif_ptz service to just ptz

* use dict[key] when default values are set

use service.data[key] instead of service.data.get[key] when default value is set in service schema

* adresse comment: use dict[key] for pan tilt zoom

* Apply suggestions from code review

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-03-06 15:14:01 +01:00
Chris Talkington
3b75fdccfd Add availability to roku media player entities (#32484)
* track if roku is available based on update errors.

* Update media_player.py

* Update media_player.py
2020-03-06 13:55:32 +01:00
Josef Schlehofer
5f6158f656 Upgrade youtube_dl to version 2020.03.06 (#32521) 2020-03-06 07:30:04 +01:00
Paulus Schoutsen
e02042b33e Send messages conforming new facebook policy (#32516) 2020-03-05 17:19:30 -08:00
Paulus Schoutsen
19254eee30 Upgrade hass-nabucasa to 0.32 (#32508) 2020-03-05 13:34:24 -08:00
Paulus Schoutsen
a579fcf248 Add app support for TVs to Vizio integration (#32432)
* add app support

* code cleanup, add additional test, add CONF_APPS storage logic for import

* simplify schema defaults logic

* remove unnecessary lower() and fix docstring

* remove default return for popping CONF_APPS during import update because we know entry data has CONF_APPS due to if statement

* further simplification

* even more simplification

* fix type hints

* move app configuration to separate step, fix tests, and only make app updates if device_type == tv

* remove errors variable from tv_apps and move tv_apps schema out of ConfigFlow for consistency

* slight refactor

* remove unused error from strings.json

* set unique id as early as possible

* correct which dictionary to use to set unique id in pair_tv step
2020-03-05 13:34:12 -08:00
Paulus Schoutsen
873bf887a5 Add OwnTracks Friends via person integration (#27303)
* Returns an unencrypted location of all persons with device trackers

* Handle encrypted messages and exclude the poster's location

* Friends is by default False. Reformats with Black

* Updates the context init to account for the Friends option

* Fix Linter error

* Remove  as a config option

* No longer imports encyrption-related functions in encrypt_message

* Fix initialization in test

* Test the friends functionality

* Bugfix for persons not having a location

* Better way to return the timestamp

* Update homeassistant/components/owntracks/__init__.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Linting and tid generation

* Fix test

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-05 12:55:48 -08:00
David F. Mulcahey
b5022f5bcb guard against invalid trigger and action scenarios (#32512) 2020-03-05 15:52:09 -05:00
David Bonnes
ae0ea0f088 Bugfix evohome converting non-UTC timezones (#32120)
* bugfix: correctly handle non-UTC TZs
* bugfix: system mode is always permanent
* bugfix: handle where until is none
* tweak: improve logging to support above fixes
2020-03-05 20:42:52 +00:00
Paulus Schoutsen
4717d072c9 Remove discovery and legacy config file loading for Plex (#32510) 2020-03-05 12:36:18 -08:00
Paulus Schoutsen
8aea538662 Allow teaching logbook about events (#32444)
* Allow teaching logbook about events

* Use async_add_executor_job

* Fix tests
2020-03-05 11:55:50 -08:00
Paulus Schoutsen
7c51318861 Require title, separate show sidebar option (#32479)
* Require title, separate show sidebar option

* Fix list command not updating

* Some more test checks
2020-03-05 11:52:12 -08:00
Paulus Schoutsen
d885853b35 Make it possible to fetch proxy media player album art (#32471) 2020-03-05 11:45:36 -08:00
Paulus Schoutsen
6a21afa2a8 Improve script validation (#32461) 2020-03-05 11:44:42 -08:00
Ville Skyttä
da7c5518f3 Add Huawei LTE operator and network related sensors (#32485)
* Add Huawei LTE operator and network related sensors

Adds "Operator search mode", "Operator name", "Operator code", and "Preferred mode" sensors

* Blackify

* Blackify "Add Huawei LTE operator and network related sensors"
2020-03-05 21:29:53 +02:00
Jc2k
007d934214 Initial support for HomeKit enabled televisions (#32404)
* Initial support for HomeKit enabled televisions

* Fix nit from review
2020-03-05 13:49:56 +00:00
Quentame
85ba4692a9 Get pending iCloud devices when available + request again when needs an update (#32400)
* Fetch iCloud devices again if the status is pending

* Remove "No iCloud device found" double check

* fix default api_devices value

* Remove useless unitialisation declarations
2020-03-05 08:50:39 +01:00
Paulus Schoutsen
521cc7247d Add Dynalite switch platform (#32389)
* added presets for switch devices

* added channel type to __init and const

* ran pylint on library so needed a few changes in names

* removed callback

* bool -> cv.boolean
2020-03-04 22:05:39 -08:00
Paulus Schoutsen
d216c1f2ac UniFi - Add block network access control to config option (#32004)
* Add block network access control to config option

* Clean up
2020-03-04 21:55:56 -08:00
Paulus Schoutsen
1615a5ee81 Use unique_id in Plex config entries (#32489) 2020-03-04 21:42:48 -08:00
Paulus Schoutsen
81f99efda1 Mock all invocations of coronavirus.get_cases (#32487) 2020-03-04 21:42:07 -08:00
Paulus Schoutsen
81810dd920 Modernize WWLLN config flow (#32194)
* Modernize WWLLN config flow

* Code review

* Update tests
2020-03-04 18:23:00 -08:00
Paulus Schoutsen
56cf4e54a9 Add github sensor latest tag attribute (#32360)
* Add attribute 

latest release tag

* add attrs = 

and only create attr Tag if exists
made requested changes

* change condition for _latest_release_tag

to use self._github_data.latest_release_url

* Correct changes

* Update sensor.py

* blackify
2020-03-04 18:14:45 -08:00
Paulus Schoutsen
9a4aad1777 Add async_setup_entry/async_unload_entry for remote platform (#31974)
* add async_setup_entry for remote platform

* add async_unload_entry for remote platform

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Type

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-04 18:09:17 -08:00
Paulus Schoutsen
daff87fe5d Emoncms API now provides a Unit of Measurement (#32042)
* Emoncms API provides a Unit

The EmonCMS API has been amended to include a 'unit' as part of it's payload.  By using this information, all the sensors can be created without the need for individual sensors to be setup by type.

The change is backward compatible so if a unit type has been specified in the configuration, this will be used by default.

If no unit is pecified either by the Home Assistant configuration, or the Emoncms API, then the default of W will be used as before.

* Update sensor.py

Check the 'unit' key is in the API call. Older systems may not have that key in the payload.

* Modified approach with new configuration item

* Removed new config item

Removed the configuration item. The integration attempts to get the unit from the API.

If this fails *or* the unit key of the API is blank, either the specified unit, or the default will be used.

If approved, documentation will be updated.

* Update homeassistant/components/emoncms/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Update homeassistant/components/emoncms/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Apply suggestions from code review

* Apply suggestions from code review v2

* Update homeassistant/components/emoncms/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Update sensor.py

Update `config_unit`

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-03-04 18:03:51 -08:00
Paulus Schoutsen
bfe1e8fef3 fix double tab and match events. (#32108)
this propose makes some logic to the device triggers, matching the events for the aqara cube.
this also fixes the double tap function on side 2
2020-03-04 17:54:00 -08:00
Paulus Schoutsen
b848c97211 Add soundtouch attributes exposing multiroom zone info (#28298)
* [soundtouch] workaround for API bug when removing multiple slaves from a zone at once

* [soundtouch] added additional attributes exposing multiroom zone info

* Fix update with slave entities

* Add zone attributes test

* Fix and clean up tests

* Fix typo

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-03-04 17:53:15 -08:00
Paulus Schoutsen
2316f7ace4 Add edl21 component for SML-based smart meters (#27962)
* Add edl21 component for SML-based smart meters

* edl21: Remove unused variable

* [edl21] Add 1 minute throttle to the sensor

* Update homeassistant/components/edl21/manifest.json

Fix documentation URL

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* edl21: Move imports to top

* edl21: Remove special case for STATE_UNKNOWN, which replicated default behavior

* edl21: Implement blacklist for and warn about unhandled OBIS values

* edl21: Make blacklist global

* edl21: Add filter to issues URL

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* edl21: Rename device to entity

* edl21: Don't schedule async_add_entities

* edl21: Use dispatcher, implement own throttling mechanism

* edl21: Simplify keeping track of known obis

* edl21: Use whitelist for state attributes

* edl21: Remove dispatcher on shutdown

* edl21: Convert state attributes to snakecase

* edl21: Annotate handle_telegram with @callback

* edl21: Call async_write_ha_state instead of schedule_update_ha_state

Co-authored-by: David Straub <straub@protonmail.com>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-04 17:43:12 -08:00
Paulus Schoutsen
c4ed2ecb61 Add node_def_id for ISY994i wrapped X10 modules (#31815) 2020-03-04 17:42:18 -08:00
Paulus Schoutsen
eac1f029e5 Allow string values on zwave.set_node_value (#31061)
* Allow string values on zwave.set_node_value

This allows for:

* Accessing longer value_ids. In some cases, value ids in z-wave nodes are very large (17 digits in my case). Passing them as int does not seem to work well (python probably truncates the number), but passing them as string works fine
* Changing color values, which are represented as hex string

reformat test

* update services.yaml with string set_node_value
2020-03-04 17:40:58 -08:00
Paulus Schoutsen
1d3647e6a1 Make gen_requirements_all.py case insensitive for ignored pack… (#30885) 2020-03-04 17:39:59 -08:00
Paulus Schoutsen
2d3b117cb8 Use SCAN_INTERVAL instead of Throttle for google travel time (#31420)
The documentation for google_travel_time was at odds with the
implementation. The documentation stated a default scan time of
5 minutes, but the implementation was using Throttle which resulted
in the sensor updating at a maximum rate of one API call every
5 minutes. This was especially at odds with a given example at
the end of the documentation, which showed updating the sensor
every 2 minutes during commute times.

This change brings the implementation in line with the docs by
adopting the `SCAN_INTERVAL` constant set to the stated default
of 5 minutes and removing the Throttle.
2020-03-04 17:39:28 -08:00
Paulus Schoutsen
7b5b909f0a ZHA Dependencies bump (#32483)
* ZHA Dependencies bump.

* Bump up ZHA dependencies.
2020-03-04 17:35:07 -08:00
Paulus Schoutsen
3ca97a0517 Add sighthound timestamped file (#32202)
* Update image_processing.py

Adds save timestamp file and adds last_detection attribute

* Update test_image_processing.py

Adds test

* Adds assert pil_img.save.call_args

* Test timestamp filename

* Add test bad data

* Update test_image_processing.py

* Fix bad image data test

* Update homeassistant/components/sighthound/image_processing.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-03-04 17:31:54 -08:00
Alexei Chetroi
e416f17e4d ZHA: Successful pairing feedback (#32456) 2020-03-04 19:27:37 -05:00
Paulus Schoutsen
76fec90fec Reduce log level for initial error and bump library version (#32381)
* Reduce log level for initial error and bump library version

  * Use new buienradar library version which reduces the log level
    for some types of warnings.
  * Initially logs at a lower level and only logs at WARN for repeated
    errors.

This should serve to reduce confusion with users such as in
issue #32301.

* Fix linter error with new linter settings.

* Fix linter warning

* Update homeassistant/components/buienradar/util.py

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-04 15:32:44 -08:00
Quentame
15a5cebd5f Add icons to Coronavirus (#32480)
* Add icons to Coronavirus

* Update homeassistant/components/coronavirus/sensor.py

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-05 00:02:22 +01:00
Paulus Schoutsen
9a8017aadd Add more Huawei LTE sensors (#32123)
* Add Huawei LTE WiFi client count and DNS server sensors

* Add Huawei LTE current month statistics sensors
2020-03-04 14:56:37 -08:00
Paulus Schoutsen
d1beb92c5d Add abode support for CUE automations (#32296)
* Add support for CUE automations

* Update requirements

* Minor update to string name
2020-03-04 14:54:28 -08:00
Paulus Schoutsen
2abdfc9da6 GeoNet NZ Quakes code improvements (#32338)
* code quality improvements

* code quality improvements and fixed tests

* explicitly set unique ids

* improve unique id creation

* remove entities from entity registry

* added test for removing entities from entity registry

* revert entity registry handling from sensor and test code

* check for entity registry removal in geolocation test case

* make import absolute; isort

* change quality scale
2020-03-04 14:52:16 -08:00
Paulus Schoutsen
dd7d8d4792 Remove 'show all controls' option for Plex (#32391) 2020-03-04 14:42:50 -08:00
Paulus Schoutsen
0e436ac80e add const file for roku (#32470) 2020-03-04 14:24:59 -08:00
springstan
c7d983fd44 Catch an extra error for Ring (#32477) 2020-03-04 23:09:54 +01:00
Daniel Høyer Iversen
0c0d4c460f Upgrade Tibber library to 0.13.2 (#32478) 2020-03-04 22:48:00 +01:00
Pascal Vizeli
9aaab41985 Deprecate camera WS API (#32473) 2020-03-04 21:58:07 +01:00
Paulus Schoutsen
0763dc6089 Fix filter sensor processing states that aren't numbers (#32453)
* lint

* only_numbers flag
2020-03-04 12:47:53 -08:00
Martin Hjelmare
e9978e77bd Upgrade huawei-lte-api to 1.4.10 (#32472)
https://github.com/Salamek/huawei-lte-api/releases/tag/1.4.8
https://github.com/Salamek/huawei-lte-api/releases/tag/1.4.9
https://github.com/Salamek/huawei-lte-api/releases/tag/1.4.10
2020-03-04 20:51:56 +01:00
HomeAssistant Azure
104350265d [ci skip] Translation update 2020-03-04 18:13:24 +00:00
Alexei Chetroi
20333703c5 Remove ZHA attribute listening channel (#32468)
* remove AttributeListeningChannel
* pull sleeps
* update signature to fix pylint
2020-03-04 13:11:53 -05:00
J. Nick Koston
7f91501a36 Use a requests Session for rest sensors (#32463)
This avoids the ssl setup overhead for each request
2020-03-04 08:32:38 -08:00
Paulus Schoutsen
b27c46750c Update error handling in update coordinator (#32452) 2020-03-04 08:05:46 -08:00
z0p
f62322cfb4 Add set_speed to smarty fan (#32255) 2020-03-04 10:09:33 +01:00
Raman Gupta
4f619691df Add is_volume_muted property to vizio integration (#32332)
* add is_muted property and update tests

* black

* manually set is_muted on async_mute_volume calls to set state early

* combine two lines into one

* set is_muted to None when device is not on
2020-03-04 10:04:52 +01:00
Alan Tse
6a6bf517fe Add energy added attribute to Tesla charging rate sensor (#32368)
* Add charge_energy_added attribute

* Bump teslajsonpy
2020-03-04 10:00:34 +01:00
Paulus Schoutsen
7678d66464 Fix device tracker TrackerEntity defaults (#32459) 2020-03-04 09:43:52 +01:00
Philipp Schmitt
af76a336af Update roombapy to 1.4.3 (#32462) 2020-03-04 09:41:34 +01:00
Austin Mroczek
d666b15689 Bump total-connect-client to 0.53 (#32460) 2020-03-04 08:08:31 +01:00
Paulus Schoutsen
4be9766498 Merge pull request #32457 from home-assistant/rc
0.106.5
2020-03-03 20:19:14 -08:00
Paulus Schoutsen
4080d6a822 Bumped version to 0.106.5 2020-03-03 18:26:19 -08:00
Robert Svensson
6d06844318 UniFi - Fix websocket bug (#32449) 2020-03-03 18:26:11 -08:00
Paulus Schoutsen
a150d6dcf3 Remove hassfest blacklisted rest (#32441)
* Remove blacklisted deps from hassfest deps

* Whitelist all internal integrations
2020-03-03 18:26:10 -08:00
Achilleas Pipinellis
a0390783bb Fix pushover's ATTR_RETRY env variable typo (#32440) 2020-03-03 18:26:10 -08:00
J. Nick Koston
91b10e875f Properly define dependency for pvoutput integration on rest in… (#32435) 2020-03-03 18:26:09 -08:00
Paulus Schoutsen
f04969cf30 Filter out duplicate logbook states (#32427) 2020-03-03 18:26:08 -08:00
Alan Tse
cdde5a37cd Fix too many device tracker updates in log for Tesla (#32426)
* Fix Tesla too many device tracker updates in log

* Empty commit to re-trigger build

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2020-03-03 18:26:07 -08:00
Alan Tse
f0c7a7c1bf Fix too many device tracker updates in log for Tesla (#32426)
* Fix Tesla too many device tracker updates in log

* Empty commit to re-trigger build

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2020-03-03 18:25:32 -08:00
Achilleas Pipinellis
7e3e4c1668 Fix pushover's ATTR_RETRY env variable typo (#32440) 2020-03-03 17:36:28 -08:00
Robert Svensson
02c8cd07f3 UniFi - Fix websocket bug (#32449) 2020-03-03 17:32:13 -08:00
Paulus Schoutsen
4cf86262af Numeric state trigger: validate that above is not above below (#32421)
* Numeric state trigger: validate that above is not above below

* Lint
2020-03-03 17:26:44 -08:00
Paulus Schoutsen
db7d0eb9b9 Remove hassfest blacklisted rest (#32441)
* Remove blacklisted deps from hassfest deps

* Whitelist all internal integrations
2020-03-03 13:57:09 -08:00
Paulus Schoutsen
fed23030d6 Filter out duplicate logbook states (#32427) 2020-03-03 13:56:32 -08:00
Paulus Schoutsen
8f6651af3d Update system log grouping (#32367) 2020-03-03 13:55:15 -08:00
Alexei Chetroi
896df9267a Fix ZHA device healthcheck pings (#32425) 2020-03-03 13:37:17 -05:00
J. Nick Koston
cfa61a6b74 Properly define dependency for pvoutput integration on rest in… (#32435) 2020-03-03 09:25:50 -08:00
J. Nick Koston
1119da7e8a Flume Cleanups (unique id, fix missing timeout, http session,… (#32384)
* Flume Cleanups

* Sensors now show the name

* include_devices and exclude_devices are now available in the config.

* Address review items

* bump as 0.3.0 is published
2020-03-03 09:22:26 -08:00
Jeff Irion
59b4e42f8b Remove SUPPORT_PLAY_MEDIA from Roku (#32378) 2020-03-03 16:59:32 +01:00
Maciej Bieniek
2f8381b1bf Bump brother library (#32436) 2020-03-03 16:59:02 +01:00
Pascal Vizeli
5bbbe60635 Disable codecov because it stop working after renaming.
Come back with GitHub action migration
2020-03-03 16:06:17 +01:00
Bram Kragten
558da56d75 Update config.yml 2020-03-03 11:11:38 +01:00
Paulus Schoutsen
a0403a8864 Merge pull request #32424 from home-assistant/rc
0.106.4
2020-03-02 19:41:01 -08:00
Paulus Schoutsen
bfaad97318 Add unique ID to coronavirus (#32423) 2020-03-02 18:10:51 -08:00
Paulus Schoutsen
c62961f40c Add unique ID to coronavirus (#32423) 2020-03-02 18:10:38 -08:00
Paulus Schoutsen
d6c15d2f45 Bumped version to 0.106.4 2020-03-02 18:04:07 -08:00
Paulus Schoutsen
815502044e Coronavirus updates (#32417)
* Sort countries alphabetically

* Update sensor name

* Add migration to stable unique IDs

* Update sensor.py
2020-03-02 18:04:01 -08:00
mezz64
08f5b49dc4 Catch Eight Sleep API errors, don't round None type (#32410)
* Catch API errors, don't round None type

* Specify error type
2020-03-02 18:04:00 -08:00
mezz64
fab55b0ea2 Bump pyeight to 0.1.4 (#32363) 2020-03-02 18:03:59 -08:00
elmurato
649ec2fc8e Fixed TypeError with old server versions (#32329) 2020-03-02 18:03:59 -08:00
mezz64
aacdc1bc2d Catch Eight Sleep API errors, don't round None type (#32410)
* Catch API errors, don't round None type

* Specify error type
2020-03-02 18:01:39 -08:00
Paulus Schoutsen
fcbea47c74 Coronavirus updates (#32417)
* Sort countries alphabetically

* Update sensor name

* Add migration to stable unique IDs

* Update sensor.py
2020-03-02 17:59:32 -08:00
Matt Snyder
ee7ce47860 Add QVR Pro integration (#31173)
* Initial working commit

* Create const file.  Load camera from component.

* Handle failed authentication.  Bump library version.

* Remove line break

* Camera attributes and recording services

* Add services, manifest, constant update, and exclude_channels.  Prefix channel name.  Update service argument.

* Update codeowners

* Update coveragerc

* Remove codeowners line

* Update codeowners again from python3 -m script.hassfest

* Update homeassistant/components/qvrpro/__init__.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Requested changes

* Fix typo

* Update to use exception. Bump library version.

* Support stream component

* Update module header

* Missing property wrapper

* Partial requested changes

* Update coveragerc and codeowners

* Move constants to const file.  Add SHORT_NAME

* Add conf variable

* Use camera domain

* More requested changes

* Requested changes

* Requested changes

* Update prefix

* Handle error condition when camera is not configured to support live streaming

* Move method to camera setup.  Disable stream component support.

* Move auth string to library to prevent private member access

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-03-03 01:10:02 +01:00
Paulus Schoutsen
a25b94cd2d Update azure-pipelines-wheels.yml 2020-03-02 14:01:40 -08:00
Bram Kragten
21e0df42ac Update azure-pipelines-release.yml for Azure Pipelines 2020-03-02 13:59:21 -08:00
Bram Kragten
66d70195c9 Update azure-pipelines-release.yml for Azure Pipelines 2020-03-02 22:55:57 +01:00
Paulus Schoutsen
f7f9126610 Merge pull request #32414 from home-assistant/rc
0.106.3
2020-03-02 13:43:02 -08:00
Paulus Schoutsen
52809396d4 Bumped version to 0.106.3 2020-03-02 13:40:57 -08:00
Paulus Schoutsen
121d967732 Add coronavirus integration (#32413)
* Add coronavirus integration

* Update homeassistant/components/coronavirus/manifest.json

Co-Authored-By: Franck Nijhof <git@frenck.dev>

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2020-03-02 13:40:51 -08:00
Paulus Schoutsen
1603f7ac21 Add coronavirus integration (#32413)
* Add coronavirus integration

* Update homeassistant/components/coronavirus/manifest.json

Co-Authored-By: Franck Nijhof <git@frenck.dev>

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2020-03-02 13:40:11 -08:00
David F. Mulcahey
2ba514253c Bump ZHA Quirks to 0.0.34 (#32401)
* bump zha quirks version

* add required parts to support alt opple remote
2020-03-02 11:26:37 -05:00
Pascal Vizeli
87abd193ee Update azure-pipelines-ci.yml for Azure Pipelines 2020-03-02 16:33:39 +01:00
Pascal Vizeli
049897365c Update azure-pipelines-ci.yml for Azure Pipelines 2020-03-02 16:33:11 +01:00
jjlawren
df3f7687d4 Refactor Certificate Expiry Sensor (#32066)
* Cert Expiry refactor

* Unused parameter

* Reduce delay

* Deprecate 'name' config

* Use config entry unique_id

* Fix logic bugs found with tests

* Rewrite tests to use config flow core interfaces, validate created sensors

* Update strings

* Minor consistency fix

* Review fixes, complete test coverage

* Move error handling to helper

* Subclass exceptions

* Better tests

* Use first object reference

* Fix docstring
2020-03-02 07:44:24 -06:00
kuchel77
eb90cefd84 Keeping adding in Github repositories after error (#32393) 2020-03-02 13:59:11 +01:00
J. Nick Koston
7ca4665711 Move keypad battery implementation details into py-august (#32349)
* Move keypad battery implementation details into py-august

* Upgrade to py-august 0.22.0 which also adds gen2 doorbell battery data

* remove cruft from previous refactor
2020-03-01 23:22:28 -08:00
J. Nick Koston
924c313c8a Add application/xml as an XML to JSON auto converted mime type… (#32289)
* Resolves issue #32280
2020-03-01 23:22:01 -08:00
HomeAssistant Azure
da959c8f7b [ci skip] Translation update 2020-03-02 00:31:47 +00:00
Daniel Høyer Iversen
c361358c6d Upgrade Tibber library to 0.13.0 (#32369) 2020-03-01 22:56:31 +01:00
Ziv
e13d5bdc10 Refactor dynalite integration for multi-platform (#32335)
* refactoring for multi platform

* adopted test_bridge to refactoring

* refactoring tests for multi-platform
additional coverage in config and init

* comment for clarity

* more specific imports from lib

* library version bump

* removed async_update

* changed parameter order to start with hass

* removed pylint disable

* unsubscribe from signal dispatcher
inherit from Entity

* use device.unique_id

* changed hass_obj to hass

* added test for remove entity
bug fix from the test

* removed the polling try_connect. hate polling... it is now part of the async_setup()
significantly makes the code clearer and simplifies the tests

* removed leftover debug logs in the library

* changed tests to get the entry_id from hass

* changed place to assign hass.data only after success

* fixes for test_init

* removed assert

* removed device_info

* removed bridge internal from common

* modified test_bridge to work without the bridge directly

* removed bridge from test_existing_update

* changed update to not use bridge internals

* dyn_bridge fixture no longer used - removed
2020-03-01 22:44:24 +01:00
David Nielsen
fc98faa425 Add Media Stop Support to BraviaTV Mediaplayer (#32220)
* Add media_stop to braviatv mediaplayer

* Fix typo in media_stop()

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-03-01 22:07:44 +01:00
AJ Schmidt
9da5bc9dce Fix AlarmDecoder Integration to use Instant Mode for alarm_arm_night (#32292) 2020-03-01 20:25:16 +01:00
guillempages
f53c94ed2a Add Tankerkoenig integration (#28661)
* Initial version

Parse configuration, but return a fixed value

* Add basic functionality

Request real data from the server
Currently the prices are not getting updated, but the petrol station
data is real

* Update values regularly

The tankerkoenig values get updated regularly with real data.

* Move base functionality for the sensor to a base class

And move that to an own file, so that it can be inherited

* Reduce calls to tankerkoenig api

Use a master/slave concept for sensors; one master gets the data and
updates it into the slaves.

* Update requirements files

* Update all gas stations at once

* Remove tests directory

Currently there are no tests for the integration; will be added in
a future commit.

* Fix slaves not being updated

Let the base class regularly poll, so that slaves are also updated

* Refactor entity creation

Create an auxiliary method to add a station to the entity list,
in preparation to allowing extra stations.

* Add possibility to manually add stations

Add a new configuration option "stations" to manually add extra stations

* Fix style issues

Make the code more pythonic

* Remove redundant code

Implement suggestions from the code review

* Change to platform component

Remove the master/slave concept, in favor of a platform with dummy sensors.
The platform takes care of contacting the server and fetching updates
atomically, and updating the data on the sensors.

* Rename ATTR_STATE

Rename the attribute to "IS_OPEN", to avoid confusion with the sensor state.

* Minor updates

Combine two consecutive error logs into a single one.
Update the sensor's icon

* Separate address into different fields

* Style updates

Use "[]" syntax instead of ".get()" for required parameters
Use warning log level for not available fuel types

* Implement review comments

Fix style issues
Improve error messages
Remove redundant options

* Refactor using DataUpdateCoordinator

Use the new DataUpdateCoordinator to fetch the global data from
the API, instead of implementing an own method.
Also fix comments from the PR

* Implement PR comments

Implement suggestions to improve code readability and keep the Home Assistant style.
Also separate fetching data to an async thread
2020-03-01 16:49:07 +01:00
Colin Robbins
0431b983d2 Add optimistic mode for somfy covers that do not support position (#31407)
* Add a shadow for covers that do not support postion

* Rename shadow as optimistic

* Set optimisic default mode

* fix black error

* Remove redundant check

* optimisitc variable name consistency with config
2020-03-01 16:42:26 +01:00
Josef Schlehofer
a9a523b05c Upgrade youtube_dl to version 2020.03.01 (#32376) 2020-03-01 15:13:56 +01:00
Sébastien RAMAGE
7a7fdc5de6 Add sms support to pushbullet notification (#32347)
* add sms support

* fix formating

* fix formating

* fix whitespace

* fix format
2020-03-01 15:07:14 +01:00
mezz64
e9206b26ad Bump pyeight to 0.1.4 (#32363) 2020-03-01 15:05:37 +01:00
Tim van Cann
f0b5e132af Bump avri api version (#32373)
* Bump avri api version

* Trigger CI
2020-03-01 15:04:18 +01:00
Paulus Schoutsen
c6e85cac0b Require IFTTT to send data as dictionary (#32317)
* Require IFTTT to send data as dictionary

* Update logging
2020-02-29 20:37:06 -08:00
Robert Chmielowiec
8e3492d4f5 ZHA: Support light flashing (#32234) 2020-02-29 18:37:06 -05:00
Marius
3ab04118f6 Fix github sensor short SHA (#32316) 2020-02-29 14:35:28 +01:00
Erik Montnemery
c4ac3155e4 Add brightness to light device turn_on action (#32219)
* Add support for setting brightness

* Remove default brightness
2020-02-29 13:33:20 +01:00
J. Nick Koston
be14b94705 Restore august lock changed_by state on restart (#32340)
* Various code review items from previous PRs

* Add a test for fetching the doorbell camera image

* Switch to using UNIT_PERCENTAGE for battery charge unit

* Add tests for changed_by
2020-02-29 12:12:50 +01:00
Aaron Bach
e9a7b66df6 Add config entry for AirVisual (#32072)
* Add config entry for AirVisual

* Update coverage

* Catch invalid API key from config schema

* Rename geographies to stations

* Revert "Rename geographies to stations"

This reverts commit 5477f89c24cb3f58965351985b1021fc5fc794a5.

* Update strings

* Update CONNECTION_CLASS

* Remove options (subsequent PR)

* Handle import step separately

* Code review comments and simplification

* Move default geography logic to config flow

* Register domain in config flow init

* Add tests

* Update strings

* Bump requirements

* Update homeassistant/components/airvisual/config_flow.py

* Update homeassistant/components/airvisual/config_flow.py

* Make schemas stricter

* Linting

* Linting

* Code review comments

* Put config flow unique ID logic into a method

* Fix tests

* Streamline

* Linting

* show_on_map in options with default value

* Code review comments

* Default options

* Update tests

* Test update

* Move config entry into data object (in prep for options flow)

* Empty commit to re-trigger build
2020-02-28 20:14:17 -07:00
Diogo Gomes
bf33144c2b Bump pyipma to 2.0.5 (#32337)
* bump pyipma version to 2.0.5

* bump pyipma version to 2.0.5
2020-02-28 17:37:34 -08:00
Bram Kragten
3ea29635a0 Updated frontend to 20200228.0 (#32334) 2020-02-29 01:55:27 +01:00
HomeAssistant Azure
2d4ee01c1a [ci skip] Translation update 2020-02-29 00:31:43 +00:00
Alexei Chetroi
5fbaaf41dc Bump up ZHA depdendency (#32336) 2020-02-28 19:13:49 -05:00
Alexei Chetroi
0670b4f457 Use collection helpers for counter integration (#32295)
* Refactor counter to use config dict.

* Use collection helpers for counter integration.

* Update tests.

* Use callbacks were applicable.
2020-02-28 14:06:39 -08:00
elmurato
4a95eee40f Fixed TypeError with old server versions (#32329) 2020-02-28 13:39:46 -08:00
Paulus Schoutsen
deda2f86e7 Allow managing Lovelace storage dashboards (#32241)
* Allow managing Lovelace storage dashboards

* Make sure we do not allow duplicate url paths

* Allow setting sidebar to None

* Fix tests

* Delete storage file on delete

* List all dashboards
2020-02-28 12:43:17 -08:00
Paulus Schoutsen
ede39454a2 Merge remote-tracking branch 'origin/master' into dev 2020-02-28 12:42:02 -08:00
Paulus Schoutsen
3b147bcbf7 Merge pull request #32327 from home-assistant/rc
0.106.2
2020-02-28 12:40:20 -08:00
springstan
f1a0ca7cd3 Add and use percentage constant (#32094)
* Add and use percentage constant

* Fix pylint error and broken test
2020-02-28 11:46:48 -08:00
J. Nick Koston
ca81c6e684 Ensure rest sensors are marked unavailable when http requests… (#32309) 2020-02-28 11:43:00 -08:00
J. Nick Koston
c7f128f286 Ensure rest sensors are marked unavailable when http requests… (#32309) 2020-02-28 11:41:41 -08:00
Paulus Schoutsen
e62ba49979 Bumped version to 0.106.2 2020-02-28 11:38:53 -08:00
Robert Svensson
6ea20090a4 UniFi - Temporary workaround to get device tracker to mark cli… (#32321) 2020-02-28 11:38:37 -08:00
Paulus Schoutsen
c43b7d10d8 revent saving/deleting Lovelace config in safe mode (#32319) 2020-02-28 11:37:57 -08:00
Bram Kragten
430fa24acd Updated frontend to 20200220.5 (#32312) 2020-02-28 11:36:39 -08:00
Paulus Schoutsen
601f2c693d Prevent saving/deleting Lovelace config in safe mode (#32319) 2020-02-28 11:12:16 -08:00
Robert Svensson
f17462b159 UniFi - Temporary workaround to get device tracker to mark cli… (#32321) 2020-02-28 10:28:03 -08:00
Bram Kragten
3dc1ece33c Updated frontend to 20200220.5 (#32312) 2020-02-28 07:56:39 -08:00
Malte Franken
6852ccd8de change log level (#32244) 2020-02-28 12:41:21 +01:00
springstan
157f972d72 Use f-strings in integrations starting with "H" - "L" (#32265)
* Use f-strings in integrations starting with "H"

* Use f-strings in integrations starting with "I"

* Use f-strings in integrations starting with "J"

* Use f-strings in integrations starting with "K"

* Use f-strings in integrations starting with "L"

* Fix lint error

* Use join instead of f-string in homekit_controller

* Use local variables with f-strings

* Fix lint error

* Escape the characters in f-string

* Sort imports with isort in homeworks light

* Fix pylint error

* Fix broken tests

* Fix broken tests v2
2020-02-28 12:39:29 +01:00
Marius
7714160f4c Change github sensor state to short commit sha (#31581)
* change state to latest_release_url

to have a meaningful frontend representation.
self._github_data.latest_commit_sha is still available in the attributes, so no info is lost

* template state to show only the tag

and not the full url to the tag

* add guard to update(self) for state

* add empty line 150

black...

* Update sensor.py

* add SHA if no release url

* Correct sha to 7 digits

* take out fallback on state
2020-02-28 12:34:39 +01:00
Malte Franken
adb3bb3653 Explicitly set unique ids for GDACS integration (#32203)
* explicitly set unique ids

* use config flow's unique id

* use config's unique id
2020-02-28 11:47:49 +01:00
Franck Nijhof
2390a7f365 Pass in aiohttp session for onvif (#32045) 2020-02-28 11:46:06 +01:00
Petro31
2c1c395c28 Set min and max temp only if it is not None (#32262) 2020-02-28 09:49:47 +01:00
Tim van Cann
1d962aeb65 Add Avri waste collection sensor (#31134)
* Add Avri waste collection sensor

* Apply black formatting

* Update manifest

* Add requirements

* Add sensor to coverage

* Update import order

* Bump dependency to include todays pickup

* Bump avri version in requirements_all.txt

* Code review comments

* Reduce scan interval to 4 hours

This makes sure that no matter what happens, in
the morning the correct dates have been pulled
without the old ones lingering for too long.

* Better logging

* Made scan interval a timedelta

* Fix import order

* Update homeassistant/components/avri/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Update homeassistant/components/avri/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Use filter instead of break statement

* Use positive int for house number extension

* Switch voluptuous types for house number and house number extension

* Update homeassistant/components/avri/sensor.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Implement `available`

* Bump avri api

* Code review comments

* Replace `postcode` with `zip_code`

* Update logic for `available`

* Remove variable for delimiter

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-27 22:12:01 -08:00
Ziv
02c170b961 Dynalite listener for config entry update (#32116)
* added entry listener that reloads the component

* fixed update with existing entry

* fixed import in test

* fixes

* library version

* removed unique_id

* fix

* fixed for no entries in hass.data

* fixed return value on abort

* moved to use async_entries

* removed unused import
2020-02-27 22:05:55 -08:00
Raman Gupta
b9fa32444a Support vizio pairing through config flow (#31520)
* support pairing through config flow

* simplify import failure log messages

* remove unnecessary list comprehension

* bump pyvizio to add passing ClientSession in where it was missed

* show different message if user completes pairing through import

* remove dupe failure message since reasons for failure are the same in both instances

* remove extra constant

* add host reachability check during pairing workflow

* revert redundant connection check since check is implicitly done during pairing process

* fix rebase errors

* fix string

* updates based on review

* update docstring

* missed commit

* update import confirmation message to be less wordy

* use ConfigFlow _abort_if_unique_id_configured

* fix test
2020-02-27 22:04:59 -08:00
Aaron Bach
03d8abe1ba Fix unhandled exception in Ambient PWS_URL (#32238)
* Fix unhandled exception in Ambient PWS_URL

* Comment update

* Be more explicit
2020-02-27 21:40:51 -08:00
J. Nick Koston
0364cd8db5 Add usage sensors for each device sense detects that show powe… (#32206)
* init

* const

* update docs string

* update docs string

* restore binary sensors

* Restore binary sensors

* match name

* pylint

* Fix bug in conf migration

* Fix refactoring error

* Address review items

Imporve performance

* Fix devices never turning back off
2020-02-27 21:23:47 -08:00
Erik Montnemery
3b17e570df Add device actions to cover (#28064)
* Add device actions to cover

* Remove toggle action, improve tests

* lint

* lint

* Simplify actions

* Update homeassistant/components/cover/device_action.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Improve tests

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-27 21:05:43 -08:00
J. Nick Koston
223c01d842 Coordinate all august detail and activity updates (#32249)
* Removing polling from august

* Now using subscribers to the detail and activity

* Fix hash to list keys

* continue to the next house if one fails

* Add async_signal_device_id_update

* Fix double initial update

* Handle self.hass not being available until after async_added_to_hass

* Remove not needed await

* Fix regression with device name
2020-02-27 19:44:22 -08:00
Paulus Schoutsen
d51b2ad675 Merge pull request #32282 from home-assistant/rc
0.106.1
2020-02-27 16:37:35 -08:00
HomeAssistant Azure
fefbe02d44 [ci skip] Translation update 2020-02-28 00:31:47 +00:00
Aaron Bach
9329bc4ca0 Remove ability to configure monitored conditions in IQVIA (#32223)
* Remove ability to configure monitored conditions in IQVIA

* Deprecate instead of removing (until 0.108.0)

* Simplify imports

* Update version
2020-02-27 17:24:14 -07:00
Diogo Gomes
b8fbe758d8 Bump pyipma dependency (fixes bug in 0.106) (#32286)
* Bump version

* Bump PyIPMA version
2020-02-27 14:44:22 -08:00
Diogo Gomes
5bdf450f78 Bump pyipma dependency (fixes bug in 0.106) (#32286)
* Bump version

* Bump PyIPMA version
2020-02-27 14:44:02 -08:00
Paulus Schoutsen
61476f4f2c Fix dsmr test 2020-02-27 14:41:35 -08:00
Paulus Schoutsen
cab60bcd0c Bumped version to 0.106.1 2020-02-27 14:03:07 -08:00
Paulus Schoutsen
c0394232f3 Catch more Hue errors (#32275) 2020-02-27 14:03:00 -08:00
Robert Svensson
a5d9e89d08 deCONZ - Race condition on slower systems (#32274)
When battery sensors gets created before other platforms loading deconz sensors gets created first the other platform would not create entities related to those battery sensors
2020-02-27 14:02:59 -08:00
Aaron Bach
f43b26f250 Bump simplisafe-python to 9.0.2 (#32273) 2020-02-27 14:02:59 -08:00
Aaron Bach
58b32bbeff Bump simplisafe-python to 9.0.0 (#32215) 2020-02-27 14:02:58 -08:00
dupondje
6d0a465390 Fix DSMR 5 (#32233)
DSMR 5 was broken because some wrong if.
if dsmr_version in ("5B"):
-> this checks dsmr_version against 5 and B. Not if its 5B.
2020-02-27 14:00:51 -08:00
Jens Nistler
a5d334bbf7 Mark clients away if they have never been seen. (#32222) 2020-02-27 14:00:51 -08:00
Erik Montnemery
a77fd4892e Add missing translations for light actions (#32216) 2020-02-27 14:00:50 -08:00
Balazs Sandor
75e8d49af1 Show kernel version on linux (#32276) 2020-02-27 13:59:30 -08:00
Paulus Schoutsen
5a56d0ec1d Catch more Hue errors (#32275) 2020-02-27 12:53:36 -08:00
Jens Nistler
ecd076c5e4 Mark clients away if they have never been seen. (#32222) 2020-02-27 11:50:34 -08:00
Robert Svensson
e695bb55c8 deCONZ - Race condition on slower systems (#32274)
When battery sensors gets created before other platforms loading deconz sensors gets created first the other platform would not create entities related to those battery sensors
2020-02-27 20:48:01 +01:00
Aaron Bach
aab2fd5ec3 Bump simplisafe-python to 9.0.2 (#32273) 2020-02-27 12:18:26 -07:00
Yuki Ueda
0eb5ca67cd Make heos and transmission config flow tests more robust (#31783)
* async_step_user to async_configure

* fix for lint

* fix for pylint

* fix isort and black

* fix miss-fixed black

* fixing for the python37 coverage

* fix transmission definition

* fix for Black formatting

* fix type to abort

* clean up

* clean up for the test

* fix for the test

* refactor

* split test_flow_works to three tests

* revert the assert

* remove whitespaces for flake8

* apply patch function

* fix for the patch

* fix for the black

* remove mock_coro

* fix for the black

* hue to heos

* try to fix import

* fix for the black

* revert try to fix import

* Add a pytest fixture

* fix for the black
2020-02-27 12:19:54 +01:00
Aaron Bach
df04fe3258 Bump simplisafe-python to 9.0.0 (#32215) 2020-02-26 18:52:07 -08:00
J. Nick Koston
4c5e364d90 Centralize august activity updates (#32197)
* Reduce August doorbell detail updates

* Doorbell images now get updates from the activity feed

* Tests for activity updates

* py-august now provides bridge_is_online for available state

* py-august now provides is_standby for available state

* py-august now provides get_doorbell_image (eliminate requests)

* remove debug

* black after merge conflict

* Centralize august activity updates

* Updates appear significantly more responsive

* Should address the community complaints about "lag"

* Reduce detail updates (device end points) to one hour interval

* Signal entities to update via dispatcher when new activity arrives

* Resolves out of sync state (skipped test is now unskipped)

* pylint

* fix merge conflict

* review comments

* Remove stray

* Address review items that can be done without refactor
2020-02-26 18:48:44 -08:00
Jc2k
d207c37c33 Address homekit_controller feedback on #32212 and #32213 (#32228) 2020-02-26 17:10:05 -08:00
dupondje
f26826d949 Fix DSMR 5 (#32233)
DSMR 5 was broken because some wrong if.
if dsmr_version in ("5B"):
-> this checks dsmr_version against 5 and B. Not if its 5B.
2020-02-26 17:02:42 -08:00
Paulus Schoutsen
483d822272 Lovelace resource mgmt (#32224)
* Add websockets commands for resource management

* Add LL resource management

Co-authored-by: Bram Kragten <mail@bramkragten.nl>
2020-02-26 16:43:34 -08:00
HomeAssistant Azure
92988d60a7 [ci skip] Translation update 2020-02-27 00:31:50 +00:00
Franck Nijhof
16dba3fa85 Merge branch 'master' into dev 2020-02-26 21:01:29 +01:00
Paulus Schoutsen
2a88ae559e Improve debounce cooldown (#32161) 2020-02-26 11:27:37 -08:00
Jc2k
853d6cda25 Make homekit_controller a local push integration (#32213) 2020-02-26 10:35:53 -08:00
Erik Montnemery
c92aa30663 Add missing translations for light actions (#32216) 2020-02-26 10:24:43 -08:00
Jc2k
92a47f14bb homekit_controller test cleanups (#32212) 2020-02-26 09:44:04 -08:00
Franck Nijhof
2d68b37dd5 Merge pull request #32211 from home-assistant/rc
0.106.0
2020-02-26 14:30:57 +01:00
Paulus Schoutsen
4de3871a78 Fix hue test 2020-02-26 12:54:19 +01:00
Franck Nijhof
9c755d8fd4 Remove deprecated Hue options (fixes CI) (#32027) 2020-02-26 12:53:44 +01:00
Franck Nijhof
1e5f0a5136 Bumped version to 0.106.0 2020-02-26 12:34:38 +01:00
Bram Kragten
897433ecba Updated frontend to 20200220.4 (#32205) 2020-02-26 12:31:50 +01:00
Aaron Bach
89625010e5 Fix error where SimpliSafe websocket would disconnect and not reconnect (#32199)
* Fix error where SimpliSafe websocket would disconnect and not reconnect

* Await
2020-02-26 12:31:44 +01:00
Aaron Bach
e435f6eb67 Fix error where SimpliSafe websocket would disconnect and not reconnect (#32199)
* Fix error where SimpliSafe websocket would disconnect and not reconnect

* Await
2020-02-26 12:19:14 +01:00
Bram Kragten
5a67d73a37 Updated frontend to 20200220.4 (#32205) 2020-02-26 11:32:15 +01:00
J. Nick Koston
638a3025df Reduce August doorbell detail updates (#32193)
* Reduce August doorbell detail updates

* Doorbell images now get updates from the activity feed

* Tests for activity updates

* py-august now provides bridge_is_online for available state

* py-august now provides is_standby for available state

* py-august now provides get_doorbell_image (eliminate requests)

* remove debug

* black after merge conflict
2020-02-26 08:43:41 +01:00
Aaron Bach
b5c1afcb84 Make SimpliSafe entities unavailable when wifi is lost (#32154)
* Make SimpliSafe entities unavailable when wifi is lost

* Remove online status from REST API

* Comments

* Mispelling
2020-02-25 20:03:41 -07:00
J. Nick Koston
4c33a9d732 Add model to august device_info (#32187)
* Add model to august device_info

* Address review comments from PR#32125

* Fix test name
2020-02-25 18:34:31 -08:00
springstan
58de7fe9a3 Fix name of emby media player (#32183)
* Fix name of emby media player

* Remove client name from entity_id
2020-02-25 17:30:03 -08:00
HomeAssistant Azure
ed461a0ad8 [ci skip] Translation update 2020-02-26 00:31:47 +00:00
J. Nick Koston
3e702c8ca4 Add Config Flow for sense (#32160)
* Config Flow for sense

* Fix unique ids so they are actually unique (and migrate the old ones)

* Fix missing solar production

* Do not mark sensors available until they have data

* Address review items

* Address review round #2
2020-02-25 16:37:41 -07:00
Paulus Schoutsen
7391aa2d7e Bumped version to 0.106.0b5 2020-02-25 14:17:32 -08:00
Paulus Schoutsen
0e7e0086cd Update translations 2020-02-25 14:17:28 -08:00
Jenny
6f8380b442 Bump socialbladeclient to 0.5 (#32191) 2020-02-25 14:16:52 -08:00
Paulus Schoutsen
e60a6cfa19 Fix Arlo doing I/O in event loop (#32190) 2020-02-25 14:16:52 -08:00
Bram Kragten
ff6d415c67 Updated frontend to 20200220.3 (#32189) 2020-02-25 14:16:51 -08:00
Michaël Arnauts
d3629d9f32 Bump python-tado to 0.3.0 (#32186) 2020-02-25 14:16:50 -08:00
Kit Klein
61e2ce5faf Dedup and clarify imported konnected config flows (#32138)
* dedup config flows

* use default (imported) options until user goes thru options flow

* address pr feedback

* correct key used to distinguish pro model
2020-02-25 14:16:49 -08:00
Bram Kragten
b0fdbebd56 Updated frontend to 20200220.3 (#32189) 2020-02-25 23:15:25 +01:00
Paulus Schoutsen
fc0278c91f Fix Arlo doing I/O in event loop (#32190) 2020-02-25 23:10:43 +01:00
Jenny
1f23361a5d Bump socialbladeclient to 0.5 (#32191) 2020-02-25 23:01:18 +01:00
Jc2k
4a89fba6f9 Add homekit_controller occupancy sensor (#32188) 2020-02-25 22:01:03 +00:00
Jc2k
dd13e99967 Add missing device class attributes to homekit_controller sensors (#32175)
* Add some missing device class attributes to homekit_controller sensors

* Add classes for binary sensors
2020-02-25 21:43:14 +01:00
Michaël Arnauts
24652d82ab Bump python-tado to 0.3.0 (#32186) 2020-02-25 21:29:45 +01:00
Jc2k
1ddc1ebc6b Refactor away deprecated homekit_controller test helpers (#32177) 2020-02-25 21:19:04 +01:00
Paulus Schoutsen
7d8da47309 Revert "Use orjson to parse json faster (#32153)" (#32185)
This reverts commit 2365e2e8cf.
2020-02-25 21:07:16 +01:00
Franck Nijhof
ceb3985a99 Remove hide_entity property from automation integration (#32038)
* Remove hidden property from automation integration

* Allow configuration options untils 0.110
2020-02-25 11:21:05 -08:00
Paulus Schoutsen
536b31305a Support multiple Lovelace dashboards (#32134)
* Support multiple Lovelace dashboards

* Mark collection maintenance as unfinished

* Fix import

* Add websockets commands for resource management

* Revert "Add websockets commands for resource management"

This reverts commit 7d140b2bcc.

Co-authored-by: Bram Kragten <mail@bramkragten.nl>
2020-02-25 11:18:21 -08:00
Erik Montnemery
2d6b80470f Improve error handling (#32182) 2020-02-25 10:44:24 -08:00
Ruslan Sayfutdinov
2365e2e8cf Use orjson to parse json faster (#32153)
* [recorder] Use orjson to parse json faster

* Remove from http manifest

* Bump to orjson 2.5.1

* Empty commit to trigger CI

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-25 10:20:51 -08:00
springstan
5c12fa0daa Fix description of fan service set_direction (#32181) 2020-02-25 19:18:44 +01:00
J. Nick Koston
2925e0617c Add Config flow to august (#32133)
* Add battery sensors for August devices

* Additional tests and cleanup in prep for config flow
  and device registry

* pylint

* update name for new style guidelines - https://developers.home-assistant.io/docs/development_guidelines/#use-new-style-string-formatting

* Config Flow for august push

* Update homeassistant/components/august/__init__.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Address review items

* Update tests

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-25 10:18:15 -08:00
Paulus Schoutsen
900714a3ee Do not report state when closing down (#32168) 2020-02-25 09:05:36 -08:00
Kit Klein
5488389244 Dedup and clarify imported konnected config flows (#32138)
* dedup config flows

* use default (imported) options until user goes thru options flow

* address pr feedback

* correct key used to distinguish pro model
2020-02-25 13:55:06 +01:00
Jc2k
438c4acf07 Deprecate homekit_controller .homekit folder (#32158)
* homekit_controller: Deprecate .homekit folder

* Tweaks from review

* Delay it a release
2020-02-25 12:09:04 +01:00
Jc2k
c9d78aa78c Refactor homekit_controller config flow tests (#32141)
* Config flow test refactor

* Add a service and characteristic to the accessory so its more realistic

* Feedback from review

* Missing apostrophe
2020-02-25 12:06:35 +01:00
Aaron Bach
ba4cc373c8 Modernize Ambient PWS config flow (#32164)
* Modernize Ambient PWS config flow

* Linting
2020-02-24 21:37:38 -08:00
Aaron Bach
c97b1c60b0 Modernize Notion config flow (#32167)
* Modernize Notion config flow

* Linting
2020-02-24 21:36:58 -08:00
paolog89
0e6a48c688 Add observed entities to bayesian sensor (#27721)
* Add observed entities to bayesian sensor

* Update binary_sensor.py to comply with style guidelines and test_binary_sensor.py to verify the entity_id

* Update binary_sensor.py and test_binary_sensor.py to include an additional attribute for observed entities

* Use of ATTR_ENTITY_ID and numeric key of observed entity

* Update binary_sensor.py

* Update test_binary_sensor.py to verify behavior

* Update to return a list without duplicates in the state attribute

* Update binary_sensor.py: rename of ATTR_ENTITY_ID into ATTR_OBSERVED_ENTITIES

* Rename new attribute into ATTR_OCCURRED_OBSERVATION_ENTITIES and fix test
2020-02-24 21:27:59 -08:00
Paulus Schoutsen
5776b9f17d Fix flaky coverage in UK transport test (#32053) 2020-02-24 21:27:07 -08:00
Paulus Schoutsen
9007d37de1 Bumped version to 0.106.0b4 2020-02-24 21:05:10 -08:00
Aaron Bach
7c2765fbff Remove unused SimpliSafe config flow function (#32166)
* Remove unused SimpliSafe config flow function

* Code review comments from other PR

* Linting
2020-02-24 22:02:20 -07:00
Aaron Bach
75f465bf7e Remove unused RainMachine config flow function (#32165)
* Remove unused RainMachine config flow function

* Remove test we don't need

* Code review comments

* Linting
2020-02-24 22:01:55 -07:00
Erik Montnemery
7e387f93d6 Add MQTT WS command to remove device (#31989)
* Add MQTT WS command to remove device

* Review comments, fix test

* Fix tests
2020-02-24 20:46:02 -08:00
Paulus Schoutsen
9e832aaaa6 Bumped version to 0.106.0b3 2020-02-24 19:36:26 -08:00
Raman Gupta
5dc93aeeb1 Improve Vizio fix to avoid KeyError (#32163)
* dont set default volume_step on import check

* ensure config entry data['volume_step'] is set

* consolidate entry update during entry setup
2020-02-24 19:36:15 -08:00
Raman Gupta
45d63e22d5 Fix vizio bug to use 'get' to get volume_step since it is optional (#32151)
* use get to get volume_step since it is optional

* always set volume_step to default in options and data if its not included
2020-02-24 19:36:14 -08:00
Paulus Schoutsen
6edef444a7 Properly define depenency for Scrape integration on Rest integ… (#32136) 2020-02-24 19:36:14 -08:00
Kit Klein
6f1f9bdd45 0.106 Beta - provide correctly formatted placeholders (#32119) 2020-02-24 19:36:13 -08:00
Tom
1d075a7dd0 Fix Plugwise climate issues for new firmware #32080 (#32109)
* Fix Plugwise climate issue firmare 3.1.11 (#32080)

* Submit checklist actions
2020-02-24 19:36:12 -08:00
Raman Gupta
4236d62b44 Improve Vizio fix to avoid KeyError (#32163)
* dont set default volume_step on import check

* ensure config entry data['volume_step'] is set

* consolidate entry update during entry setup
2020-02-24 19:35:28 -08:00
Mike
71a6ea1c10 Add shopping_list_item_added event_type (#28334)
* Update __init__.py

Added event_type "shopping_list_item_added" with an item tied to it.

* Update __init__.py

* Update __init__.py

Black formatting style

* Modified global event variables

* Typo fix

* Update __init__.py

* Formatting changes

* More formatting changes

* Update __init__.py

* Black formatting

* Update __init__.py

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-24 18:43:27 -08:00
SukramJ
e0586df602 Migrate HomematicIP Cloud services to admin services (#32107)
* Migrate HomematicIP Cloud services to admin services

* remove unused dict

* vacation and eco mode are usable by users

* add verify_domain_control, make service user accessible
2020-02-24 18:16:57 -08:00
springstan
88df9c8ab4 Remove friendly_name attribute from twitch sensor (#32067)
* Remove friendly_name attribute twitch sensor

* Use deepcopy to only copy the content

* Update homeassistant/components/twitch/sensor.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Update homeassistant/components/twitch/sensor.py

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-25 02:55:31 +01:00
springstan
ad102b3840 Use f-strings in integrations starting with "F"and"G" (#32150)
* Use f-strings in integrations starting with F

* Use f-strings in tests for integrations starting with F

* Use f-strings in integrations starting with G

* Use f-strings in tests for integrations starting with G

* Fix pylint error

* Fix broken test
2020-02-24 17:54:20 -08:00
Ville Skyttä
496bd3dddf Add and use more unit constants (#32122)
* Add and use speed constants

* Add and use meter based volume and area constants

* Add and use more mass unit constants

* Add and use concentration unit constants

* Add and use watts per square meter constant

* Use more time constants

* Use more data constants
2020-02-24 17:52:14 -08:00
Franck Nijhof
c98f50115d Upgrade pre-commit to 2.1.1 (#32159) 2020-02-25 02:16:23 +01:00
Ville Skyttä
9b2544c923 Remove some unneeded pylint suppressions (#32152) 2020-02-24 16:47:15 -08:00
HomeAssistant Azure
a9e061270b [ci skip] Translation update 2020-02-25 00:32:13 +00:00
Chris Talkington
3f49f6c047 Add constants file for directv (#32157) 2020-02-25 01:30:00 +01:00
Phil Bruckner
b2d7bc40dc Add support for simultaneous runs of Script helper (#31937)
* Add tests for legacy Script helper behavior

* Add Script helper if_running and run_mode options

- if_running controls what happens if Script run while previous run
  has not completed. Can be:
  - error: Raise an exception
  - ignore: Return without doing anything (previous run continues as-is)
  - parallel: Start run in new task
  - restart: Stop previous run before starting new run
- run_mode controls when call to async_run will return. Can be:
  - background: Returns immediately
  - legacy: Implements previous behavior, which is to return when done,
            or when suspended by delay or wait_template
  - blocking: Returns when run has completed
- If neither is specified, default is run_mode=legacy (and if_running
  is not used.) Otherwise, defaults are if_running=parallel and
  run_mode=background. If run_mode is set to legacy then if_running must
  be None.
- Caller may supply a logger which will be used throughout instead of
  default module logger.
- Move Script running state into new helper classes, comprised of an
  abstract base class and two concrete clases, one for legacy behavior
  and one for new behavior.
- Remove some non-async methods, as well as call_from_config which has
  only been used in tests.
- Adjust tests accordingly.

* Change per review

- Change run_mode default from background to blocking.
- Make sure change listener is called, even when there's an unexpected
  exception.
- Make _ScriptRun.async_stop more graceful by using an asyncio.Event for
  signaling instead of simply cancelling Task.
- Subclass _ScriptRun for background & blocking behavior.

Also:

- Fix timeouts in _ScriptRun by converting timedeltas to float seconds.
- General cleanup.

* Change per review 2

- Don't propagate exceptions if call from user has already returned
  (i.e., for background runs or legacy runs that have suspended.)
- Allow user to specify if exceptions should be logged. They will still
  be logged regardless if exception is not propagated.
- Rename _start_script_delay and _start_wait_template_delay for
  clarity.
- Remove return value from Script.async_run.
- Fix missing await.
- Change call to self.is_running in Script.async_run to direct test of
  self._runs.

* Change per review 3 and add tests

- Remove Script.set_logger().
- Enhance existing tests to check all run modes.
- Add tests for new features.
- Fix a few minor bugs found by tests.
2020-02-24 14:56:00 -08:00
Raman Gupta
309989be89 Fix vizio bug to use 'get' to get volume_step since it is optional (#32151)
* use get to get volume_step since it is optional

* always set volume_step to default in options and data if its not included
2020-02-24 23:37:54 +01:00
Colin O'Dell
90859b82e2 Upgrade qnapstats to 0.3.0 (#32148) 2020-02-24 22:46:07 +01:00
Aaron Bach
6b0d7c77f0 Clean up RainMachine config entry data (#32132) 2020-02-24 13:07:18 -07:00
Aaron Bach
edf44f4158 Modernize RainMachine config flow (#32131)
* Modernize RainMachine config flow

* Update strings
2020-02-24 13:05:54 -07:00
Aaron Bach
f7e336eaa6 Modernize SimpliSafe config flow (#32130)
* Modernize SimpliSafe config flow

* Fix tests
2020-02-24 13:03:08 -07:00
Aaron Bach
db40b2fc32 Handle unhandled IQVIA data update exception (#32144)
* Handle unhandled IQVIA data update exception

* Cleanup

* Ask for forgiveness, not permission

* Use warning-level logs

* Fix log messages
2020-02-24 13:02:33 -07:00
springstan
9801810552 Use f-strings in integrations starting with "B"-"E" (#32121)
* Use f-strings in integrations starting with B

* Use f-strings in integrations starting with C

* Use f-strings in integrations starting with D

* Use f-strings in integrations starting with E

* Fix pylint errors

* Fix pylint errors v2

* Fix tests

* Fix tests v2
2020-02-24 08:47:52 -08:00
Paulus Schoutsen
07fa844c43 Speed up validate_entity_id (#32137)
* Speed up validate_entity_id

* Add some more invalid entity IDs

* Adjust regular expression

* Extend and sort test cases

* Update regular expression, more cases, faster

* Adjust tests, allow start with number, disallow double underscore

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2020-02-24 08:35:02 -08:00
Ruslan Sayfutdinov
15b4975681 Use ciso8601 library to parse datetime faster (#32128) 2020-02-24 08:33:10 -08:00
Rocik
d996a4a9a9 Add Supla gate (#31643)
* Add support for Supla gate with sensor

* Fix Supla switch module description and state access

* Add docs to methods of Supla gate

* Add missing comma

* Remove unused import

* Sort imports of Supla cover

* Add returning availability for every Supla device

* Use direct access to dict

* Remove deprecated property "hidden"

* Remove unused constant

* Revert using get function on dict
2020-02-24 15:34:53 +01:00
Jc2k
df9363610c Refactor homekit_controller to be fully asynchronous (#32111)
* Port homekit_controller to aiohomekit

* Remove succeed() test helper

* Remove fail() test helper
2020-02-24 10:55:33 +01:00
Pierre
a1a835cf54 Add platform Ezviz (#30378)
* hookid : isort fix

* New platform: Ezviz

* updated CODEOWNERS for ezviz

* proper test requirements

* resolved conflict

* regenerated requirements

* removed stale comments, only one call to add_entities, removed unnecessary attributes

* setup is sync, not async. Removed stale comments

* Compatible with pyezviz 0.1.4

* pyezviz 0.1.4 is now requiredf

* Added PTZ + switch management

* added services.yaml

* proper requirement

* PTZ working in async mode

* Now updates the entity

* Compatible with pyezviz 0.1.5.1

* Fixed switch ir service registering

* now requires pyezviz 0.1.5.2

* now requires pyezviz 0.1.5.2

* Revert "regenerated requirements"

This reverts commit 848b317cf9.

* Rollbacked to a simpler version

* snake_case names everywhere, logging sanatizing, voluptuous proper check

* pyezviz 0.1.5, reworked the PR so that it's intelligible

* no need for services.yaml for now

* proper voluptuous validation

* Removed stale code, use proper conf variable, describe attributes

* regenerated requirements

* stale

* removed status from attributes, since we use it for available we don't need it here then.

* Fixed log message
2020-02-24 10:39:55 +01:00
Paulus Schoutsen
ca01e9a537 Improve condition validation error msg (#32135) 2020-02-24 09:59:34 +01:00
Paulus Schoutsen
270758417b Properly define depenency for Scrape integration on Rest integ… (#32136) 2020-02-24 00:03:33 -08:00
Aaron Bach
6e6625e1ab Remove no-longer-needed SimpliSafe websocket watchdog (#32129)
* Fix SimpliSafe reconnection issue upon websocket error

* Rename listener cancelation properties

* Remove watchdog
2020-02-23 20:47:19 -07:00
HomeAssistant Azure
5ec7d07283 [ci skip] Translation update 2020-02-24 00:31:49 +00:00
J. Nick Koston
693441e56f Deduplicate code in the august integration (#32101)
* Deduplicate code in the august integration

* Add additional tests for august (more coming)

* Door state is now updated when a lock or unlock call returns
  as the state is contained in the response which avoids
  the confusing out of sync state

* revert

* document known issue with doorsense and lock getting out of sync (pre-existing)

* Address review comments

* Additional review comments
2020-02-23 13:54:34 -08:00
Kit Klein
d2d788631e 0.106 Beta - provide correctly formatted placeholders (#32119) 2020-02-23 13:54:18 -08:00
springstan
524a1a7587 Use f-strings in integrations starting with "A" (#32110)
* Use f-strings in integrations starting with A

* Use f-strings in tests for integrations starting with A

* Fix pylint by renaming variable

* Fix nested for loop in f-string for aprs device_tracker

* Break long lines into multiple short lines

* Break long lines into multiple short lines v2
2020-02-23 13:38:05 -08:00
springstan
a85808e325 Add and use time related constants (#32065)
* Add and use time related constants

* Sort time constants and reuse them in data rate constants

* Fix greeneyemonitor import

* Fix greeneyemonitor import V2

* Fix failing here_travel_time test

* Add TIME_MONTHS and TIME_YEARS

* Use TIME_MINUTES in opentherm_gw and isy994

* Add and use TIME_MILLISECONDS

* Change inconsistent ones

* Add TIME_MICROSECONDS and TIME_WEEKS

* Use constants in apcupsd and travisci

* Fix import error in upnp sensor.py

* Fix isy994 sensor.py using TIME_YEARS

* Fix dyson tests

* Use TIME_SECONDS in more places

* Use TIME_DAYS in google wifi
2020-02-23 22:09:24 +02:00
Chris Talkington
8dd80e0e3c Add unique_id to directv entities (#31838)
* add unique_id to directv entities.

* add addiitional debug and fix tests.

* fix lint error.

* rework unique_id and flow a bit.

* review adjustments.

* review adjustments

* review adjustments

* review adjustments.

* review adjustments

* review adjustments

* review adjustments

* review adjustments

* lint

* use serial number for host unit and mac address for client units

* fix elsif

* update test with realistic client id

* lint
2020-02-23 19:26:34 +01:00
Robert Svensson
1007283da5 UniFi - Add unit of measurement to bandwidth sensors (#32114) 2020-02-23 19:17:26 +01:00
Robin
4cc4f070f5 Add sighthound save image (#32103)
* Adds save_image

* Update test_image_processing.py

* Update test

* Tidy test

* update image_processing with reviewer comments

* Update test_image_processing.py

* Ammend tests

not passing

* Patch convert

* remove join

* Use valid_config_save_file
2020-02-23 19:11:05 +01:00
Martin Long
f6fbecf963 Add boost support for Hive TRVs (#31261)
* Add boost support for TRVs

* Updated pyhiveapi dependency to 0.2.20.1
2020-02-23 17:40:50 +01:00
jezcooke
a533b7a746 Fix volume control for Frontier Silicon media players (#32040)
* Fixed volume control for Frontier Silicon media players.

* Removed unnecessary else which caused pylint test to fail.

* Removed whitespace on empty line.

* Tweaks from on springstan's suggestions and other fixes

* Apply suggestions from code review

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Comment to explain why 1 is subtracted from volume_Steps

Also reformatted using black after code review changes.

* Split up the set volume functions into steps rather than all in-line as suggested.

* Renamed _volume_steps to _max_volume.

* Prevent asnyc_update from failing if we can't get the volume steps

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-02-23 17:37:31 +01:00
jezcooke
458e47f981 Add name option for Frontier Silicon devices (#32085)
* Added the option to specify the name of the device in confirguration.yaml

* Adding missing default name parameter in auto-discovery FSAPIDevice constructor.

* Fixed Black formatting.

* Removed DEFAULT_NAME constant.

* Apply suggestions from code review

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-02-23 17:05:24 +01:00
Tom
d22ee7179d Fix Plugwise climate issues for new firmware #32080 (#32109)
* Fix Plugwise climate issue firmare 3.1.11 (#32080)

* Submit checklist actions
2020-02-23 17:02:42 +01:00
Paulus Schoutsen
f975654ae7 Mock setup_entry in oauth2 tests (#32102)
* Mock setup_entry in oauth2 tests

* Fix scaffold constant
2020-02-23 12:23:21 +01:00
jezcooke
a678c6fd0b Fix Frontier Silicon player state (#32082)
The player would report itself as ‘off’ when in certain modes (e.g ‘Music player’ or ‘Spotify’) which meant HA would lose all control (it can’t change input or set volume etc. as it thinks it’s off). Now reports STATE_IDLE in these cases and only STATE_OFF if it is actually off.

This fixes issue #20728.
2020-02-22 20:33:42 -08:00
michaeldavie
bd00453cef Bump env_canada to 0.0.35 to address issue 31924 (#32077)
* Bump env_canada to 0.0.35, remove details from alerts

* Black
2020-02-22 20:32:19 -08:00
HomeAssistant Azure
8257165562 [ci skip] Translation update 2020-02-23 00:31:50 +00:00
Bram Kragten
fcaabb3d33 Change get_entity to return a extended entry, add inputs to de… (#32083)
* Change get_entity to return a extended entry + add inputs to default config

For https://github.com/home-assistant/home-assistant-polymer/pull/4940

* Fix tests, simplify code, update to return extended

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-22 15:18:10 -08:00
Franck Nijhof
edfb967b10 Add unique ID to ONVIF camera entities (#32093) 2020-02-22 22:29:49 +01:00
Paulus Schoutsen
e78449904b Bumped version to 0.106.0b2 2020-02-21 17:38:43 -08:00
jjlawren
f30ff31439 Add ConfigEntryNotReady exception to Plex (#32071) 2020-02-21 17:38:29 -08:00
Alok Saboo
9dda44ffdd Add additional logging to rest sensor (#32068) 2020-02-21 17:38:28 -08:00
Maciej Bieniek
39fd7ca5d3 Bump brother to 0.1.6 (#32054) 2020-02-21 17:38:27 -08:00
Paulus Schoutsen
ca07ae5b1e Updated frontend to 20200220.1 (#32046) 2020-02-21 17:38:26 -08:00
J. Nick Koston
cc8430ebed Fix i/o in august camera async image update (#32044)
* Fix i/o in august camera image update

* Address review comments
2020-02-21 17:38:25 -08:00
Paulus Schoutsen
a3b3ff52fc Remove YAML config from Ring integration (#32039) 2020-02-21 17:38:24 -08:00
Ziv
a102728997 Enhance Dynalite Integration after review (#31760)
* fixes per Martin Hjelmare

* pylint fix

* final fixes per request

* fixed unit tests for new config flow

* Added unit-tests to increase coverage. at 97% now

* Added unit tests for 100% coverage of component

* removed configured_host function and updated config_flow unit tests

* added a pylint directive since it tells me by mistake DOMAIN is not used

* fixed path (removed __init__)

* Update homeassistant/components/dynalite/light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/dynalite/light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* fixed the test as we moved from schedule_update_... to async_schedule

* Update homeassistant/components/dynalite/bridge.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* removed context from config_flow
changed test_init to use the core methods

* moved test_light to also use the core interfaces

* moved to config_entries.async_unload

* additional fixes for the tests

* pylint fix and removed unnecessary code

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* added break in loop

* removed last mock_coro reference
pylint fix

* added coverage for try_connect

* added check for a successful connection before bridge.async_setup succeeds
also added a "nowait" config option (default False) that avoids this check

* changed log level

* fixed accidental chmod I did

* fixed accidental change

* not storing config in bridge

* not patching asyncio

* moved CONFIG_SCHEMA into component

* moved all logs to start capitalized (and revised some of them)

* moved test_config_flow to not patch the DynaliteBridge

* also took DynaliteBridge patching out of test_init

* removed NO_WAIT

* fixes to SCHEMA

* changed _ in multi-word CONF
moved imports to component const.py

* removed tries

* removed redundant tests

* fixed some small change i broke in the library. only version update

* fixed rewuirements

* Update tests/components/dynalite/test_config_flow.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_config_flow.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* removed HIDDEN_ENTITY
removed hass in test fixture

* black fixes

* removed final piece of hidden_entity from light
fix in the library
updated config flow so if the entry is already set but with a different config, calls async_update_entry

* removed DATA_CONFIGS - no longer necessary

* pylint fixes

* added coverage

* use abort in config_flow

* test update

* removed logs

* test that update actually updates the entry

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-02-21 17:38:23 -08:00
Paulus Schoutsen
ced870c588 Remove YAML config from Ring integration (#32039) 2020-02-21 17:36:19 -08:00
HomeAssistant Azure
dc15b9c28e [ci skip] Translation update 2020-02-22 00:31:49 +00:00
springstan
b41cbe9885 Add www. to all documentation links (#32063)
* Add www. to all documentation links

* Fix broken redirect uri test
2020-02-21 16:10:02 -08:00
Alexei Chetroi
3385893b77 ZHA device channel refactoring (#31971)
* Add ZHA core typing helper.
* Add aux_channels to ZHA rule matching.
* Add match rule claim_channels() method.
* Expose underlying zigpy device.
* Not sure we need this one.
* Move "base" channels.
* Framework for channel discovery.
* Make DEVICE_CLASS and REMOTE_DEVICE_TYPE default dicts.
* Remove attribute reporting configuration registry.
* Refactor channels.
- Refactor zha events
- Use compound IDs and unique_ids
- Refactor signal dispatching on attribute updates

* Use unique id compatible with entities unique ids.
* Refactor ZHA Entity registry.
Let match rule to check for the match.

* Refactor discovery to use new channels.
* Cleanup ZDO channel.
Remove unused zha store call.

* Handle channel configuration and initialization.
* Refactor ZHA Device to use new channels.
* Refactor ZHA Gateway to use new discovery framework.
Use hass.data for entity info intermediate store.

* Don't keep entities in hass.data.
* ZHA gateway new discovery framework.
* Refactor ZHA platform loading.
* Don't update ZHA entities, when restoring from zigpy.
* ZHA entity discover tests.
* Add AnalogInput sensor.
* Remove 0xFC02 based entity from Keen smart vents.
* Clean up IAS channels.
* Refactor entity restoration.
* Fix lumi.router entities name.
* Rename EndpointsChannel to ChannelPool.
* Make Channels.pools a list.
* Fix cover test.
* Fix FakeDevice class.
* Fix device actions.
* Fix channels typing.
* Revert update_before_add=False
* Refactor channel class matching.
* Use a helper function for adding entities.
* Make Pylint happy.
* Rebase cleanup.
* Update coverage for ZHA device type overrides.
* Use cluster_id for single output cluster registry.
* Remove ZHA typing from coverage.
* Fix tests.
* Address comments.
* Address comments.
2020-02-21 18:06:57 -05:00
Ziv
36db302cc8 Enhance Dynalite Integration after review (#31760)
* fixes per Martin Hjelmare

* pylint fix

* final fixes per request

* fixed unit tests for new config flow

* Added unit-tests to increase coverage. at 97% now

* Added unit tests for 100% coverage of component

* removed configured_host function and updated config_flow unit tests

* added a pylint directive since it tells me by mistake DOMAIN is not used

* fixed path (removed __init__)

* Update homeassistant/components/dynalite/light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/dynalite/light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* fixed the test as we moved from schedule_update_... to async_schedule

* Update homeassistant/components/dynalite/bridge.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* removed context from config_flow
changed test_init to use the core methods

* moved test_light to also use the core interfaces

* moved to config_entries.async_unload

* additional fixes for the tests

* pylint fix and removed unnecessary code

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* added break in loop

* removed last mock_coro reference
pylint fix

* added coverage for try_connect

* added check for a successful connection before bridge.async_setup succeeds
also added a "nowait" config option (default False) that avoids this check

* changed log level

* fixed accidental chmod I did

* fixed accidental change

* not storing config in bridge

* not patching asyncio

* moved CONFIG_SCHEMA into component

* moved all logs to start capitalized (and revised some of them)

* moved test_config_flow to not patch the DynaliteBridge

* also took DynaliteBridge patching out of test_init

* removed NO_WAIT

* fixes to SCHEMA

* changed _ in multi-word CONF
moved imports to component const.py

* removed tries

* removed redundant tests

* fixed some small change i broke in the library. only version update

* fixed rewuirements

* Update tests/components/dynalite/test_config_flow.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_light.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/dynalite/test_config_flow.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

* removed HIDDEN_ENTITY
removed hass in test fixture

* black fixes

* removed final piece of hidden_entity from light
fix in the library
updated config flow so if the entry is already set but with a different config, calls async_update_entry

* removed DATA_CONFIGS - no longer necessary

* pylint fixes

* added coverage

* use abort in config_flow

* test update

* removed logs

* test that update actually updates the entry

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-02-21 23:29:59 +01:00
jjlawren
9cc47ca737 Add ConfigEntryNotReady exception to Plex (#32071) 2020-02-21 22:07:26 +01:00
Alok Saboo
2fb66fd866 Add additional logging to rest sensor (#32068) 2020-02-21 21:11:25 +01:00
Patrick Kishino
f32411e394 Add asuswrt interface and dnsmasq location configuration (#29834)
* Added interface and dnsmasq location configuration

* Updated aioasuswrt requirement to latest 1.2.1 release

* Updated to working aioasus library and fixed correct conf formatting
2020-02-21 17:01:57 +01:00
Maciej Bieniek
dd8597cb46 Bump brother to 0.1.6 (#32054) 2020-02-21 10:32:48 +01:00
J. Nick Koston
6e74ee7b64 Fix i/o in august camera async image update (#32044)
* Fix i/o in august camera image update

* Address review comments
2020-02-21 07:39:07 +01:00
J. Nick Koston
d4075fb262 Significantly reduce code in august integration (#32030)
* Significantly reduce code in august integration

* Activity updates can now be processed by py-august
  this allows us to eliminate the activity sync
  code for the door sensors and locks

* Lock and door state can now be consumed from
  the lock detail api which allows us to
  remove the status call apis and reduce
  the number of API calls to august

* Refactor the testing method for locks (part #1)

* Update homeassistant/components/august/binary_sensor.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Switch to asynctest instead of unittest for mock.patch

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-20 21:06:24 -08:00
HomeAssistant Azure
a12c4da0ca [ci skip] Translation update 2020-02-21 00:33:51 +00:00
springstan
1ee7c483a7 Update file headers and outdated documentation links (#32022)
* Update documentation links

* Update file headers v2
2020-02-20 15:29:46 -08:00
Paulus Schoutsen
51b5796916 Updated frontend to 20200220.1 (#32046) 2020-02-20 14:51:27 -08:00
Robbie Trencheny
f0d58ab7a7 Change TTS codeowner to @pvizeli (#32041) 2020-02-20 13:36:36 -08:00
Paulus Schoutsen
ce710f1e0b Template platform tweaks (#32037)
* Remove unnecessary boolean return from platform setup

* Fix template cover validation
2020-02-20 12:14:31 -08:00
Franck Nijhof
2e35190aff Fix extra arguments of group integration (#32032) 2020-02-20 20:15:45 +01:00
Paulus Schoutsen
fbe7ec7b11 Bumped version to 0.106.0b1 2020-02-20 11:02:23 -08:00
Paulus Schoutsen
b2310d6341 Updated frontend to 20200220.0 (#32033) 2020-02-20 11:02:04 -08:00
Franck Nijhof
fdd0becd5f Add minimal version contrain to urllib3 (#32031) 2020-02-20 11:02:03 -08:00
MatthewFlamm
425e6b2b1f Add missing name to logging in DataUpdateCoordinator (#32023) 2020-02-20 11:02:03 -08:00
cgtobi
f58e5a2185 Bump pyatmo to 3.2.4 (#32018)
* Bump pyatmo to 3.2.3

* Bump pyatmo version to 3.2.4

* Update requirements_test_all.txt
2020-02-20 11:02:02 -08:00
Tsvi Mostovicz
2fb6bb2a92 Don't return coroutine in DLNA/DMR service handler (#32011)
Fixes #32010
2020-02-20 11:02:01 -08:00
Paulus Schoutsen
35e9b52e2e Fix recursion bug (#32009)
* Fix recursion bug

* Remove shield
2020-02-20 11:02:00 -08:00
Mark Coombes
1e52dd5945 Fix bug in ecobee integration (#32008)
* Bump python-ecobee-api to 0.2.1

* Update log messages for clarity

* Update requirements_all
2020-02-20 11:01:59 -08:00
David F. Mulcahey
bf92b3099d Bump ZHA quirks and add skip configuration support (#31982)
* add skip configuration
* Bump quirks
* add skip configuration to FakeDevice
2020-02-20 11:01:58 -08:00
jjlawren
16f094d4d3 Fix Plex sensor title handling (#31973)
* Fix Plex sensor title parsing

* Revert episode year for now
2020-02-20 11:01:57 -08:00
Paulus Schoutsen
1b2bb87566 Only check frontend for safe mode if frontend wanted to be loa… (#31969)
* Only check frontend for safe mode if frontend wanted to be loaded

* Update test
2020-02-20 11:01:57 -08:00
Paulus Schoutsen
20e3c91ebd Updated frontend to 20200220.0 (#32033) 2020-02-20 11:01:20 -08:00
Franck Nijhof
bf1092ec80 Add minimal version contrain to urllib3 (#32031) 2020-02-20 19:19:09 +01:00
Franck Nijhof
b2f2afaf0c Prevent committing to dev/master/rc directly (#32029)
* Prevent committing to dev/master/rc directly

* Skip pre-commit on version bump
2020-02-20 09:34:30 -08:00
Franck Nijhof
1c81e8ad68 Remove history_graph integration (#32028)
* Remove history_graph integration

* Update codeowners file
2020-02-20 09:01:29 -08:00
Paulus Schoutsen
1c2bce9292 Fix recursion bug (#32009)
* Fix recursion bug

* Remove shield
2020-02-20 08:51:00 -08:00
Franck Nijhof
5c5f839119 Remove weblink integration (#32024) 2020-02-20 08:50:40 -08:00
Robin
a7d5e898ba Add convert_to_pil_image to pil util (#31825)
* Update pil.py

* Update doods and tensorflow to use convert_to_pil_image

* Update pil.py

* Add log messages on bad data

* Drop convert_to_pil_image

Just perform conversion in the integrations without seperate convert_to_pil_image()
2020-02-20 17:50:28 +01:00
Raman Gupta
7a6b13cb0d Update vizio dependency and integration name (#31975)
* bump pyvizio version and clean up code

* fix requirements

* update parameter to optional per review in docs PR
2020-02-20 08:43:29 -08:00
Paulus Schoutsen
51b2d0b4f8 Add entity ID to input_number warning (#32012)
* Add entity ID to warning

* Input Number flexibility
2020-02-20 08:30:24 -08:00
Franck Nijhof
2ad1f7fd02 Remove states UI options in group integration (#32021) 2020-02-20 08:26:41 -08:00
cgtobi
7e3841e172 Bump pyatmo to 3.2.4 (#32018)
* Bump pyatmo to 3.2.3

* Bump pyatmo version to 3.2.4

* Update requirements_test_all.txt
2020-02-20 08:25:49 -08:00
Franck Nijhof
2ec0a504da Remove deprecated Hue options (fixes CI) (#32027) 2020-02-20 17:18:50 +01:00
Paulus Schoutsen
e71c7e1f5e Fix hue test 2020-02-20 08:11:27 -08:00
MatthewFlamm
6c9d4a6d15 Add missing name to logging in DataUpdateCoordinator (#32023) 2020-02-20 16:51:15 +01:00
Franck Nijhof
d6c185fdf4 Deprecate Xfinity Gateway integration (ADR-0004) (#32017) 2020-02-20 16:01:03 +01:00
Franck Nijhof
aae64dba62 Bumped version to 0.107.0dev0 2020-02-20 11:44:00 +01:00
Franck Nijhof
febd7e551b Upgrade requests to 2.23.0 (#32013) 2020-02-20 11:41:13 +01:00
jjlawren
047111b00f Fix Plex sensor title handling (#31973)
* Fix Plex sensor title parsing

* Revert episode year for now
2020-02-19 22:33:38 -08:00
Daniel Perna
136ed12ec5 Update pyhomematic to 0.1.65 (#32006) 2020-02-19 22:27:50 -08:00
Tsvi Mostovicz
b6d60c36a5 Don't return coroutine in DLNA/DMR service handler (#32011)
Fixes #32010
2020-02-19 22:21:09 -08:00
Mark Coombes
832337f26c Fix bug in ecobee integration (#32008)
* Bump python-ecobee-api to 0.2.1

* Update log messages for clarity

* Update requirements_all
2020-02-19 21:05:22 -08:00
HomeAssistant Azure
5839df39b5 [ci skip] Translation update 2020-02-20 00:31:46 +00:00
Pascal Vizeli
6f8f23238a Nuki: add support for unique id (#31824)
* Nuki support unique id and the battery level attribute

* Fix isort

* Address comments

* Cache attribute

* Cleanup

* Restore false

* Fix isort
2020-02-19 08:16:02 -08:00
Paulus Schoutsen
4e765398cc Only check frontend for safe mode if frontend wanted to be loa… (#31969)
* Only check frontend for safe mode if frontend wanted to be loaded

* Update test
2020-02-19 15:56:46 +01:00
David F. Mulcahey
8255bdf3d5 Bump ZHA quirks and add skip configuration support (#31982)
* add skip configuration
* Bump quirks
* add skip configuration to FakeDevice
2020-02-19 09:19:26 -05:00
Franck Nijhof
e6258ec009 Merge branch 'dev' into rc 2020-02-19 13:22:32 +01:00
Bram Kragten
e90d29ea36 Updated frontend to 20200219.0 (#31979) 2020-02-19 12:46:40 +01:00
SukramJ
da4c08de12 Fix test for HMIPC (#31981) 2020-02-19 12:41:14 +01:00
SukramJ
0d874902cc Add shutter group to HomematicIP Cloud (#31916) 2020-02-19 10:59:49 +01:00
SukramJ
f4f01cb23a Add new devices to HomematicIP Cloud (#31914)
* Add new devices to HomematicIP Cloud

Adds:
- HMIP-WTH-B (Wall Thermostat Basic)
- ALPHA-IP-RBG (Alpha IP Wall Thermostat Display)
- ALPHA-IP-RBGa (ALpha IP Wall Thermostat Display analog)

* Update homeassistant/components/homematicip_cloud/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-02-19 10:43:12 +01:00
springstan
21f8d0a80c Bump vallox-websocket-api to 2.4.0 (#31913) 2020-02-19 10:01:21 +01:00
Vladimír Záhradník
32cd58e03d Modbus remove unnecessary get calls (#31966) 2020-02-18 19:41:12 -08:00
Gerard
0dad2f8e41 Upgrade to bimmer_connected 0.7.1 to fix US and China access (#31968) 2020-02-18 19:40:34 -08:00
jjlawren
56c834b8a4 Fix Plex naming and devices for misbehaving clients (#31970) 2020-02-18 19:37:21 -08:00
jjlawren
0213f43f10 Add options to ignore shared/managed Plex clients (#31738)
* Add option to ignore shared/managed Plex clients

* Start to allow user selection

* hass object not ready during init

* Don't bother sorting

* Plex account multi-select, handle new users not matching config

* Fix/add tests

* Lint simplifications

* Review cleanup

* Oops

* Rename options attributes, fix/add tests
2020-02-18 16:46:45 -08:00
HomeAssistant Azure
4b3f9ecc2d [ci skip] Translation update 2020-02-19 00:31:49 +00:00
Paulus Schoutsen
9f830964ef Optimize find bad JSON data (#31963) 2020-02-18 16:06:13 -08:00
Robert Svensson
a745134128 deConz - Use proper mechanisms for options flow tests (#31965)
Generic clean up
2020-02-18 23:52:56 +01:00
Robert Svensson
774c892ee6 UniFi config option SSID filter (#31842)
* Draft

* Use new multi_select config validation

* Bump dependency to v13

* Improve options flow

* Add title to config options

* Add config option descriptions

* Fix martins comment
2020-02-18 23:24:21 +01:00
Erik Montnemery
60ae85564e Add support for MQTT device triggers (#31679)
* Add support for MQTT device triggers

* Fix test, tweaks

* Improve test coverage

* Address review comments, improve tests

* Tidy up exception handling

* Fix abbreviations

* Rewrite to handle update of attached triggers

* Update abbreviation test

* Refactor according to review comments

* Refactor according to review comments

* Improve trigger removal

* Further refactoring
2020-02-18 13:51:10 -08:00
Tom Harris
f6540e3002 Fix pre-commit hook issue on Windows (#31648)
* Make shebang compatable with Windows

* Prehook test

* Undo prehook test
2020-02-18 13:33:52 -08:00
Franck Nijhof
4ed7a7f2e0 Upgrade pre-commit to 2.1.0 (#31962) 2020-02-18 13:25:26 -08:00
Robert Svensson
b5df2ba853 deCONZ - Directly reflect changes to config entry options (#31661)
* Directly reflect changes to config entry options

* Remove print

* Add tests

* Add title to config options
2020-02-18 13:24:25 -08:00
J. Nick Koston
17f3332c89 Audit state handling off august bridges and sensors (#31935)
* Audit state handling of august bridges and sensors

This addresses issue #29980

* Prevent setting up august locks that do not have a bridge as they will never work

* Prevent locks showing available when their bridge is offline

* Prevent door sensors from showing available when their bridge is offline

* Prevent creating door sensors for locks that do not have them

* Prevent doorbells showing unavailable when they are in standby mode

* Set SCAN_INTERVAL for binary_sensors to 5 seconds as
  data comes in from the activity endpoint more frequently

* Update homeassistant/components/august/__init__.py

raise if the detail is missing when checking doorsense

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Handle another place where the lock detail could not exist

* Address review comments

* Handle lock detail update failing and add test

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-18 12:11:05 -08:00
Paulus Schoutsen
239dfaba4b Do not use a set for hvac modes in SmartThings (#31959) 2020-02-18 12:09:56 -08:00
Paulus Schoutsen
beee1298c5 Extend safe mode (#31927)
* Extend safe mode

* Add safe mode boolean to config JSON output and default Lovelace

* Add safe mode to frontend

* Update accent color
2020-02-18 11:52:38 -08:00
Markus Pöschl
245482d802 Add Twitch subscription and additional stats (#31122)
* add oauth functionality and additional attributes

* Add tests WIP

* Make mocks work the correct way

* Use CONF_TOKEN constant for config

* Remove twitch from .coveragerc

* Update homeassistant/components/twitch/sensor.py

Lets be consistent

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-02-18 11:51:37 -08:00
Aaron Bach
30efef3085 Add support for SimpliSafe system notifications (#31936)
* Add support for SimpliSafe system notifications

* Actually process notifications

* Code review comments
2020-02-18 11:49:36 -07:00
Vladimír Záhradník
af67bb0df3 Read Modbus climate current temp from input register (#31944) 2020-02-18 18:45:05 +01:00
Paulus Schoutsen
b73531b2fc Untag discovery as an allowed dependency (#31934) 2020-02-18 08:32:56 -08:00
Paulus Schoutsen
7be3a4cd37 Fix entity registry not saving name/icon (#31932) 2020-02-18 08:32:34 -08:00
Markus Pöschl
0ae86b022d Add pigpio remote functionality (#31667) 2020-02-18 12:52:55 +01:00
ktnrg45
f75bda7551 Bump pyps4-2ndscreen to 1.0.7 (#31943) 2020-02-18 09:50:49 +01:00
Malte Franken
e65995eb87 Bump aio_geojson_nsw_rfs_incidents to 0.3 (#31941) 2020-02-18 08:59:49 +01:00
Austin Mroczek
1fa16eefc9 Fix translations_develop (#31942) 2020-02-18 08:58:49 +01:00
HomeAssistant Azure
2e5161997f [ci skip] Translation update 2020-02-18 00:31:41 +00:00
Malte Franken
70910ecc61 Bump aio_geojson_geonetnz_quakes to 0.12 (#31930) 2020-02-17 15:30:31 -08:00
Paulus Schoutsen
7a9b2a2234 Bumped version to 0.106.0b0 2020-02-17 15:26:37 -08:00
Paulus Schoutsen
1f7e3946e8 Merge remote-tracking branch 'origin/master' into dev 2020-02-17 14:55:27 -08:00
Paulus Schoutsen
75b508e872 Merge pull request #31931 from home-assistant/rc
0.105.5
2020-02-17 14:52:02 -08:00
Paulus Schoutsen
7bc87eef6f Bumped version to 0.105.5 2020-02-17 14:15:37 -08:00
Paulus Schoutsen
8812b60f2e Report which data causes JSON serialization error (#31901) 2020-02-17 14:15:09 -08:00
Gerard
21a1186efe Upgrade bimmer_connected to 0.7.0 (#31894) 2020-02-17 14:15:09 -08:00
Bram Kragten
95bcceddf7 Add an options flow to demo (#31920)
To help test the frontend
2020-02-17 14:10:44 -08:00
Quentame
3743aaf70f Add async_unload_entry to iCloud (#31917) 2020-02-17 22:23:24 +01:00
Bram Kragten
e52adbb942 Updated frontend to 20200217.0 (#31922) 2020-02-17 22:03:42 +01:00
Franck Nijhof
4497e98ea2 Remove duke_energy integration (ADR-0004) (#31921) 2020-02-17 21:51:53 +01:00
Aaron Bach
74f0262e82 Bump simplisafe-python to 8.1.1 (#31915) 2020-02-17 13:16:24 -07:00
Paulus Schoutsen
a6b5d73f1c Report which data causes JSON serialization error (#31901) 2020-02-17 10:49:42 -08:00
J. Nick Koston
00ac7a7d70 Provide user consumable errors when lock operations fail (#31864)
* Provide user consumable errors when lock operations fail

This resolves issue #26672

* include from in raise

* pylint

* Cleanup of mocking.
2020-02-17 10:30:14 -08:00
Bram Kragten
18dfb02355 Updated frontend to 20200212.0 (#31912) 2020-02-17 10:24:11 -08:00
Victor Guimarães
93a844b1d5 Hue Group features based on the bulbs in it (#31897)
* Computes the features of a hue group as the union of the features of the bulbs in the group

* Moved create item to a function

* Added test for hue group features
2020-02-17 10:22:34 -08:00
Paulus Schoutsen
81701f7e4c Start safe mode if invalid core conf (#31904) 2020-02-17 10:20:05 -08:00
SukramJ
2366b5f6ca Bump dependency to 0.10.17 for HomematicIP Cloud (#31911) 2020-02-17 18:31:09 +01:00
Paulus Schoutsen
1b7dd6c603 Add icons to scripts (#31899) 2020-02-17 08:44:36 -08:00
Paulus Schoutsen
c788946430 Allow specifying an icon for a scene (#31898) 2020-02-17 08:41:33 -08:00
Paulus Schoutsen
3da136b034 Add logger name to system log (#31902) 2020-02-17 17:26:25 +01:00
mezz64
164e970ba0 Add POD support, sleep fitness sensor to EightSleep (#31874)
* Add POD support, sleep fitness sensor

* Black format changes

* Change dict formatting
2020-02-17 10:15:21 +01:00
Paulus Schoutsen
b77f2670a7 Upgrade aiohue (#31903) 2020-02-17 09:52:54 +01:00
Josef Schlehofer
aead5bada8 Upgrade youtube_dl to version 2020.02.16 (#31905) 2020-02-17 09:08:29 +01:00
mueslo
00b3efec89 prevent dev_id being permanently assigned as config_name (#31886) 2020-02-16 21:07:49 -08:00
Jonathan Keljo
56142ba085 Upgrade greeneye_monitor to 2.0 (#31896) 2020-02-16 20:40:34 -08:00
Jonathan Keljo
f30c636fb7 Fix bugs in greeneye_monitor voltage reporting (#31895)
* Fix #31870

* Fix voltage notifications too
2020-02-16 20:32:59 -08:00
HomeAssistant Azure
84e4ef510e [ci skip] Translation update 2020-02-17 00:31:56 +00:00
Martin Hjelmare
2ce7561343 Clean soundtouch (#31888)
* Clean up soundtouch tests

* Remove not needed updates
2020-02-16 15:34:44 -08:00
Martin Hjelmare
e3adbc336d Fix check_real location guard (#31890) 2020-02-16 15:33:09 -08:00
Gerard
4dc4f84b37 Upgrade bimmer_connected to 0.7.0 (#31894) 2020-02-16 15:32:36 -08:00
Franck Nijhof
ae78fb857e Activate Stale bot for PR's (#31837)
* Activate Stale bot for PR's

* Disable issues only
2020-02-17 00:22:51 +01:00
Martin Hjelmare
f53ae12bb6 Clean up netgear device tracker (#31861)
* Improve logging

* Clean up login

* Clean docstring

* Clean config access

* Remove default None for port

* Add not working guard

* Remove debug print
2020-02-16 23:27:19 +01:00
Laszlo Jakab
1d5d56faf8 Add timestamp to lg_netcast media_image_url to update image correctly (#30933)
* add timestamp to media_image_url to update image correctly

* applying isort on source

* apply black formatting on source

* using f strings in media_image_url property

* remove unnecessary casting
2020-02-16 23:26:41 +01:00
Squixx
2516b9474d Update nederlandse_spoorwegen to properly handle punctuality (#31741) 2020-02-16 17:24:38 +01:00
Jardi Martinez
6be0bcceff Bump adafruit-blinka and adafruit-circuitpython-mcp230xx (#31845)
* Updated MCP23017 component to use latest adafruit-blinka v-3.9.0 and Adafruit_CircuitPython_MCP230xx v-2.2.2

* Added updated dependencies to requirements_all.txt
2020-02-16 17:19:45 +01:00
Ville Skyttä
03f7fe483b Type hint improvements (#31876)
* Complete components.remote type hints

* Define ConfigType only in helpers.typing
2020-02-16 13:47:55 +01:00
Maikel Punie
e5e7c9fa25 Upgrade python-velbus to 2.0.41 (#31875) 2020-02-16 12:36:13 +01:00
SukramJ
32f25a8484 Adjust tests after speed up to restore coverage for HomematicIP Cloud (#31836)
* Adjust tests after speed up to restore coverage for HomematicIP Cloud

* Fix test data

* Fixes after review

* remove duplicate cade

* remove service marker
2020-02-16 10:09:26 +01:00
Marco
20d7c84b22 Fix mikrotik detecting capsman support (#31819)
* fix detecting capsman support

* fix isort

* moved support_capsman to update_devices()

* moved support-checks to setup method

* moved setup method to get_hub_details

* implement suggestion for device lists

* fix black formatting

* remove not needed variable wireless_devices

* fix usage of force_dhcp to seperate wireless devs

* fix black fmt
2020-02-16 09:49:13 +01:00
Paulus Schoutsen
a6eb776768 Merge remote-tracking branch 'origin/master' into dev 2020-02-15 21:39:55 -08:00
J. Nick Koston
096e7cceed Support XML conversion for RESTful sensors (#31809)
* Support XML conversion for RESTful sensors

Many devices continue to use XML for RESTful
APIs.  Interfacing with these APIs requires custom
integrations or command line fork()/exec() overhead
which many of these devices can work with as if
they were JSON using xmltojson via this spec:
https://www.xml.com/pub/a/2006/05/31/converting-between-xml-and-json.html

This change implements converting XML output to
JSON via xmltojson so it can work with the existing
rest sensor component.  As the attributes that
usually need to be scraped are deeper in the document
support for passing in a template to find the
JSON attributes that have been added.  JSON APIs that
do not have their attributes at the top level
can also benefit from this change.

* Auto convert xml, change out the template for jsonpath

* Address review items and potentially unexpected normalize behavior with jsonpath

* Revert "Address review items and potentially unexpected normalize behavior with jsonpath"

This reverts commit fe9e179092.

* json_dict[0] turned out to be needed
2020-02-15 21:10:23 -08:00
Joseph Albert
fee0d8dbdd Add rainforest_eagle support for legacy hardware (#28082)
* Add compatibility with Legacy EAGLE models.

* added mdns resultion via zeroconf

* Added requirements to requirements_all.txt

* Fixed model determination bug

* Fixed formatting issue for Eagle-200 responses.

* Remove mDNS resolution, IP now required.

* added pypi deps, fixed handling of optional params

manifest updates

* Fixed import order per isort.

* Two pylint fixes.

* More consistent try-fail structure to guessing hardware.  Errors actually fail.
2020-02-15 21:10:04 -08:00
J. Nick Koston
f6d9e6b6c5 Convert august to async so a token refresh lock can be used (#31848)
* Convert august to async so a token refresh lock can be used

* Update comment since we now have a lock

* Do not mock the lock

* Address review items
2020-02-15 21:08:52 -08:00
Philip Rosenberg-Watt
fb8cbc2e93 Fix CalDAV recurring events (#31805)
* Fix CalDAV parsing of recurring events

Some CaDAV servers (see: SOGo) return the original event that contains
the recurrence rules. The CalDAV calendar component sorts and filters
events based on their start and end dates, and was failing to properly
show recurring events based on these recurrence rules.

This this change checks if an event has recurrence rules and changes the
start/end dates of the event to today if the event is set to occur
today. This allows the rest of the component logic to function properly.

* Use date from nextmost occurence

* Adding unit tests

* Add endless event unit test

* Create new vevent for each event recurrence today

* Remove redundant unit test

* Add timezone to events that have none

Python cannot compare them otherwise.

* Simplify code, add comments & guard clause

* Add test for recurring all day event

* Account for all-day events

* Remove redundant code

* Remove redundant code

* Remove unnecessary deepcopy

* Add hourly recurring tests

* Add tests for hourly repeating event

* Fix unit test

* Use event.copy()
2020-02-15 19:31:36 -08:00
HomeAssistant Azure
3fb80712be [ci skip] Translation update 2020-02-16 00:31:42 +00:00
jjlawren
91018034b6 Use new custom_serializer (#31871) 2020-02-15 15:36:57 -08:00
Moshe Kaplan
7dff5e79d1 Add support for displaying Daf Yomi (#30628)
* Add support for displaying Daf Yomi

* Ran black --fast

* Added docstring to get_daf

* Further lint fixes

* Remove unnecessary else

* clarify code

* Use fstrings

* pull daf yomi from hdate

* Update manifest version for daf_yomi support

* fix variable usage

* Update requirements

* Also pass in today's date as well

* Rename date variable to daytime_date

* Add tests for daf yomi sensor

* Update stale test IDs
2020-02-16 00:00:17 +01:00
Chris Caron
481d3295a6 Bump Apprise version to v0.8.4 (#31868) 2020-02-15 23:58:42 +01:00
Daniel Høyer Iversen
8c270e6fc7 update pyTibber libary, add signal strength for Pulse and watty (#31851)
* update pyTibber libary, add signal strength for Pulse and watty

* update pyTibber libary, add signal strength for Pulse and watty
2020-02-15 13:52:56 -08:00
Massimiliano Cannarozzo
2c42e2aa79 Improve media name detection on lg_netcast (#31863)
When the tv is using an external input (e.g. HDMI1) values have to be taken from fields otherwise they'll empty
2020-02-15 13:48:30 -08:00
Paulus Schoutsen
02002ac3b9 Update codecov.yml 2020-02-15 13:06:08 -08:00
Ville Skyttä
733f1e1101 Helpers typing improvements (#31865) 2020-02-15 13:03:53 -08:00
Martin Hjelmare
588f2cd920 Revert "Check netgear device_tracker link_rate to ensure device is connected" (#31855)
This reverts commit 669844e4dd.
2020-02-15 17:21:04 +01:00
Michaël Arnauts
b8f9ff76b3 Add Tado water_heater (#30095)
* Add Tado water_heater

* Don't use climate CONSTS

* Fix logging text

* Add changes for multiple bridge support

* Address remarks

* should_poll must be False

* Remove additional async_schedule_update_ha_state()

* Not for climate
2020-02-15 17:08:21 +01:00
Ville Skyttä
1609e33030 Simplify missing Garmin Connect data handling, mark entities un/available (#31718)
* Simplify missing Garmin Connect data handling, mark entities un/available

* Remove unnecessary else
2020-02-15 17:53:10 +02:00
Robin
e38522c612 Bump pillow to 7.0 (#31847) 2020-02-15 11:59:41 +01:00
Massimiliano Cannarozzo
4e54dfa874 Add turn_on_action configuration variable (#31792)
Allow to turn on the TV using an external service
2020-02-15 10:57:04 +01:00
HomeAssistant Azure
f3a8196fb5 [ci skip] Translation update 2020-02-15 00:31:45 +00:00
Paulus Schoutsen
68d2a1107e Merge pull request #31841 from home-assistant/rc
0.105.4
2020-02-14 16:29:09 -08:00
Paulus Schoutsen
350726d938 Revert "For vizio integration, set unique ID early to prevent multiple zeroconf discovery items for the same device to appear (#31686)"
This reverts commit 295963f8e8.
2020-02-14 15:47:14 -08:00
Paulus Schoutsen
8140c033fa Bumped version to 0.105.4 2020-02-14 15:30:23 -08:00
Franck Nijhof
f26cbbdef9 Spotify integration hotfixes (#31835)
* Remove services file, incorrect info

* Guard currently playing for being a NoneType

* Revert "Guard currently playing for being a NoneType"

This reverts commit f5f56b0db0.

* Guard currently playing item is None

* Process review suggestions
2020-02-14 15:30:11 -08:00
Paulus Schoutsen
7705eb7941 Google Assistant: Remove speaker type and earlier filter out devices from being locally exposed (#31830)
* Remove speaker type

* Do not expose locks or alarms to Google Local
2020-02-14 15:30:11 -08:00
Paulus Schoutsen
af9832d468 Fix person device_trackers null (#31829) 2020-02-14 15:30:10 -08:00
Bram Kragten
f042c6f8d5 Updated frontend to 20200130.3 (#31771) 2020-02-14 15:29:41 -08:00
SukramJ
656c901f7b Fix smoke detection for HomematicIP Cloud (#31753) 2020-02-14 15:29:10 -08:00
Paulus Schoutsen
30e302a8a3 Fix person reload service (#31716) 2020-02-14 15:29:09 -08:00
cgtobi
7edf0460cc Fix missing device class in netatmo binary sensors (#31693)
* Bring back device class

* Add door tag sensors types

* Actually discover individual tags per camera
2020-02-14 15:29:08 -08:00
Raman Gupta
295963f8e8 For vizio integration, set unique ID early to prevent multiple zeroconf discovery items for the same device to appear (#31686)
* set unique ID early to prevent multiple zeroconf discovery items for the same device to appear

* add test
2020-02-14 15:29:08 -08:00
Paulus Schoutsen
966df6a411 Guard writing automation/scene/script config (#31568) 2020-02-14 15:29:07 -08:00
Paulus Schoutsen
4501471b8c Google Assistant: Remove speaker type and earlier filter out devices from being locally exposed (#31830)
* Remove speaker type

* Do not expose locks or alarms to Google Local
2020-02-14 15:28:11 -08:00
Paulus Schoutsen
52b045ed30 Fix person device_trackers null (#31829) 2020-02-14 15:27:31 -08:00
Franck Nijhof
f396f1cb18 Spotify integration hotfixes (#31835)
* Remove services file, incorrect info

* Guard currently playing for being a NoneType

* Revert "Guard currently playing for being a NoneType"

This reverts commit f5f56b0db0.

* Guard currently playing item is None

* Process review suggestions
2020-02-14 22:58:39 +01:00
Vilppu Vuorinen
614be5c1bb Remove energy sensor from incompatible Ata devices (#31831)
An AtaDevice has a boolean flag describing whether it supports energy
consumption metering. The flag was ignored resulting in sensor entities
reporting constant 0 kWh consumption.

* Update pymelcloud dependency to support the has_energy_consumed_meter
flag.

* Add ATTR_ENABLED_FN to sensor definitions for filtering out
unsupported sensors.

* Fix typing issue in sensor constructor.

* Remove unused UnitSystem constructor parameter.
2020-02-14 21:11:51 +01:00
Robert Svensson
043d36f7c6 Change multi_select config validator to class (#31828)
* Move multi_select to class

* Fix serializer and add test

* Serializer should also return options
2020-02-14 11:09:40 -08:00
Aaron Bach
d6f0c26e7f Fire HASS events on SimpliSafe events (#31811)
* Fire HASS events on SimpliSafe events

* Bump simplisafe-ptyhon to 7.3.0

* Update reqirements

* Updates

* Revert "Updates"

This reverts commit 5581889417.

* Restrict which events get fired

* Code review comments
2020-02-14 11:24:35 -07:00
Paulus Schoutsen
e019280d94 Annotate more async functions correctly (#31802) 2020-02-14 10:00:22 -08:00
Paulus Schoutsen
71a81c443f Limit translations_develop to an integration (#31804)
* limit translations_develop to english

* Convert to Python

* Limit to integration

* Add to hassfest

* Remove old bash comment
2020-02-14 09:26:50 -08:00
Abílio Costa
e6148d223a Allow hourly forecast in IPMA (#30979)
* update ipma component for pyipma 2.0
* fix wind speed; refactor forecast
* update requirements*.txt
* fix tests; update CODEOWNERS; update pyipma to 2.0.1
* minor changes as suggested in PR
* make lint happy
* fix mocking coroutines
* restore old unique id
* fix station lat/lon; update pyipma version
* add hourly forecast option to IPMA
* add forecast tests
* use for instead of lambda
2020-02-14 12:04:41 -05:00
SukramJ
9eb0415234 Speed up tests of HomematicIP Cloud (#31810)
* Speed up tests of HomematicIP Cloud

* load the json once
2020-02-13 22:56:17 -08:00
Chris Talkington
f9fda7d616 update directv to directpy==0.6 (#31812) 2020-02-13 17:47:16 -08:00
jjlawren
408b41ea02 Add device registry support for Plex (#31797)
* Add device registry support for Plex

* Fix model

* Use Plex server as sensor device identifier
2020-02-13 16:37:52 -08:00
Vladimír Záhradník
f0b2d50e41 Fix swap of min and max default values in Modbus climate (#31801) 2020-02-13 16:34:42 -08:00
jjlawren
eb3097506f Add summary attribtue for currently playing media (#31803) 2020-02-13 16:34:12 -08:00
HomeAssistant Azure
32bc94bdd6 [ci skip] Translation update 2020-02-14 00:31:49 +00:00
SukramJ
2f3ab15268 Remove force from async_schedule_update_ha_state for HMIPC (#31796)
* remove force from async_schedule_update_ha_state if HMIPC

* Fix lint
2020-02-13 16:24:43 -08:00
Paulus Schoutsen
ebeab7f44c Update codecov.yml 2020-02-13 16:15:46 -08:00
jjlawren
59932545ab Update Plex connection class to push (#31806) 2020-02-13 16:45:48 -07:00
Robbie Trencheny
f6341ed3de Add Home Assistant Companion to manifest.json so we can sugges… (#31808) 2020-02-13 15:44:45 -08:00
Ville Skyttä
3018e8ff47 Use time.monotonic instead of time.time where appropriate (#31780) 2020-02-13 22:57:07 +01:00
Paulus Schoutsen
fbbb29a6ec Catch unexpected exceptions when validating config (#31795) 2020-02-13 22:43:07 +01:00
Robert Svensson
6211a2bb98 Add multi select support to config validation and to custom serializer (#31798) 2020-02-13 13:12:09 -08:00
MrDadoo
fdfe88566b Update onewire component (#31419)
* Added some measurement points for Family 26.
Added three attriubtes for each sensor, DEVICE_FILE, RAW_VALUE and SENSOR_TYPE
Added some comments.
Updated to get config values for owserver to get owport and owhost.

* Changed to _LOGGER.debug in some places

Resorted includes

* Fixup of code to reflect review comment, comply to Black and pass tests

* Added unique_id Entity property with device file id and added device_file as attribute that takes its data from Entities unique_id-.

* Missing blank line identified by fake8 and black

* Changed to let device_state_attributes return attribute device_file from the self._device_file member variable of the entity.

* Changed from info to debug logging
2020-02-13 21:56:20 +01:00
Aaron Bach
f091e0412f Add support for real-time data from SimpliSafe (#31424)
* Add support for real-time data from SimpliSafe

* Updated requirements

* Linting

* Ensure dispatcher topic contains the domain

* Don't bother with a partial

* Websovket dataclass and other code review

* Ensure initial_event_to_use works with error

* Don't inline methods

* Don't abuse loop variable

* Simplify initial event retrieval

* Add connection lost and restored events

* Revert "Add connection lost and restored events"

This reverts commit e7ffe05938.

* Make _on_disconnect a static method

* Code review comments

* Allow entities to opt out of REST and/or websocket API updates

* Revert "Allow entities to opt out of REST and/or websocket API updates"

This reverts commit 1989f2e00e.

* Code review comments

* Fix issues with events not triggering correct entities

* Bug fixes
2020-02-13 11:30:38 -08:00
Paulus Schoutsen
9e7185c676 Write state if schedule update state from async context (#31758)
* Write state if schedule update state from async context

* Fix most tests

* Fix test and PS4 I/O in event loop

* Fix ps4 better
2020-02-13 10:22:06 -08:00
Franck Nijhof
8d1f8055dd Fix spelling of NETGEAR and CalDAV in manifests (#31790) 2020-02-13 19:20:26 +01:00
Ville Skyttä
3e23a3a860 Add and use bunch of data size and rate related constants (#31781)
Also fix a few units to match the corresponding data.
2020-02-13 08:52:57 -08:00
Franck Nijhof
0173c61fee Spelling: Config(uration) (#31782) 2020-02-13 08:27:00 -08:00
Jens Østergaard Nielsen
8356ea2616 Update to version 2.6 of ihcsdk (#31789)
* Make the set_runtime_value_int function work with template values

* Use newest version of the ihcsdk library

* Make the set_runtime_value_int function work with template values

* Use newest version of the ihcsdk library

* Updated to the newest ihcsdk 2.5.0

* Formatted changes to make it pass CI tests

* Update to version 2.6 of ihcsdk
2020-02-13 16:12:02 +01:00
Franck Nijhof
d66123cc37 Fix spelling of ASUSWRT in manifest (#31764)
* Fix spelling of ASUSWRT in manifest

* Update homeassistant/components/asuswrt/__init__.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-02-13 14:24:15 +01:00
HomeAssistant Azure
40e866a5bb [ci skip] Translation update 2020-02-13 00:31:46 +00:00
Paulus Schoutsen
52b16bf5aa Rename codecov so it will be picked up (#31775) 2020-02-12 16:16:47 -08:00
Robert Svensson
4cac0443e2 UniFi - Change handling of updated options (#31762)
* Change handling of updated options

* Add tests
2020-02-12 16:15:08 -08:00
Quentame
e0a035ce35 Implement PlatformNotReady to Linky + fix TypeError (#31768) 2020-02-12 16:12:35 -08:00
Franck Nijhof
be388a4797 Fix spelling of AVM FRITZ!Box in manifest (#31765) 2020-02-12 16:12:11 -08:00
Franck Nijhof
aa97be71a8 Fix spelling of apcupsd in manifest (#31770) 2020-02-12 15:36:15 -08:00
Franck Nijhof
78783555ea Fix spelling of VIVOTEK (#31773)
* Fix spelling of VIVOTEK in manifest

* Also adjust default name of camera to match the brand name
2020-02-12 15:36:04 -08:00
J. Nick Koston
6879105b14 Cleanup August activity processing and add tests (#31774)
* Update py-august to 0.12.0

* Upstream update also resolves issue #28960
2020-02-12 15:35:07 -08:00
Bram Kragten
834acd85d3 Updated frontend to 20200212.0 (#31772) 2020-02-12 14:54:33 -08:00
Bram Kragten
56316b1f6e Updated frontend to 20200130.3 (#31771) 2020-02-12 14:53:26 -08:00
Alexei Chetroi
52fe1328f6 ZHA tests refactoring (#31744)
* Refactor ZHA fixtures.
Patch Zigpy radio libs instead of ZHA when setting up fixtures.
Use new fixtures for binary_sensor.zha platform.

* Update ZHA api tests.
* Update ZHA channels and discovery tests.
* Update ZHA cover tests.
* Update device action/trigger tests.
* Update device_tracker.zha platform tests.
* Update fan.zha platform tests.
* Update ZHA gateway tests.
* Update lock.zha platform tests.
* Update switch.zha platform tests.
* Update sensor.zha platform tests.
* Update light.zha platform tests.
* Use MockConfigEntry.
* Address PR comments.
2020-02-12 16:12:14 -05:00
Daniel Shokouhi
43256ebd83 Add device name to sensor name for mobile_app (#31756)
* Add device name to sensor name

* Update test to include device name
2020-02-12 11:40:39 -08:00
Paulus Schoutsen
3b3e062a35 Whitelist shopping list updated event (#31742)
* Whitelist shopping list updated event

* Add ignore to hassfest
2020-02-12 10:13:07 -08:00
SukramJ
c0756948da Fix smoke detection for HomematicIP Cloud (#31753) 2020-02-12 10:12:26 -08:00
Emanuel Winblad
3e05fc1c11 Add initial version of Vilfo Router integration (#31177)
* Initial implementation of Vilfo router integration.

This commit is a combination of several commits, with commit messages in bullet form below.

* Added additional files to Vilfo integration.
* Added generated files.
* Fixed alphabetic order in generated config_flows.
* Continued implementation of config flow for Vilfo integration.
* Continued work on config_flow for Vilfo.
* Updated requirements in manifest for Vilfo Router integration.
* Some strings added to Vilfo Router integration.
* Vilfo Router integration updated with sensor support.
* Code style cleanup.
* Additional cleanup of config flow.
* Added additional UI strings for Vilfo Router
* Updated tests of config flow and fixed formatting
* Updated requirement upon vilfo-api-client.
* Sensor refactoring including support for icons
* Code style changes for Vilfo Router integration
* Code cleanup
* Fixed linting issues in Vilfo Router integration
* Fixed import order in test for Vilfo integration.

* Updates to Vilfo Router integration based on feedback

Based on the feedback received, updates have been made to the Vilfo Router integration.

A couple of the points mentioned have not been addressed yet, since the appropriate action has not yet been determined. These are:

* https://github.com/home-assistant/home-assistant/pull/31177#discussion_r371124477
* https://github.com/home-assistant/home-assistant/pull/31177#discussion_r371202896

This commit consists of:

    * Removed unused folder/submodule
    * Fixes to __init__
    * Fixes to config_flow
    * Fixes to const
    * Refactored sensors and applied fixes
    * Fix issue with wrong exception type in config flow
    * Updated tests for Vilfo integration config_flow
    * Updated dependency upon vilfo-api-client to improve testability
    * Import order fixes in test
    * Use constants instead of strings in tests

* Updated the VilfoRouterData class to only use the hostname as unique_id when it is the default one (admin.vilfo.com).

* Refactored based on feedback during review.

* Changes to constant names,
* Blocking IO separated to executor job,
* Data for uptime sensor changed from being computed to being a timestamp,
* Started refactoring uptime sensor in terms of naming and unit.
* Updated constants for boot time (previously uptime) sensor.
* Refactored test of Vilfo config flow to avoid patching code under test.
* UI naming fixes and better exception handling.

* Removed unused exception class.

* Various changes to Vilfo Router integration.

* Removed unit of measurement for boot time sensor,
* Added support for a sensor not having a unit,
* Updated the config_flow to handle when the integration is already configured,
* Updated tests to avoid mocking the code under test and also to cover the aforementioned changes.

* Exception handling in Vilfo Router config flow refactored to be more readable.

* Refactored constant usage, fixed sensor availability and fix API client library doing I/O in async context.

* Updated signature with hass first

* Update call to constructor with changed order of arguments
2020-02-12 19:11:15 +01:00
jjlawren
1b2f4fa19f Improve Plex media_player entity naming (#31755) 2020-02-12 09:55:18 -08:00
Bas Nijholt
8498ca37cd Fix moving average test for discrete derivative sensor (#31750)
* fix test_data_moving_average_for_discrete_sensor

After https://github.com/home-assistant/home-assistant/pull/31717 the test
didn't actually test anything anymore.

This fixes that.

* make the test faster
2020-02-12 09:53:06 -08:00
Vladimír Záhradník
378c432f6d Add availability status to Modbus entities and improve error handling (#31073) 2020-02-12 09:37:16 -08:00
Franck Nijhof
06f06427b6 Fix spelling of ecobee in manifest (#31751) 2020-02-12 10:29:06 -05:00
Paulus Schoutsen
cde414e1df Use set for dependency lookup in hassfest (#31746) 2020-02-12 12:59:59 +01:00
Robbie Trencheny
0700d38d1f Add new webhook action to allow enabling encryption in an exis… (#31743)
* Add new webhook action to allow enabling encryption in an existing registration

* Harden tests

* Make requested fixes
2020-02-11 23:56:22 -08:00
J. Nick Koston
f5be9ef7fb Refresh the august access token when needed (#31735)
* Refresh the august access token
when needed.

Currently august will stop working when the token
expires about every six month.

This resolves issue #23788

* Make refresh_access_token_if_needed private since we do not want additional callers

* Add init
2020-02-11 22:13:54 -08:00
cgtobi
891f13eefe Fix missing device class in netatmo binary sensors (#31693)
* Bring back device class

* Add door tag sensors types

* Actually discover individual tags per camera
2020-02-11 18:02:13 -08:00
Ville Skyttä
d1b0ab736d Improve Huawei LTE timeouting/stalling request behavior (#31710)
* Suppress data get timeout exceptions for 30s after notify attempts

At least SMS send failures may put the API in a state where it times out
some (but not all) data get operations for some time, e.g. 25s.

Closes https://github.com/home-assistant/home-assistant/issues/30827

* Do not pile up duplicate data requests

Do not add another request for a piece of data for which a previous
request is still in progress. For example failing SMS sends are known to
stall some (but not all) requests for some time, and firing up more is
not going to help.
2020-02-11 17:54:19 -08:00
J. Nick Koston
54eb740ff6 Read door open/close events from the activity log. (#31732)
As polling for lock status is every 15 minutes,
we read lock and unlock events from the activity log.

An upstream update of py-august was needed to
expose the door open and close events.

Door open and close events are now seen within
a few seconds instead of delayed 15+ minutes.
2020-02-11 17:43:56 -08:00
Diogo Gomes
787edf9417 pyipma version bump (#31739) 2020-02-11 17:37:48 -08:00
HomeAssistant Azure
9e233070a0 [ci skip] Translation update 2020-02-12 00:31:49 +00:00
Vladimír Záhradník
378bd8438b Update Modbus service manifest (#31727) 2020-02-11 22:11:02 +01:00
Massimiliano Cannarozzo
15ed086ed2 Fix set volume level (#31731)
afsapi requires an `int` in the 0-20 range but we receive a `float` in the 0.0-1.0 range so we have to cast and offset it
2020-02-11 22:10:33 +01:00
Kit Klein
3435281bd1 Support Konnected Pro alarm panel, embrace async, leverage latest HA features/architecture (#30894)
* fix unique_id computation for switches

* update konnected component to use async, config entries, registries. Pro board support and tests

* clean up formatting comments from PR

* use standard interfaces in tests

* migrate config flow to use options

* address latest pr feedback

* format for import as part of config schema validation

* address pr feedback

* lint fix

* simplify check based on pr feedback

* clarify default schema validation

* fix other schema checks

* fix translations

Co-authored-by: Nate Clark <nate@nateclark.com>
2020-02-11 22:04:42 +01:00
Paulus Schoutsen
51c35ab9a8 Entity Registry to store and restore name/icon (#31714)
* Entity Registry to store and restore name/icon

* Update test_entity_registry.py

* Add original name/icon to JSON result
2020-02-11 09:40:50 -08:00
J. Nick Koston
ecd7ec385d Significantly reduce the number of API calls that the august integration (#31685)
* Significantly reduce the number of API calls that the august integration
makes.

The poll interval for the lock status API is now 15 minutes
instead of every 10 seconds because we can use the activity
API to see changes in lock state.  The interval for the
activity API is 10 seconds which allows for the same
frequency of state monitoring without all the additional API calls.
With four locks, this change results in an ~80% reduction in the number
of API calls.

The result of the lock and unlock APIs now update the lock state instead
of waiting for the next poll.  This change also has the added benefit of
making the UI appear far more responsive.

* Convert to using UTC times
2020-02-11 17:57:26 +01:00
Paulus Schoutsen
81b159f424 Disable Hue groups for new setups (#31713) 2020-02-11 08:50:07 -08:00
Victor Vostrikov
3df2cb6b78 Add support of multiple Tado accounts (#31527)
* Added support of multiple Tado accounts
Changed geberation of sensor unique id (breaking change)

* Fixed lints

* Fixed error detecting opened window

* Changed gereration of unique id of climate

* Removed commented code and added comments
2020-02-11 08:46:02 -08:00
Paulus Schoutsen
8a6158116a Fix person reload service (#31716) 2020-02-11 09:07:46 +01:00
Paulus Schoutsen
6fcf5472a5 Limit derivative test (#31717) 2020-02-11 09:03:52 +01:00
Paulus Schoutsen
5a0f21cbe3 Adjust entity slow warning for custom component (#31711) 2020-02-10 16:32:47 -08:00
HomeAssistant Azure
2db6246244 [ci skip] Translation update 2020-02-11 00:31:53 +00:00
Paulus Schoutsen
fb6fb42f85 Merge pull request #31712 from home-assistant/rc
0.105.3
2020-02-10 15:49:08 -08:00
Rami Mosleh
c66106ee98 Add Glances sensors dynamically (#28639)
* Add temp_sensors to glances dynamically

* unsub from updates when sensor is disabled

* dynamicall add sensors

* change "device_name" to "mnt_point"

* remove unnecessary logging

* update sensor.py

* update test_config_flow.py

* remove commented code
2020-02-10 15:02:14 -08:00
SoftXperience
d55846c33a Use latest version of python-pushover (forked) to fix issue with diff… (#31647)
* Use latest version of python-pushover (forked) to fix issue with different API tokens. (https://community.home-assistant.io/t/different-applications-in-pushover/6985)

* Rewrite pushover notify to use pushover_complete library

* Remove possibility to attach urls to notifications

* Fix comment
2020-02-10 14:55:17 -08:00
Raman Gupta
284fd46ea8 For vizio integration, set unique ID early to prevent multiple zeroconf discovery items for the same device to appear (#31686)
* set unique ID early to prevent multiple zeroconf discovery items for the same device to appear

* add test
2020-02-10 14:54:52 -08:00
Paulus Schoutsen
992484fbe6 Bumped version to 0.105.3 2020-02-10 14:45:44 -08:00
cgtobi
834b0e6cf0 Fix wrong error message in netatmo integration (#31690) 2020-02-10 14:45:34 -08:00
Daniel Høyer Iversen
925fa25ac7 Fix hvac_action for mill (#31630) 2020-02-10 14:45:33 -08:00
Alexei Chetroi
fb6eedb4c2 Bump ZHA dependencies. (#31619)
Bump up zigpy-homeassistant==0.13.2
2020-02-10 14:44:25 -08:00
Ron Klinkien
881c501cef Catch garmin_connect keyerrors with unknown entity type updates (#31608)
* Catch keyerrors with unknown entity type updates

* Change debug level and removed . from log call
2020-02-10 14:44:24 -08:00
MatthewFlamm
4212fd8999 update pynws to 0.10.4 (#31591) 2020-02-10 14:44:23 -08:00
Rami Mosleh
b3aacfeb90 Fix librouteros response error handling (#31588) 2020-02-10 14:44:23 -08:00
Franck Nijhof
8da948e909 Bump adguardhome to 0.4.1 (#31565) 2020-02-10 14:44:22 -08:00
J. Nick Koston
a02bb893ef Resolve August integration makes too many requests and hits rate limits (#31558) 2020-02-10 14:44:21 -08:00
Alexei Chetroi
cc5377747f Bump ZHA dependencies. (#31555) 2020-02-10 14:44:21 -08:00
Eduard van Valkenburg
454e63b69e Fix Evohome checking override duration (#31697) 2020-02-10 14:43:39 -08:00
Vladimír Záhradník
94da129ef8 Extend Modbus binary sensor to support discrete inputs (#30004)
* Extend Modbus binary sensor to support discrete inputs

* Add backward compatibility for Modbus binary sensor
2020-02-10 13:56:39 -08:00
Ziv
4467409e5c Dynalite Integration (#27841)
* Initial commit

* ran hassfest and gen_requirements_all scripts

* fixes per request from Paulus Schoutsen

* ran gen_requirements_all

* updated library version - removed some debug leftover

* get_requirements again...

* added documentation URL

* ran isort

* changed storage in hass.data[DOMAIN] to use entry_id instead of host

* adopted unit tests to latest fix

* Update const.py

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-10 13:16:04 -08:00
Vilppu Vuorinen
b78d156f0e Add MELCloud integration (#30712)
* Add MELCloud integration

* Provides a climate and sensor platforms. Multiple platforms on one go
is not the best option, but it does not make sense to remove them and
commit them later either.

* Email and access token are stored to the ConfigEntry. The token can be
updated by adding the integration again with the same email address. The
config flow is aborted and the update is performed on the background.

* Run isort

* Fix pylint errors

* Run black

* Increase coverage

* Update pymelcloud dependency

* Add HVAC_MODE_OFF emulation

* Remove print

* Update pymelcloud to enable device type filtering

* Collapse except blocks and chain ClientNotReadys

* Add preliminary documentation URL

* Use list comp for creating model info

Filters out empty model names form units.

* f-string galore

Dropped 'HVAC' from AtaDevice name template.

* Delegate fan mode mapping to pymelcloud

* Fix type annotation

* Access AtaDevice through self._device

* Prefer list comprehension

* Update pymelcloud to leverage device type grouping

The updated backend lib returns devices in a dict grouped by the device
type. The devices do not necessarily need to be in a single list and
this way isinstance is not required to extract devices by type.

* Remove DOMAIN presence check

This does not seem to make much sense after all.

* Fix async_setup_entry

Entry setup used half-baked naming from few experimentations back.
The naming conventiens were unified to match the platforms.

A redundant noneness check was also removed after evaluating the
possible return values from the backend lib.

* Simplify empty model name check

* Improve config validation

* Use config_validation strings.

* Add CONF_EMAIL to config schema. The value is not strictly required
when configuring through configuration.yaml, but having it there makes
things more consistent.

* Use dict[key] to access required properties.

* Add DOMAIN in config check back to async_setup. This is required if an
integration is configured throught config_flow.

* Remove unused manifest properties

* Remove redundant ClimateDevice property override

* Add __init__.py to coverage exclusion

* Use CONF_USERNAME instead of CONF_EMAIL

* Use asyncio.gather instead of asyncio.wait

* Misc fixes

* any -> Any

* Better names for dict iterations

* Proper dict access with mandatory/known keys

* Remove unused 'name' argument

* Remove unnecessary platform info from unique_ids

* Remove redundant methods from climate platform

* Remove redundant default value from dict get

* Update ConfigFlow sub-classing

* Define sensors in a dict instead of a list

* Use _abort_if_unique_id_configured to update token

* Fix them tests

* Remove current state guards

* Fix that gather call

* Implement sensor definitions without str manipulation

* Use relative intra-package imports

* Update homeassistant/components/melcloud/config_flow.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-02-10 22:09:12 +01:00
Hans Oischinger
7e0560c7dc Vicare water_heater set_temperature fix and bump PyVicare to 0.1.7 (#31672)
* Fix ViCare water_heater set_temperature

This fixes a obvious but undiscovered bug in the water heater component:
Instead of the commanded value the prvious value was set on the API

* Bump PyVicare to 0.1.7
2020-02-10 21:23:02 +01:00
Maikel Punie
5a7e0b84ff Bump velbus version + load velbus module names into device info (#31664) 2020-02-10 21:22:09 +01:00
Quentame
9e41ee49cb Fix Météo-France I/O while testing (#31695)
* Fix Météo-France I/O while testing

* Review
2020-02-10 17:00:22 +01:00
cgtobi
7d0b50cadb Fix wrong error message in netatmo integration (#31690) 2020-02-10 12:33:07 +01:00
Paulus Schoutsen
5092971452 Add brightness light device actions (#31567) 2020-02-09 19:47:59 -08:00
Paulus Schoutsen
12de3f1e47 Clean up frontend services and events (#31654)
* Clean up frontend services and events

* Fix bug in core instead

* Add test that core works correctly with callback marked async funcs
2020-02-09 19:47:16 -08:00
Alexei Chetroi
28eeed1db3 ZHA tests refactoring (#31682)
* Fixtures for restoring/joning a device.

* binary_sensor.zha tests.

* cover.zha platform tests.

* device_tracker.zha platform tests.

* fan.zha platform tests.

* switch.zha platform tests.

* Update light.zha platform tests.

* Update sensor.zha platform tests.

* ZHA api tests refactoring.

* Update lock.zha platform tests.

* Update ZHA gateway tests.

* Update zha device action tests.

* Update zha device trigger tests.

* Cleanup.
2020-02-09 21:45:35 -05:00
HomeAssistant Azure
118ba10442 [ci skip] Translation update 2020-02-10 00:31:37 +00:00
Balazs Sandor
41f3fb291a Add ZHA Texas Instruments CC device support (#31621) 2020-02-09 12:13:22 -05:00
Ben
fb2e120563 Sure Petcare new features various improvements (#31437)
* add typing

* 100% battery_level is enough

* human-friendly datetime

* better enum usage

* add online and learning mode attrs

* use max two decimals in attrs

* use legacy style debug logging

* remove str usage of enums

* add feeder

* add feeder and adapt to new surepy version

* use ProductID instead of ThingID

* various changes and improvements

* add connectivity sensors for all devices & proper support for multiple hubs

* remove "side effects"/exception catching in attribs

* correct unique ids, reorder classes

* move Flap class from binary_sensor to sensor and add a sensore base class

* comments cleanup, minor typing and logging fixes

* remove commented code

* remove commented code

* add typing

* 100% battery_level is enough

* human-friendly datetime

* better enum usage

* add online and learning mode attrs

* use max two decimals in attrs

* use legacy style debug logging

* remove str usage of enums

* add feeder

* add feeder and adapt to new surepy version

* use ProductID instead of ThingID

* various changes and improvements

* add connectivity sensors for all devices & proper support for multiple hubs

* remove "side effects"/exception catching in attribs

* correct unique ids, reorder classes

* move Flap class from binary_sensor to sensor and add a sensore base class

* comments cleanup, minor typing and logging fixes

* remove commented code

* remove commented code

* fix spelling in comment to make the CI happy (seriously?!)

* fix manifest file

* fix requirements_all.txt file

* add missing docstrings

* fix available property

* remove typing from self

* remove commented code

* remove is_on property from sensor

* jump to new surepy version

* remove useles init methods
2020-02-09 17:46:00 +01:00
Jonathan Østrup
150b376cf9 Add recorder vars db_max_retries and db_retry_wait (#31561)
* added recorder vars db_max_retries and db_retry_wait

* fixed test_recorder_setup_failure

I failed because it was missing the two new variables. I simply added these with default values.

* fixed syntax error in test_recorder_setup_failure

* fixed formatting error in test_init_py for recorder component

* fixed typo in test case

* Updated the way the default keys for db_,max_wait and db_retry_wait is set

Implemented based on suggestions from @springstan

* Updated config_schema call to adhere to Black

* changed conf.get to conf[dict] for var retrieval

* removed 2 blank lines
2020-02-09 17:43:09 +01:00
crallian
645c673720 Added zone type Technical as power. (#31611)
*The zone type technical can be used in SPC to track status of e.g. mapping keys and outputs.
2020-02-09 17:41:43 +01:00
Paulus Schoutsen
da0ddc84ab Guard writing automation/scene/script config (#31568) 2020-02-08 17:26:58 -08:00
Josh Anderson
9987978d1a Add unique ID to edimax switches (#27984)
* Add unique ID and device info data

* Don't get power info on switch models lacking it

* Move info fetching to update, update before adding

* Upgrade pyedimax to get device info

* Remove device info

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-08 16:45:28 -08:00
HomeAssistant Azure
a2bea2cab8 [ci skip] Translation update 2020-02-09 00:31:39 +00:00
Bruno Furtado
9f58e5d6ea Only auth on enter_learning in response to errors for broadlink (#27341)
* Only auth on enter_learning in response to errors.

* Remove extra newline.

* Add missing break on successful attempt.

* Avoid logging success message when auth is unsuccessful.
2020-02-08 16:17:40 -08:00
Tom Harris
e3894d212c Bump insteonplm to 0.16.7 (#31645) 2020-02-08 22:34:22 +01:00
Paulus Schoutsen
989dd32258 Hue to retry if hub errors out (#31616)
* Respect semaphore

* Add retries when connection reset

* Also catch OSError from aiohttp when authenticating
2020-02-08 13:20:37 -08:00
J. Nick Koston
0dd151c1c3 Resolve August integration makes too many requests and hits rate limits (#31558) 2020-02-08 20:22:48 +01:00
Paulus Schoutsen
ca1319e1ef Device tracker entities based on GPS should always publish updates (#31551) 2020-02-08 19:56:48 +01:00
Ron Klinkien
1093e25a30 Catch garmin_connect keyerrors with unknown entity type updates (#31608)
* Catch keyerrors with unknown entity type updates

* Change debug level and removed . from log call
2020-02-08 18:47:54 +01:00
shred86
14e0dde055 Add Abode water valve support (#30635) 2020-02-08 16:58:07 +01:00
CHAZICLE
967b02073e Remove stray debug from unifi integration (#31634) 2020-02-08 16:07:17 +01:00
Daniel Høyer Iversen
6037f7364f Fix hvac_action for mill (#31630) 2020-02-08 16:00:20 +01:00
Yarmo Mackenbach
658c48b237 Handle missing next train from NS (#31626)
* Handle missing next train

* Ignore next attribute instead
2020-02-08 15:52:05 +01:00
springstan
83a79a434c Use slug in ping device tracker config validation (#31329)
* Use slug instead of string for config validation
2020-02-08 15:19:46 +01:00
melyux
ed3e16123e Actually enable alarmdecoder to see open/close state of bypassed RF zones when armed (#31426) 2020-02-08 14:32:52 +01:00
Oliver
a5b4f43ea5 Bump denonavr to 0.7.12 (#31629) 2020-02-08 13:46:13 +01:00
Paulus Schoutsen
111050bea9 Clean up core services (#31509)
* Clean up core services

* Fix conversation test
2020-02-08 13:10:59 +01:00
Alexei Chetroi
57ab30d534 Bump ZHA dependencies. (#31619)
Bump up zigpy-homeassistant==0.13.2
2020-02-08 06:50:50 -05:00
escoand
0823ee4385 Fix exceptions when using newer Samsung TVs (#31602)
* try to fix websocket problems

* use tuple

* catch websocket exceptions

* typo
2020-02-08 12:03:35 +01:00
SukramJ
baa9184b33 Extract services from init.py for HomematicIP Cloud (#31376)
* Extract services from init.py for HomematicIP Cloud

* add ServiceCallType
2020-02-08 10:07:20 +01:00
elmurato
699d6ad658 Add Minecraft Server Integration (#30992)
* Add Minecraft Server integration

* Add unit test for config flow

* Fixed some review findings and increased unit test coverage

* Fixed docstrings of new test cases

* Removed unnecessary debug log messages

* Added unique IDs and device infos and removed duplicate name validation

* Attempt to fix unit test on CI

* Return state OFF instead of UNAVAILABLE in case connection to server drops

* Added property decorator to server properties, even less debug messages, improved sensor dispatcher connection and other review findings fixed

* Moved special property handling to sensors, fixed name confusion in sensor entity, switch to HA const for scan_interval, simplified building players list string

* Improved periodic update, speeded up unit tests

* Added type hints, added callback decorator to entity update callback, added const.py to unit test exclusions

* Changed state sensor to binary sensor, removed empty unit test file, added constants for icons and units

* Let HA handle unknown state, check for None in description and players list sensor

* Removed periods at end of log messages, removed constant for default host

* Updated requirements_test_pre_commit.txt, fixed codespell findings

* Use localhost as default host

* Removed passing hass to entities, moved log message from init, moved host lower to vol, use proper patch library, patch library instead of own code

* Replaced server properties with global instance attributes, removed config option scan_interval, switch back to async_track_time_interval

* Removed description and players list sensors, added players list as state attributes to online players sensor, raise OSError instead of deprecated IOError, other minor review findings fixed

* Use MAC address for unique_id in case of an IP address as host, added getmac to manifest.json, added invalid_ip to strings.json, added new test cases for changes in config_flow, replace all IOError's with OSError, other review findings fixed

* Removed double assignment

* Call get_mac_address async safe

* Handle unavailable and unknown states to reach silver quality scale, added quality scale to manifest.json
2020-02-08 09:28:35 +01:00
HomeAssistant Azure
5483de7e25 [ci skip] Translation update 2020-02-08 00:31:45 +00:00
MatthewFlamm
f9e037a823 update pynws to 0.10.4 (#31591) 2020-02-07 09:16:56 -05:00
Rami Mosleh
c0eb399d54 Fix librouteros response error handling (#31588) 2020-02-07 14:03:32 +01:00
Eugenio Panadero
37205f9f61 Unregister listener for stats sensor with max_age (#31580) 2020-02-07 11:06:46 +01:00
HomeAssistant Azure
274cf23269 [ci skip] Translation update 2020-02-07 00:31:50 +00:00
Franck Nijhof
d093b5f5e8 Bump adguardhome to 0.4.1 (#31565) 2020-02-06 16:02:00 -08:00
jjlawren
3a3328dc13 Skip updates when Plex client viewing photos (#31556) 2020-02-06 14:26:34 -08:00
Alexei Chetroi
0e68ace3dd Bump ZHA dependencies. (#31555) 2020-02-06 16:34:28 -05:00
Phil Bruckner
d1e7ade6db Make amcrest integration more robust (#30843)
- Bump amcrest package to 1.5.6. Includes networking improvements, no longer
  communicates during Http.__init__(), and allows running snapshot command
  without using stream mode.
- Handle login errors better, and not just at startup.
- Increase network connect & read timeout to 6.05 seconds.
- Increase network read timeout to 20 seconds for snapshot command.
- Run snapshot command in separate task, that cannot be cancelled, to eliminate
  possibility of two snapshot commands running simultaneously (since
  AmcrestCam.async_camera_image can be cancelled.) Also makes sure any exceptions
  from the command are caught properly.
2020-02-06 14:44:48 -06:00
Paulus Schoutsen
76d2658101 Merge pull request #31550 from home-assistant/rc
0.105.2
2020-02-06 11:54:23 -08:00
Paulus Schoutsen
8ab91eb6bb Update MQTT service description 2020-02-06 11:39:55 -08:00
Paulus Schoutsen
9e87a662d5 Update MQTT service description 2020-02-06 11:39:44 -08:00
Paulus Schoutsen
4e5c74d293 Bumped version to 0.105.2 2020-02-06 11:08:26 -08:00
Paulus Schoutsen
d31eb9f352 Guard for reloading with no zone config (#31547) 2020-02-06 11:08:18 -08:00
Josh Bendavid
bb96584d6e update aiopylgtv to 0.3.3 (#31545) 2020-02-06 11:08:17 -08:00
Paulus Schoutsen
774f0f9b67 Deprecate old netatmo keys (#31544) 2020-02-06 11:08:16 -08:00
Ville Skyttä
64fc7103be Use min and m as units in Garmin Connect for consistency and correctness (#31543) 2020-02-06 11:08:16 -08:00
Franck Nijhof
080f9725dc Limit OAuth scopes for Netatmo and Home Assistant Cloud (#31538)
* Limit OAuth scopes for Netatmo and Home Assistant Cloud

* Fix tests by making order of scopes predictable
2020-02-06 11:08:15 -08:00
Quentame
bf1b78f621 Fix iCloud determine_interval: add default interval to max_interval (#31533) 2020-02-06 11:08:14 -08:00
Dougal Matthews
6b5cd74771 Only normalise Garmin connect data to minutes if the value is not None (#31526)
Otherwise this causes additional TypeError messages to be logged for
division of None.
2020-02-06 11:08:13 -08:00
Robert Chmielowiec
60c5ef5b34 Fix migrating huawei_lte entry without recipient (#31522) 2020-02-06 11:08:12 -08:00
Paulus Schoutsen
1e81d14822 Fix automation sun import (#31521) 2020-02-06 11:08:11 -08:00
Paulus Schoutsen
00c6f3cb85 Guard for reloading with no zone config (#31547) 2020-02-06 10:55:12 -08:00
Ville Skyttä
08a74ff686 Use min and m as units in Garmin Connect for consistency and correctness (#31543) 2020-02-06 10:54:01 -08:00
Josh Bendavid
eee1ca9211 update aiopylgtv to 0.3.3 (#31545) 2020-02-06 10:00:54 -08:00
Paulus Schoutsen
0d474e1183 Update the update coordinator API to make it easier to use (#31471)
* Update the update coordinator API to make it easier to use

* failed_last_update -> last_update_success
2020-02-06 09:29:29 -08:00
Paulus Schoutsen
d407b8e215 Deprecate old netatmo keys (#31544) 2020-02-06 09:26:51 -08:00
Quentame
9e4904cb21 Fix iCloud determine_interval: add default interval to max_interval (#31533) 2020-02-06 08:53:42 -08:00
Dougal Matthews
24c382d689 Only normalise Garmin connect data to minutes if the value is not None (#31526)
Otherwise this causes additional TypeError messages to be logged for
division of None.
2020-02-06 08:52:46 -08:00
Franck Nijhof
7233048fea Limit OAuth scopes for Netatmo and Home Assistant Cloud (#31538)
* Limit OAuth scopes for Netatmo and Home Assistant Cloud

* Fix tests by making order of scopes predictable
2020-02-06 17:00:27 +01:00
Robert Chmielowiec
24e9a638d5 Fix migrating huawei_lte entry without recipient (#31522) 2020-02-06 16:53:16 +02:00
P-Verbrugge
d3e99f13dd Changed website name to blockchain.com (#31528)
The name and domain of blockchain.info has been changed to blockchain.com. Updated the names in de script.
2020-02-06 15:43:52 +01:00
P-Verbrugge
4f2195101c Updated the provider name to blockchain.com (#31534)
* Updated the provider name to blockchain.com

Blockchain.info moved from .info .com. Updated the name of the service to blockchain.com

* Updated the provider name to blockchain.com

Updated the provider name to blockchain.com
2020-02-06 15:41:48 +01:00
Paulus Schoutsen
44e243039c Fix automation sun import (#31521) 2020-02-06 12:55:11 +01:00
Franck Nijhof
1cfd69d484 Remove of liveboxplaytv integration (ADR0004) (#31525) 2020-02-06 12:54:46 +01:00
Paulus Schoutsen
a3b3924e21 Update link when IO in event loop (#31519) 2020-02-06 11:37:35 +01:00
Malte Franken
8d429d7676 Add GDACS feed integration (#31235)
* initial version of gdacs integration

* updated translations

* generated files

* added abbreviation

* bumped library version

* small feed entry attribute fixes

* add unit tests

* need to use original mdi name

* bumped library version

* improved entity name for earthquakes

* round vulnerability number

* typo

* support for categories

* testing support for categories

* tie longitude and latitude together

* validating categories

* simplifying setup

* passing domain as parameter

* simplified test setup

* moved test code

* simplified test code

* removed superfluous code

* changed approach to unique identifier

* changed code structure

* simplified unit system handling

* made schema a constant

* comment added

* simplifying code

* added message if location already configured

* removed unnecessary code

* simplified test code

* avoid mocking __init__

* pylint

* simplified code

* fetch categories from integration library

* setting PARALLEL_UPDATES

* setting PARALLEL_UPDATES to zero/unlimited

* added quality scale
2020-02-06 11:32:30 +01:00
Paulus Schoutsen
05b3c1f17d Merge remote-tracking branch 'origin/master' into dev 2020-02-05 16:42:47 -08:00
Paulus Schoutsen
8b4bd95fc5 Merge pull request #31510 from home-assistant/rc
0.105.1
2020-02-05 16:41:17 -08:00
HomeAssistant Azure
6f99bac557 [ci skip] Translation update 2020-02-06 00:31:53 +00:00
Paulus Schoutsen
6246382983 Bumped version to 0.105.1 2020-02-05 15:53:11 -08:00
Paulus Schoutsen
29f17956bf Update translations 2020-02-05 15:53:04 -08:00
Paulus Schoutsen
6e0e58f6cc Sonos services to work without admin access (#31506) 2020-02-05 15:52:15 -08:00
Paulus Schoutsen
46fb73ea76 Updated frontend to 20200130.2 (#31502) 2020-02-05 15:51:49 -08:00
Andrew
08b24afc2d Move program_mode check (#31501)
Don't try to capture program_mode unless ct80
2020-02-05 15:50:49 -08:00
Paulus Schoutsen
f7f8de41e2 Check for known Hue vulnerability (#31494) 2020-02-05 15:50:48 -08:00
Paulus Schoutsen
8d2086d076 Sonos services to work without admin access (#31506) 2020-02-05 15:50:20 -08:00
Paulus Schoutsen
41c55e695e Fix typo in comment 2020-02-05 14:45:14 -08:00
Andrew
c9be201ee2 Move program_mode check (#31501)
Don't try to capture program_mode unless ct80
2020-02-05 14:44:44 -08:00
Paulus Schoutsen
ba9892e1f1 Updated frontend to 20200130.2 (#31502) 2020-02-05 14:41:01 -08:00
Paulus Schoutsen
481ea0aa5b Check for known Hue vulnerability (#31494) 2020-02-05 13:57:17 -08:00
dupondje
557f5763df Add belgian meter and rename some dsmr sensors (#30121)
* Add support for belgian meter and rename some sensors

* DSMR Fixes

* Add test

* More tests

* Adjust test to latest dev

* Remove unused code

* Depend on dsmr_parser 0.18
2020-02-05 22:14:03 +01:00
Franck Nijhof
cb2a9dfebf Merge branch 'master' into dev 2020-02-05 20:33:06 +01:00
Franck Nijhof
b2cd6707b6 0.105.0 (#31489)
0.105.0
2020-02-05 20:02:36 +01:00
Paulus Schoutsen
6a4d9d3a73 Fix Google API key test (#31492) 2020-02-05 18:57:43 +01:00
Paulus Schoutsen
472fe7a0fa Fix Google API key test (#31492) 2020-02-05 09:50:00 -08:00
Paulus Schoutsen
1ee1a43fb9 Remove tests for deprecated key (#31491) 2020-02-05 18:02:53 +01:00
Paulus Schoutsen
0f56fc75b3 Bump version to 0.106.0dev0 2020-02-05 09:00:54 -08:00
Paulus Schoutsen
84cbcb4d16 Remove tests for deprecated key (#31491) 2020-02-05 09:00:20 -08:00
Franck Nijhof
f1d5fcac75 Bumped version to 0.105.0 2020-02-05 17:01:57 +01:00
Franck Nijhof
97250d8225 Re-branding of Hass.io panel to Supervisor (#31480) 2020-02-05 16:59:29 +01:00
Paulus Schoutsen
8b6b8f1994 Automation device/entity extraction to include triggers + conditions (#31474)
* Add support for extracting triggers

* Add support for extracting triggers

* Fix test
2020-02-05 16:59:24 +01:00
Quentame
2d393b8f8b Fix iCloud device battery level can be None (#31468) 2020-02-05 16:59:19 +01:00
Paulus Schoutsen
6d79898926 Fix coordinator reference (#31467) 2020-02-05 16:59:14 +01:00
Raman Gupta
2509518950 Update vizio host check to handle entries that don't have port (#31463)
* Update vizio host check to handle entries that don't have port

* add comment explaining no_port test for future

* remove _name_is_same function and support user updating name in config

* Update strings.json

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-05 16:59:07 +01:00
Paulus Schoutsen
67680bcfa8 Automation device/entity extraction to include triggers + conditions (#31474)
* Add support for extracting triggers

* Add support for extracting triggers

* Fix test
2020-02-05 16:52:21 +01:00
Franck Nijhof
431a3a6b44 Re-branding of Hass.io panel to Supervisor (#31480) 2020-02-05 11:04:17 +01:00
Robert Svensson
fce9697591 deCONZ - Revert from using disabled_by when setting options (#31446)
* Revert from using disabled_by when setting options

* Remove signalling for changed options

* Evaluate allow group option earlier when adding a group
2020-02-04 16:37:01 -08:00
HomeAssistant Azure
3801d5adf4 [ci skip] Translation update 2020-02-05 00:31:54 +00:00
Paulus Schoutsen
c85a7934ed Add brightness_step to light.turn_on (#31452)
* Clean up light turn on service

* Add brightness_step to turn_on schema

* Fix import

* Fix imports 2

* Fix RFLink test
2020-02-04 16:13:29 -08:00
Paulus Schoutsen
e970177eeb Use entity.async_request_call in service helper (#31454)
* Use entity.async_request_call in service helper

* Clean up semaphore handling

* Address comments

* Simplify call entity service helper

* Fix stupid rflink test
2020-02-04 15:30:15 -08:00
Quentame
2c439af165 Fix iCloud device battery level can be None (#31468) 2020-02-05 00:26:47 +01:00
Paulus Schoutsen
370e2ffa5a Fix coordinator reference (#31467) 2020-02-04 14:57:15 -08:00
Paulus Schoutsen
f41623ca64 Log warning when entities referenced in service call not found (#31427)
* Raise entities not found error

* Make it a warning, not an error

* Add support for MATCH_ENTITY_NONE

* Fix lint

* Fix tests
2020-02-04 14:42:07 -08:00
Quentame
201ea2557e Add config flow to Meteo-France (#29927)
* Add config flow to Meteo-France

* Review 1

* Use config_entry.unique_id

* Fix config_flow _show_setup_form + init

* Remove empty *_setup_platform()

* Avoid HomeAssistantError: Entity id already exists: sensor.[city_name]_[sensor_type]. Platform meteo_france does not generate unique IDs

- when multiple district in one city

* Review + abort when API error

* Fix I/O

* Remove monitored_conditions

* Add async_unload_entry

* Review 3

* Fix pipe

* alert_watcher is already None

* Review 4

* Better fix for "Entity id already exists"

* Whoops, fix tests

* Fix string
2020-02-04 22:37:59 +01:00
Raman Gupta
1efea50654 Update vizio host check to handle entries that don't have port (#31463)
* Update vizio host check to handle entries that don't have port

* add comment explaining no_port test for future

* remove _name_is_same function and support user updating name in config

* Update strings.json

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-02-04 11:31:03 -08:00
Paulus Schoutsen
d411ae2503 Bumped version to 0.105.0b7 2020-02-04 09:29:39 -08:00
Bram Kragten
e5b6fbf374 Updated frontend to 20200130.1 (#31460) 2020-02-04 09:29:21 -08:00
etheralm
af75a4bc85 Update libpurecool upstream library to latest version (#31457)
* Update upstream library to latest version

* update version in requirements_all.txt

* update version in requirements_all.txt
2020-02-04 09:27:04 -08:00
Bas Nijholt
10d5ce24f6 Keep track of the derivative for unit_time (#31397)
* keep track of the derivative for unit_time

In this way, you will get a better estimate of the derivate during
the timescale that is relavant to the sensor.

This solved a problem where sensors have a low output resolution.
For example a temperature sensor that can only be integer numbers.

It might report many values that are the same and then suddenly go up one value.
Only in that moment (with the current implementation) the derivative will be finite.

With my proposed implementation, this problem will not occur, because it takes the average
derivative of the last `unit_time`.

* only loop as much as needed

* treat the special case of 1 entry

* add option time_window

* use cv.time_period

* fix comment

* set time_window=0 by default

* rephrase comment

* use timedelta for time_window

* fix the "G" unit_prefix and add more prefixes

https://en.wikipedia.org/wiki/Unit_prefix

* add debugging lines

* simplify logic

* fix bug where the there was a division of unit_time instead of multiplication

* simplify tests

* add test_data_moving_average_for_discrete_sensor

* fix test_dataSet6

* improve readability of the tests

* better explain the test

* remove debugging log lines
2020-02-04 09:27:03 -08:00
quthla
1008ab20ba Fix theme color (#31366) 2020-02-04 09:27:02 -08:00
escoand
2f2146c989 Samsung TV refinements (#31248)
* use st not deviceType

* show model in flow title

* Update strings.json

* add re-auth to entity

* add re-auth to config_flow

* handle auth popup better

* use media player domain const

* fix tests

* rename not_found to not_successful

* authz not authn

* Update media_player.py

* Update config_flow.py

* Update media_player.py

* Update test_media_player.py

* finalize re-auth

* fix ssd tests

* better naming

* fix ip-address-mock serialization

* fix turn_on_action serialization

* add type of hass object

* fix acces denied test

* remove half-added typing

* async get ip address

* fix pylint
2020-02-04 09:27:01 -08:00
Yarmo Mackenbach
9bb8b2bc00 Update NSAPI to 3.0.2 (#30971)
* Bump NSAPI version to 3.0.1

* Compatibility with NSAPI 3.0.1 response

* Removed commented code

* Obsolete setups receive an upgrade notification

* Bump NS-API to 3.0.2

* Assign platform values directly

* Removed obsolete config warning

* Improved reference to obsolete password
2020-02-04 09:27:00 -08:00
etheralm
8af9585f12 Update libpurecool upstream library to latest version (#31457)
* Update upstream library to latest version

* update version in requirements_all.txt

* update version in requirements_all.txt
2020-02-04 08:23:08 -08:00
Bram Kragten
9097912469 Updated frontend to 20200130.1 (#31460) 2020-02-04 17:07:09 +01:00
Raman Gupta
151f60658c Bump pyvizio version for bug fixes (#31453) 2020-02-04 09:19:14 +01:00
HomeAssistant Azure
db6449c3fb [ci skip] Translation update 2020-02-04 00:31:49 +00:00
ochlocracy
4602d7370c Remove Alexa.InputController from devices without supported inputs in Alexa (#31450)
* Yield Alexa.InputController only for supported inputs.

* Add Comment.

* Comment fix.
2020-02-03 16:19:40 -08:00
Bas Nijholt
119566f280 Keep track of the derivative for unit_time (#31397)
* keep track of the derivative for unit_time

In this way, you will get a better estimate of the derivate during
the timescale that is relavant to the sensor.

This solved a problem where sensors have a low output resolution.
For example a temperature sensor that can only be integer numbers.

It might report many values that are the same and then suddenly go up one value.
Only in that moment (with the current implementation) the derivative will be finite.

With my proposed implementation, this problem will not occur, because it takes the average
derivative of the last `unit_time`.

* only loop as much as needed

* treat the special case of 1 entry

* add option time_window

* use cv.time_period

* fix comment

* set time_window=0 by default

* rephrase comment

* use timedelta for time_window

* fix the "G" unit_prefix and add more prefixes

https://en.wikipedia.org/wiki/Unit_prefix

* add debugging lines

* simplify logic

* fix bug where the there was a division of unit_time instead of multiplication

* simplify tests

* add test_data_moving_average_for_discrete_sensor

* fix test_dataSet6

* improve readability of the tests

* better explain the test

* remove debugging log lines
2020-02-03 14:22:47 -08:00
ochlocracy
c8d9b83b24 Update StepSpeaker and Speaker interfaces in Alexa (#31444)
* Yield only one Speaker interface.

* Yield PowerController only is supported.

* Revert "Yield PowerController only is supported."

This reverts commit c0dbf7e4

* Add Alexa.Speaker interface properties.

* Refactor tests for Alexa.Speaker and Alexa.StepSpeaker.

* Code Smell Change.

* Fix R1705: Unnecessary "elif" after "return".
2020-02-03 14:20:39 -08:00
quthla
3f9dbe6845 Fix theme color (#31366) 2020-02-03 14:09:25 -08:00
Kasper Kirkegaard
f5b790054a Fix misspelled sensor names (#31344) 2020-02-03 21:31:53 +01:00
Konsts
114d48ed8b Add timeout attribute for send files (#31379)
* Add timeout attribute for send files

* Remove dublicate

Remove attribute dublicate in BASE_SERVICE_SCHEMA

* Remove duplicate

return attribute to BASE_SERVICE_SCHEMA and remove from SERVICE_SCHEMA_SEND_FILE

* Add timeout parameter description

Add timeout parameter description for "send message" and "send location"
2020-02-03 21:23:58 +01:00
escoand
4550968316 Samsung TV refinements (#31248)
* use st not deviceType

* show model in flow title

* Update strings.json

* add re-auth to entity

* add re-auth to config_flow

* handle auth popup better

* use media player domain const

* fix tests

* rename not_found to not_successful

* authz not authn

* Update media_player.py

* Update config_flow.py

* Update media_player.py

* Update test_media_player.py

* finalize re-auth

* fix ssd tests

* better naming

* fix ip-address-mock serialization

* fix turn_on_action serialization

* add type of hass object

* fix acces denied test

* remove half-added typing

* async get ip address

* fix pylint
2020-02-03 20:34:02 +01:00
SukramJ
03642d9029 Add missing await to HMIPC (#31415)
* Add missing await to HMIPC

* use callback instead

* Fix call, move callback to hap
2020-02-03 20:27:20 +01:00
Aaron Bach
bea7aae8cd Fix issues with Ambient PWS dispatcher topic (#31439)
* Correct over-broad Ambient PWS data updates

* Make sure we provide a callable

* Don't use a partial
2020-02-03 12:23:51 -07:00
Aaron Bach
30e803d70b Fix issue with WWLLN dispatcher topic (#31442) 2020-02-03 12:23:19 -07:00
Aaron Bach
e799b08215 Fix issue with IQVIA dispatcher topic (#31440)
* Fix issues with IQVIA dispatcher topic

* Use f-string
2020-02-03 12:23:06 -07:00
Aaron Bach
74fd57e23a Fix issue with Notion dispatcher topic (#31441)
* Fix issue with Notion dispatcher topic

* Use f-string
2020-02-03 12:22:50 -07:00
Vincent Le Bourlot
ad5db47618 Clean up Tahoma smartlock (#31430)
* Added lock support for tahoma

* Removed unused constant.
2020-02-03 20:21:38 +01:00
tetienne
8bc77f0421 Add color to light template (#31435)
* Add color support to light template

* Add tests about color support
2020-02-03 08:27:01 -08:00
Yarmo Mackenbach
45c997ea04 Update NSAPI to 3.0.2 (#30971)
* Bump NSAPI version to 3.0.1

* Compatibility with NSAPI 3.0.1 response

* Removed commented code

* Obsolete setups receive an upgrade notification

* Bump NS-API to 3.0.2

* Assign platform values directly

* Removed obsolete config warning

* Improved reference to obsolete password
2020-02-03 14:39:45 +01:00
Vincent Le Bourlot
f49a392188 Add guard clause for discovery_info to tahoma platforms (#31434) 2020-02-03 13:30:44 +01:00
Paulus Schoutsen
e78378d90f Pass correct config to updater (#31428) 2020-02-03 09:51:27 +01:00
Raman Gupta
ee927fbc9e Bump pyvizio version and add additional device info (#31417)
* bump pyvizio version and add additional device info

* add patches for get_model and get_version

* change keywrod argument to positional for _test_service
2020-02-03 08:41:58 +01:00
Paulus Schoutsen
13aae8b5ec Bumped version to 0.105.0b6 2020-02-02 20:31:39 -08:00
springstan
744ae82933 Replace cmp option with eq and order (#31423) 2020-02-02 20:28:52 -08:00
Rami Mosleh
04cb2e9fd5 Rework Mikrotik device scanning following Unifi (#27484)
* rework device scanning, add tests

* update requirements and coverage

* fix description comments

* update tests, fix disabled entity updates

* rework device scanning, add tests

* update requirements and coverage

* fix description comments

* update tests, fix disabled entity updates

* update librouteros to 3.0.0

* fix sorting

* fix sorting 2

* revert to 2.3.0 as 3.0.0 requires code update

* fix requirements

* apply fixes

* fix tests

* update hub.py and fix tests

* fix test_hub_setup_failed

* rebased on dev and update librouteros to 3.0.0

* fixed test_config_flow

* fixed tests

* fix test_config_flow
2020-02-02 20:25:45 -08:00
HomeAssistant Azure
787faaa508 [ci skip] Translation update 2020-02-03 00:31:45 +00:00
Aaron Bach
2610415501 Streamline SimpliSafe data and token management (#31324)
* Streamline SimpliSafe API usage

* Streamline SimpliSafe data and token management

* Correctly define self.systems

* Inline update method
2020-02-02 17:16:09 -07:00
Paulus Schoutsen
4f79ec0c78 Bumped version to 0.105.0b5 2020-02-02 15:39:51 -08:00
Josh Bendavid
9dfc00898b always call set_volume with integer values (#31418) 2020-02-02 15:39:41 -08:00
Franck Nijhof
67e7541016 Fix device name Google Assistant when using aliases (#31416)
* Fix device name Google Assistant when using aliases

* Adjust cloud tests
2020-02-02 15:39:40 -08:00
Martin
2c1b465215 Emulated Hue + Alexa: Fix devices not discovered and error response (#30013 & #29899) (#31413)
* Revert "Emulated Hue: changed the reported fallback device-type to fix Alexa compatibility issues (#30013)"

This reverts commit ddc8d9e25c.

* Revert "Emulated Hue: updated tests (#30013)"

This reverts commit 90df461e75.

* Emulated Hue + Alexa: changed the fallback device-type again to "Dimmable Light" (#30013) after collective debugging; fixed brightness for on/off-devices and scripts to prevent "device malfunction" response from Alexa (#29899)

* Emulated Hue + Alexa: lint (#30013, #29899)
2020-02-02 15:39:39 -08:00
akasma74
3cbd426c52 Fix rflink commands containing equals sign (#31412)
* new lib verson available

* new rflink lib version

* new rflink lib version
2020-02-02 15:39:38 -08:00
FrengerH
a54d5f0bc4 deCONZ - Fix magic cube awake gesture (#31403) 2020-02-02 15:39:37 -08:00
Paulus Schoutsen
5b7a65c5ea Fix service annotations (#31402)
* Fix service annotations

* Filter area_id from service data

* Fix services not accepting entities

* Typo
2020-02-02 15:39:37 -08:00
springstan
fb26dd3028 Revert "Bump alarmdecoder to 1.13.9 (#30303)" (#31385)
This reverts commit f11d39f8eb.
2020-02-02 15:39:36 -08:00
Robert Svensson
aaea55efed deCONZ - Services normalize bridge id (#31378)
* Services should also make sure to normalize bridge id since users do not know to manage themselves
2020-02-02 15:39:35 -08:00
ochlocracy
d91f9fc2f5 Filter int in fan speed_list when yielding RangeController in Alexa (#31375)
* Allow for int in fan speed_list.

* Test for int in fan speed_list.

* prevent yielding preset for int labels.
2020-02-02 15:39:35 -08:00
Paulus Schoutsen
3b93065568 Add dump service to MQTT integration (#31370)
* Add dump service to MQTT integration

* Lint
2020-02-02 15:39:34 -08:00
Robert Svensson
59a9ca71ce deCONZ - Add support for new switch type (#31362) 2020-02-02 15:39:33 -08:00
springstan
11fcb2cc7f Fix auto_bypass in alarmdecoder (#30961)
* Fix auto_bypass in alarmdecoder

* Address review comments: used dict[key] and renamed variable

* Use dict[key] for required or optional config keys with default values
2020-02-02 15:39:32 -08:00
Paulus Schoutsen
7687ac8b91 Fix service annotations (#31402)
* Fix service annotations

* Filter area_id from service data

* Fix services not accepting entities

* Typo
2020-02-02 15:36:39 -08:00
Paulus Schoutsen
81dbdc6b9c Add dump service to MQTT integration (#31370)
* Add dump service to MQTT integration

* Lint
2020-02-02 15:01:51 -08:00
Martin
af105d2d61 Emulated Hue + Alexa: Fix devices not discovered and error response (#30013 & #29899) (#31413)
* Revert "Emulated Hue: changed the reported fallback device-type to fix Alexa compatibility issues (#30013)"

This reverts commit ddc8d9e25c.

* Revert "Emulated Hue: updated tests (#30013)"

This reverts commit 90df461e75.

* Emulated Hue + Alexa: changed the fallback device-type again to "Dimmable Light" (#30013) after collective debugging; fixed brightness for on/off-devices and scripts to prevent "device malfunction" response from Alexa (#29899)

* Emulated Hue + Alexa: lint (#30013, #29899)
2020-02-02 14:52:00 -08:00
Josh Bendavid
96ede54a1b always call set_volume with integer values (#31418) 2020-02-02 14:50:30 -08:00
Franck Nijhof
826433b680 Fix device name Google Assistant when using aliases (#31416)
* Fix device name Google Assistant when using aliases

* Adjust cloud tests
2020-02-02 14:48:13 -08:00
Robert Svensson
883b8f21ce deCONZ - Library cleanup (#31410)
* Follow library changes

* Bump dependency to v70

* Fix test
2020-02-02 19:07:20 +01:00
Jean-Paul van Ravensberg
f21a058f31 Enable SUPPORT_VOLUME_STEP (#31023) 2020-02-02 17:47:48 +01:00
Gerben ten Hove
75f1e573e4 Search specific train in Nederlandse Spoorwegen (#28898)
* Nederlandse Spoorwegen: search for specific trip

* Reformatting with Black

* Resolve pylint error

* Reformat with black.
2020-02-02 17:28:36 +01:00
Fabian Affolter
f701b2245a Upgrade alpha_vantage to 2.1.3 (#31388) 2020-02-02 17:27:06 +01:00
Björn Orri
8852cd0def Add Salt Fiber Box device tracker (#30986)
* Add salt component

* Update files from development checklist

* Use warning log level when data cannot be retrieved

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Remove empty fields from manifest.json

* Remove default arguments for host and username

* Bump saltbox library version

* Refactor and improve error handling

* Dev checklist

* Fix linting errors

* Check for None and return empty list

* Log on debug level instead of info

* More compact None checks

* Remove redundant None check

* Return None on exception but store as empty list

* More compact syntax

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-02-02 17:26:51 +01:00
akasma74
61a1d8e99f Fix rflink commands containing equals sign (#31412)
* new lib verson available

* new rflink lib version

* new rflink lib version
2020-02-02 17:23:13 +01:00
Daniel Perna
0f6e2850ab Update pyhomematic to 0.1.64 (#31406) 2020-02-02 16:29:10 +01:00
Fabian Affolter
f68a6ae3b2 Upgrade numpy to 1.18.1 (#31411) 2020-02-02 16:28:37 +01:00
Paulus Schoutsen
7127310f10 Catch device not found in device automations (#31401) 2020-02-02 07:13:07 -08:00
Arjan van Balken
55aa341dab Add unique_id to essent sensors (#31408)
* Fix mix-up of sensor entities and their values

* Prevent multiple calls for the same meter
2020-02-02 15:45:04 +01:00
Fabian Affolter
48402d49dc Upgrade praw to 6.5.1 (#31393) 2020-02-02 13:06:44 +01:00
Fabian Affolter
34aed53dcd Upgrade discord.py to 1.3.1 (#31391) 2020-02-02 13:05:50 +01:00
FrengerH
704cfcf235 deCONZ - Fix magic cube awake gesture (#31403) 2020-02-02 12:54:59 +01:00
Fabian Affolter
55a1bf3832 Upgrade holidays to 0.10.1 (#31392) 2020-02-02 02:17:24 -08:00
Fabian Affolter
83480291ce Upgrade sendgrid to 6.1.1 (#31394) 2020-02-02 02:16:33 -08:00
ochlocracy
e796de6c59 Filter int in fan speed_list when yielding RangeController in Alexa (#31375)
* Allow for int in fan speed_list.

* Test for int in fan speed_list.

* prevent yielding preset for int labels.
2020-02-01 16:44:40 -08:00
HomeAssistant Azure
a958418ef1 [ci skip] Translation update 2020-02-02 00:31:45 +00:00
Fabian Affolter
399173e3b3 Upgrade importlib-metadata to 1.5.0 (#31390) 2020-02-02 00:33:17 +01:00
Bernhard B
294c6a713f Support multiple attachments in signal messenger integration (#31141)
* added support for multiple attachments to signal_messenger integration

* updated pysignalclirestapi version in requirements_all.txt

* reworked multiple attachments feature in signal_messenger integration

* stay backwards compatible by both allowing the "attachment" and
  the "attachments" attribute.

* reworked multiple attachments feature in signal_messenger integration

* stay backwards compatible by both allowing the "attachment" and
  the "attachments" attribute.

* small change in signal_messenger integration

* added deprecation warning for 'attachment' attribute

* small changes in signal_messenger integration

* use 'warning' instead of 'warn' when logging the warning message

* re-generated requirements_test_pre_commit.txt

* added tests for signal_messenger integration

* regenerated requirements_test_all.txt for signal_messenger integration

* added more signal_messenger tests

* remove signal_messenger integration files from .coveragerc
2020-02-01 14:21:16 -08:00
Fabian Affolter
29aa1463ef Add PlatformNotReady 2020-02-01 23:04:42 +01:00
springstan
3aeaf3bb96 Revert "Bump alarmdecoder to 1.13.9 (#30303)" (#31385)
This reverts commit f11d39f8eb.
2020-02-01 22:02:39 +01:00
Frank van Ierland
e8b55552a1 Add temperature and humidity to xiaomi miio air quality monitor (#31287)
* Added new attributes to the Miio airquality monitor:
- temperature
- humidity

* updated Docstrings

* docstrings updated
2020-02-01 20:52:28 +01:00
Robert Svensson
1edaae34c5 UniFi - Log better information than a backtrace when poor switch data is involved (#31382) 2020-02-01 20:48:23 +01:00
Robert Svensson
43b11f6b39 deCONZ - Improve config flow logging (#31381) 2020-02-01 20:02:57 +01:00
Robert Svensson
e0704d73cc deCONZ - Services normalize bridge id (#31378)
* Services should also make sure to normalize bridge id since users do not know to manage themselves
2020-02-01 18:11:05 +01:00
dcnielsen90
9821047d75 Replace unmaintained BraviaRC backend with new fork: (#31234)
BraviaRC is currently unmaintained for home-assistant. This commit
    swaps it out with a new fork of BraviaRC called python-bravia-tv.
    This captures all bug fixes from BraviaRC release 3.7 (previously
    linked backend) to right before BraviaRC breaks when used by home-assistant.
    The intent of forking is to be able to continue supporting home-assistant.
    This is not intended to be a one off solution; this new fork will have
    future updates and be maintain as needed.

    This initial commit of python-bravia-tv improves the import process,
    however overall preserves the original API.
    Other fixes include:

    * Fix set-volume slider
    * Better error handling
    * Increase input options

    Resolves: #26351, #30964
    See also: #12577, #14843, #17345, #18245
2020-02-01 18:04:49 +01:00
Bas Nijholt
3275987f17 Add play, pause, previous and next track to kef (#31373)
* KEF: add support for play, pause, next track, and previous track

* bump aiokef to 0.2.7

* run isort

* do not dynamically change the supported features
2020-02-01 17:38:36 +01:00
Paulus Schoutsen
c67f53dc43 Remove hour delay before checking for updates (#31368)
* Check for updates at startup

* Add 100% test coverage for update_coordinator

* Address comments
2020-02-01 08:14:28 -08:00
Robert Svensson
b373c202c9 deCONZ - Add support for new switch type (#31362) 2020-02-01 17:08:49 +01:00
Ville Skyttä
dc5ca461a9 Run mypy through a pyenv/virtualenv enabler wrapper script (#30922) 2020-02-01 07:12:46 -08:00
Vincent Le Bourlot
79495d9f3a Add Tahoma lock support (#31311)
* Added lock support for tahoma

* Fixed logging to conform with pylint W1201 and E1205.

* Implemented @springstan suggestions.

* Fixed a typo...

* Implemented @springstan suggestions (v2).

* Implemented @springstan suggestions (v3).
2020-02-01 11:40:48 +01:00
Austin Mroczek
f584df46b7 Add totalconnect zones as binary sensors (#28712)
* Bump skybellpy to 0.4.0

* Bump skybellpy to 0.4.0 in requirements_all.txt

* Added extra states for STATE_ALARM_TRIGGERED to allow users to know if
it is a burglar or fire or carbon monoxide so automations can take
appropriate actions.  Updated TotalConnect component to handle these new
states.

* Fix const import

* Fix const import

* Fix const imports

* Bump total-connect-client to 0.26.

* Catch details of alarm trigger in state attributes.

Also bumps total_connect_client to 0.27.

* Change state_attributes() to device_state_attributes()

* Move totalconnect component toward being a multi-platform integration.  Bump total_connect_client to 0.28.

* add missing total-connect alarm state mappings

* Made recommended changes of MartinHjelmare at
https://github.com/home-assistant/home-assistant/pull/24427

* Update __init__.py

* Updates per MartinHjelmare comments

* flake8/pydocstyle fixes

* removed . at end of log message

* added blank line between logging and voluptuous

* more fixes

* Adding totalconnect zones as HA binary_sensors

* fix manifest.json

* flake8/pydocstyle fixes.  Added codeowner.

* Update formatting per @springstan guidance.

* Fixed pylint

* Add zone ID to log message for easier troubleshooting

* Account for bypassed zones in update()

* More status handling fixes.

* Fixed flake8 error

* Another attempt at black/isort fixes.

* Bump total-connect-client to 0.50.  Simplify code using new functions in
total-connect-client package instead of importing constants.  Run black
and isort.

* Fix manifest file

* Another manifest fix

* one more manifest fix

* more manifest changes.

* sync up

* fix indent

* one more pylint fix

* Hopefully the last pylint fix

* make variable names understandable

* create and fill dict in one step

* Fix name and attributes

* rename to logical variable in alarm_control_panel

* Remove location_name from alarm_control_panel attributes since it is
already the name of the alarm.

* Multiple fixes to improve code per @springstan suggestions

* Update homeassistant/components/totalconnect/binary_sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Multiple changes per @MartinHjelmare review

* simplify alarm adding

* Fix binary_sensor.py is_on

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-02-01 10:09:52 +01:00
springstan
26415f6abd Fix auto_bypass in alarmdecoder (#30961)
* Fix auto_bypass in alarmdecoder

* Address review comments: used dict[key] and renamed variable

* Use dict[key] for required or optional config keys with default values
2020-02-01 10:01:42 +01:00
Paulus Schoutsen
d382b0ba42 Bumped version to 0.105.0b4 2020-02-01 00:29:29 -08:00
Dan Lehman
e1fd46d6db Updated wemo lights fix for #31360 (#31369) 2020-02-01 00:29:21 -08:00
Dan Lehman
0a90b01e77 Updated wemo lights fix for #31360 (#31369) 2020-01-31 21:42:37 -08:00
HomeAssistant Azure
0c1acc51a4 [ci skip] Translation update 2020-02-01 00:31:40 +00:00
Paulus Schoutsen
7ef352701c Bumped version to 0.105.0b3 2020-01-31 14:48:26 -08:00
Paulus Schoutsen
25d6bc348c Fix wemo device types for lights (#31360) 2020-01-31 14:48:20 -08:00
David F. Mulcahey
8f8468f016 bump quirks (#31355) 2020-01-31 14:48:19 -08:00
ochlocracy
f26cb83fd5 Protect for unknown state attributes. (#31354) 2020-01-31 14:48:18 -08:00
Franck Nijhof
7ee741d424 Partially Revert "Deprecate hide_if_away from device_tracker (#30833) (#31348) 2020-01-31 14:48:17 -08:00
Johann Kellerman
ec3dc3dd16 Upgrade pysma, fix #27154 (#31346) 2020-01-31 14:48:16 -08:00
Paulus Schoutsen
283cc5c8c3 Update Hue data fetching (#31338)
* Refactor Hue Lights to use DataCoordinator

* Redo how Hue updates data

* Address comments

* Inherit from Entity and remove pylint disable

* Add tests for debounce
2020-01-31 14:48:16 -08:00
Paulus Schoutsen
166d770ddd Update Hue data fetching (#31338)
* Refactor Hue Lights to use DataCoordinator

* Redo how Hue updates data

* Address comments

* Inherit from Entity and remove pylint disable

* Add tests for debounce
2020-01-31 14:47:40 -08:00
Malachi Soord
ae76b5be5a Let core resolve entity_id for lastfm from username (#31280)
* Sluggify user

* Simplify

* Remove unused import
2020-01-31 14:23:42 -08:00
escoand
d225fc08fe drop fritzdect (#31359) 2020-01-31 14:20:06 -08:00
ochlocracy
fa2e409abd Protect for unknown state attributes. (#31354) 2020-01-31 14:14:43 -08:00
Paulus Schoutsen
06efe3a2f6 Fix wemo device types for lights (#31360) 2020-01-31 14:01:25 -08:00
Robert Svensson
44f0728c60 Axis - Use core to start component tests (#31328)
* Fix test according to Martins comment in 31286

* Use core features rather than integration specific

* Fix populate options test
2020-01-31 20:23:51 +01:00
Robert Svensson
958a867c11 UniFi integration move to push messaging (#31086)
* Rewrite UniFi integration to use push messaging

* Add signalling for new clients/devices

* Update list of known wireless clients when we get events of them connecting

* Reconnection logic for websocket

* Fix failing tests

* Bump requirement to v12

* Add new tests

* Update homeassistant/components/unifi/controller.py

Co-Authored-By: Martin Hjelmare <marhje52@gmail.com>
2020-01-31 20:23:25 +01:00
David F. Mulcahey
06c8e53323 bump quirks (#31355) 2020-01-31 13:55:06 -05:00
Christian Clauss
df7d2b3aeb Fix typos found by codespell (#31243)
* Fix typos found by codespell

* Fix typos found by codespell

* codespell: Furture  ==> Future

* Update test_config_flow.py

* Update __init__.py

* Spellcheck: successfull  ==> successful

* Codespell: unsuccesful  ==> unsuccessful

* Codespell: cant  ==> can't

* Codespell: firware ==> firmware

* Codespell: mimick  ==> mimic
2020-01-31 08:33:00 -08:00
Franck Nijhof
a017c26234 Partially Revert "Deprecate hide_if_away from device_tracker (#30833) (#31348) 2020-01-31 08:27:16 -08:00
Johann Kellerman
ab3157e661 Upgrade pysma, fix #27154 (#31346) 2020-01-31 08:25:54 -08:00
Raman Gupta
a0067a298a Remove Throttle on async_setup and bump pyvizio version (#31337) 2020-01-31 12:45:23 +01:00
Pascal Vizeli
1aa322f2f0 Bump version to 0.105.0b0 2020-01-31 10:26:09 +00:00
Paulus Schoutsen
7b3dc42673 Fix incorrect annotation async flock notify (#31342)
* Fix incorrect annotation async flock notify

* Update notify.py

* Update notify.py

Co-authored-by: Pascal Vizeli <pascal.vizeli@syshack.ch>
2020-01-31 09:58:54 +00:00
Paulus Schoutsen
6a7bb7b149 Fix incorrect annotation async flock notify (#31342)
* Fix incorrect annotation async flock notify

* Update notify.py

* Update notify.py

Co-authored-by: Pascal Vizeli <pascal.vizeli@syshack.ch>
2020-01-31 10:58:27 +01:00
Paulus Schoutsen
c6baf026a7 Guard for callbacks in service helper (#31339) 2020-01-31 09:24:02 +00:00
Phil Bruckner
a53c3d10fe Fix async bug in amcrest when registering services (#31334) 2020-01-31 09:24:00 +00:00
Martin
3635c4df50 Emulated Hue: changed fallback device-type to fix Alexa compatibility issues (#30013) (#31330)
* Emulated Hue: changed the reported fallback device-type to fix Alexa compatibility issues (#30013)

* Emulated Hue: updated tests (#30013)
2020-01-31 09:23:58 +00:00
Paulus Schoutsen
73f27c728c Fix wemo lights (#31323) 2020-01-31 09:23:56 +00:00
Paulus Schoutsen
6b95e98eeb Guard Z-Wave light HS conversion on None (#31320) 2020-01-31 09:23:54 +00:00
Paulus Schoutsen
d405069406 Guard for callbacks in service helper (#31339) 2020-01-31 09:32:43 +01:00
Martin
b22dfa119b Emulated Hue: changed fallback device-type to fix Alexa compatibility issues (#30013) (#31330)
* Emulated Hue: changed the reported fallback device-type to fix Alexa compatibility issues (#30013)

* Emulated Hue: updated tests (#30013)
2020-01-30 23:30:13 -08:00
Phil Bruckner
7e9507833b Fix async bug in amcrest when registering services (#31334) 2020-01-30 23:28:53 -08:00
HomeAssistant Azure
74413e07d0 [ci skip] Translation update 2020-01-31 00:31:57 +00:00
Franck Nijhof
611127a6bc Bump pytest to 5.3.5 (#31327) 2020-01-31 00:04:59 +01:00
Robert Svensson
a8374cf423 UniFi - Try to discover local controller (#31326)
* Its working

* Use "unifi" as default host if a controller can be found

* Fix tests

* Make a fixture of patching the discovery function
2020-01-30 23:06:43 +01:00
Robert Svensson
56657fa859 Axis - config flow use new helper functions (#31286)
* Make use of new config flow helpers
Simplify Axis entry config to work with config flow helpers

* Keep old device data for rollback purposes
2020-01-30 22:20:30 +01:00
SukramJ
cd1aa46404 Register on HA stop event to gracefully shutdown HomematicIP Cloud connections (#31289)
* Register on HA stop event to gracefully shutdown HomematicIP Cloud connections

* fixes after review

* Fix lint

* switch to unload_entry

* Save listener

* Switch back to hap.async_reset()
2020-01-30 22:14:43 +01:00
Raman Gupta
73ea34e417 Update media_player and add tests to qualify vizio integration for platinum quality score (#31187)
* add media player test and update media player logic to qualify vizio for platinum quality score

* add SCAN_INTERVAL and log message once when device goes from available to unavailable and vice versa

* move test constants into one file to avoid defining dupes in each test file

* move constant to shrink diff

* move pytest fixtures to conftest.py

* remove commented out code

* move unload test to test_init

* updates to tests and logging based on review

* bypass notification service

* add fixture so component setup makes it through config flow

* split failure tests into two

* fix setup and entity check for test_init and setup failures in test_media_player

* make domain references consistent across test files

* remove logging steps that were introduced to help debug

* move common patches out to new fixture and use config entry everywhere appropriate

* fix docstring

* add test for update options to increase code coverage

* add one more assert

* refactor test_media_player to move boiler plate logic out of each test into _test_init function

* final refactor of test_media_player to move repeat logic into separate function

* update docstrings

* refactor setup failure tests to move shared logic into private function

* fix last new functions code to use variable instead of static config variable

* remove trailing comma

* test that volume_step gets properly passed to Vizio volume function

* fix comment language

* assert with unittest.mock.call in _test_service and use config_entries.async_setup instead of config_entries.async_add

* replace config_entries.async_add with config_entries.async_setup everywhere

* simplify if statement for argument assertion

* fix logging based on style guide

* remove accidentally committed changes

* update scan interval to something more reasonable and add tests for availability changes

* change filter function to list comprehension, simplify log messages, remove default entity id from logs since it is user configurable, fix docstrings
2020-01-30 22:13:45 +01:00
endor
9ab6d08b97 Bump pytrafikverket to 0.1.6.1 (#30697)
* Bumped version for pytrafikverket

* Updated version for pytrafikverket

* Updated version for pytrafikverket
2020-01-30 21:46:20 +01:00
Rick
3718b25bd9 Add opening and closing states to MQTT covers (#31259)
* Added support for the opening and closing states to MQTT covers

* Processed PR feedback on MQTT cover changes

* Add missing MQTT abbreviation to fix failing tests

* Fixed typo in MQTT abbreviations

* Added mqtt set cover position optimistic test
2020-01-30 21:14:46 +01:00
Paulus Schoutsen
d5486f883d Fix wemo lights (#31323) 2020-01-30 11:40:16 -08:00
Paulus Schoutsen
d6d3feb54e Guard Z-Wave light HS conversion on None (#31320) 2020-01-30 11:13:54 -08:00
Rami Mosleh
9432054066 Rework Mikrotik device scanning following Unifi (#27484)
* rework device scanning, add tests

* update requirements and coverage

* fix description comments

* update tests, fix disabled entity updates

* rework device scanning, add tests

* update requirements and coverage

* fix description comments

* update tests, fix disabled entity updates

* update librouteros to 3.0.0

* fix sorting

* fix sorting 2

* revert to 2.3.0 as 3.0.0 requires code update

* fix requirements

* apply fixes

* fix tests

* update hub.py and fix tests

* fix test_hub_setup_failed

* rebased on dev and update librouteros to 3.0.0

* fixed test_config_flow

* fixed tests

* fix test_config_flow
2020-01-30 10:21:51 -08:00
Paulus Schoutsen
202fd4197b Bumped version to 0.105.0b1 2020-01-30 09:48:00 -08:00
Paulus Schoutsen
e91c32cb00 Fix HTTP config serialization (#31319) 2020-01-30 09:47:50 -08:00
Bram Kragten
af8b63fe31 Updated frontend to 20200130.0 (#31318) 2020-01-30 09:47:49 -08:00
Paulus Schoutsen
afe869bee9 Handle service calls that do not refer entity IDs (#31317) 2020-01-30 09:47:49 -08:00
Paulus Schoutsen
f55193c2da Add zone to defaul config (#31303) 2020-01-30 09:47:48 -08:00
Paulus Schoutsen
9db2ad1fd7 Add zones services.yaml (#31298) 2020-01-30 09:47:47 -08:00
Alexei Chetroi
268430a61d ZHA dependencies bump (#31295)
* ZHA dependencies bump.

* Bump bellows-homeassistant.
2020-01-30 09:47:47 -08:00
Paulus Schoutsen
33361f8580 Fix HTTP config serialization (#31319) 2020-01-30 09:47:16 -08:00
Bram Kragten
0a1e397119 Updated frontend to 20200130.0 (#31318) 2020-01-30 09:30:59 -08:00
Paulus Schoutsen
d24e397a80 Handle service calls that do not refer entity IDs (#31317) 2020-01-30 09:28:06 -08:00
Alexei Chetroi
24f4f53f16 ZHA dependencies bump (#31295)
* ZHA dependencies bump.

* Bump bellows-homeassistant.
2020-01-30 10:04:06 -05:00
Franck Nijhof
981d963554 Upgrade pre-commit to 2.0.1 (#31308) 2020-01-30 13:08:37 +01:00
Tom Harris
7ff30fe29d Reorganize insteon code (#31183)
* Reorganize code

* Code review
2020-01-30 10:47:44 +01:00
Paulus Schoutsen
ea666248ce Add zones services.yaml (#31298) 2020-01-30 10:09:06 +01:00
Paulus Schoutsen
cad451d2b7 Add zone to defaul config (#31303) 2020-01-30 10:06:17 +01:00
Paulus Schoutsen
da14e2927f Removes I/O from linky tests (#31299) 2020-01-29 21:59:24 -08:00
Alan Tse
cf0e467150 Change scan_interval defaults for Tesla (#31194) 2020-01-29 20:15:47 -05:00
HomeAssistant Azure
8c178adf4f [ci skip] Translation update 2020-01-30 00:31:41 +00:00
Paulus Schoutsen
6499feffa3 Bumped version to 0.105.0b0 2020-01-29 16:30:03 -08:00
Paulus Schoutsen
c4a8af06e0 Merge remote-tracking branch 'origin/master' into dev 2020-01-29 16:29:36 -08:00
Paulus Schoutsen
01dad31adc Fix service helper not handling sync methods (#31254)
* Fix service helper not handling sync methods

* Add legacy support for returning coroutine objects

* Fix tests

* Fix tests

* Convert demo cover to async
2020-01-29 16:27:25 -08:00
Robert Svensson
111fc1fa8e Use all new helper functions (#31278) 2020-01-29 16:21:23 -08:00
Paulus Schoutsen
424e15c7a7 Find related items scripts/automations (#31293)
* Find related items scripts/automations

* Update manifest
2020-01-29 16:19:13 -08:00
Paulus Schoutsen
881437c085 Catch error when searching for scenes or automations (#31288) 2020-01-29 14:46:48 -08:00
Paulus Schoutsen
e9e44dbd97 Fix callback and async (#31281)
* Fix callback and async

* Fix a return

* Fix test

* Fix mqtt tests

* Fix some more callbacks
2020-01-29 13:59:45 -08:00
ktnrg45
ee602e40a6 Add command 'ps_hold' to PS4 (#31283) 2020-01-29 22:57:40 +01:00
Bram Kragten
67b73bd74c Updated frontend to 20200129.0 (#31279) 2020-01-29 21:40:41 +01:00
Jeff Irion
31dc2ad284 Allow filtering of sources for Android TV (#30994) 2020-01-29 14:13:09 -06:00
Phil Bruckner
61e41f0ddc Add code owner for amcrest integration (#31276) 2020-01-29 11:50:18 -06:00
David F. Mulcahey
f4a4c6bea5 ZHA group and device cleanup (#31260)
* add dispatching of groups to light
* added ha device registry device id
* added zha group object
* add group event listener
* add and remove group members
* get group by name
* api cleanup
* clean up get device info
* create and remove zigpy groups
* clean up create and remove group api
* use device id
* use device id
* cleanup
* update test
* update tests to allow group events to flow
2020-01-29 12:24:43 -05:00
Pascal Vizeli
6bbb713013 Fix tests for opnsense (#31277) 2020-01-29 18:18:24 +01:00
ochlocracy
83dff16e1e Add support for rangeValueDeltaDefault in Alexa AdjustRangeValue directive (#31258)
* Update tests with rangeValue and rangeValueDelta to use int.

* Add support for rangeValueDeltaDefault for covers.

* Update tests for range changes.

* Test for AdjustRangeValue with rangeValueDeltaDefault True.

* Update tilt error.
2020-01-29 09:04:57 -08:00
ochlocracy
7116c7404a Add PowerController to covers in Alexa (#31265)
* Add PowerController to covers.

* Comment Fix.

* Update test device_class.

* Update Comment.
2020-01-29 09:03:20 -08:00
Matthew Treinish
85dbf1ffad Add OPNSense device tracker (#26834)
* Add OPNSense device_tracker

This commit adds a new component for using an OPNSense router as a
device tracker. It uses pyopnsense to query the api to look at the
arptable for a list of devices on the network.

* Run black formatting locally to appease azure

* Apply suggestions from code review

Co-Authored-By: Fabian Affolter <mail@fabian-affolter.ch>

* Fix issues identified during code review

This commit updates several issues found in the module during code
review.

* Update homeassistant/components/opnsense/__init__.py

Co-Authored-By: Fabian Affolter <mail@fabian-affolter.ch>

* Update CODEOWNERS for recent changes

* Fix lint

* Apply suggestions from code review

Co-Authored-By: Martin Hjelmare <marhje52@kth.se>

* More fixes from review comments

This commit fixes several issues from review comments, including
abandoning all the use of async code. This also completely reworks the
tests to be a bit clearer.

* Revert tests to previous format

* Add device detection to opnsense device_tracker test

This commit adds actual device detection to the unit test for the setup
test. A fake api response is added to mocks for both api clients so that
they will register devices as expected and asserts are added for that.

The pyopnsense import is moved from the module level to be runtime in
the class. This was done because it was the only way to make the
MockDependency() call work as expected.

* Rerun black

* Fix lint

* Move import back to module level

* Return false on configuration errors in setup

This commit updates the connection logic to return false if we're unable
to connect to the configured OPNsense API endpoint for any reason.
Previously we would not catch if an endpoint was incorrectly configured
until we first tried to use it. In this case it would raise an unhandled
exception. To handle this more gracefully this adds an api call early in
the setup and catches any exception raised by that so we can return
False to indicate the setup failed.

* Update tests

* Add pyopnsense to test requirements

* Rerun gen_requirements script

* Fix failing isort lint job step

Since opening the PR originally yet another lint/style checker was added
which failed the PR in CI. This commit makes the adjustments to have
this pass the additional tool's checks.

* Fix comment

* Update manifest.json

Co-authored-by: Fabian Affolter <mail@fabian-affolter.ch>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Pascal Vizeli <pascal.vizeli@syshack.ch>
2020-01-29 16:20:43 +01:00
Jeff Irion
9312d06fe4 Catch 'ConnectionResetError' exceptions for Android TV integra… (#31274) 2020-01-29 15:18:57 +01:00
Quentame
ec4ccb10ec Bump iCloud to 0.9.2 + fix setup log (#31273)
- pyicloud to 0.9.2
- fix log `ERROR (MainThread) [homeassistant.config_entries] icloud.async_setup_entry did not return boolean`
2020-01-29 15:16:54 +01:00
tetienne
fa15bead94 Remove useless assignment (#31272) 2020-01-29 14:08:53 +01:00
Alan Tse
a1e1610a69 Add device_class to Tesla sensors (#31231) 2020-01-29 13:22:04 +01:00
Thibault Maekelbergh
64edf2fe33 Create truly live unique id (#31078)
* Create truly live unique id

* Do not generate unique id on basis of name

* Add the station to the default station live name
2020-01-29 12:12:40 +01:00
Rafał Słota
080827fb62 Fix light.turn_on for emulated_hue (#31195)
* Fix light.turn_on for emulated_hue

HarmonyHub sends `{'xy': [0, 0], 'on': True, 'bri': 0}` when turning on lights that do not support brightness control. Unfortunately current logic always uses  brightness value to control on/off state which makes no sense for lights that don't support brightness at all. This change fixes that behavior, making light without brightness control usable with HarmonyHub and probably some other remotes.

* Test 'no_brightness' lights
2020-01-29 12:11:22 +01:00
Thomas
56c235d4f2 Fix example for set_datetime service (#31159) 2020-01-29 12:09:19 +01:00
Matthias Alphart
9ff9614d0b fix knx light turn_on with ct (#31184)
process both brightness and color_temperature in a turn_on call.
2020-01-29 12:07:25 +01:00
Franck Nijhof
c2f1d6aa19 Upgrade pre-commit to 2.0.0 (#31267) 2020-01-29 12:04:25 +01:00
Pascal Vizeli
28bfc6ae76 Update homeassistant-pyozw to 0.1.8 (#31270) 2020-01-29 12:04:05 +01:00
Daniel Perna
9902b648fb Add channel-mapping for HomeMatic (#31178)
* Update entity.py

* Fix Black

* Fix Black

* Update entity.py

* Use new style python

* Simplify

* Allow multible attribute with different channels

* Black

Co-authored-by: Pascal Vizeli <pascal.vizeli@syshack.ch>
2020-01-29 12:02:36 +01:00
Alan Tse
bcdef4e500 Fix reporting of battery sensor for Tesla (#31232)
* Fix reporting of battery sensor for Tesla

* Remove try
2020-01-29 08:58:43 +01:00
Bouwe Westerdijk
61a8618010 Fix Plugwise climate issues (#31209)
* Fix Plugwise climate issues

* Remove showing None-state for available_schemas, as requested by reviewer.
2020-01-29 08:57:25 +01:00
Bas Nijholt
89ae255de7 Bump pyhaversion to 3.2.0 (#31241)
* upgrade to pyhaversion=3.2.0

* bump to pyhaversion==3.2.0 in manifest.json
2020-01-29 08:54:21 +01:00
shred86
3ae5735e12 Bump abodepy version to 0.17.0 (#31250) 2020-01-29 08:53:30 +01:00
Robert Svensson
36675fe4fa deCONZ - New light level sensor attribute (#31255) 2020-01-29 07:40:42 +01:00
Alexei Chetroi
37af2170ec Mark device unavailable when it leaves Zigbee network. (#31264) 2020-01-28 21:21:33 -05:00
HomeAssistant Azure
2c02334c1f [ci skip] Translation update 2020-01-29 00:31:54 +00:00
Franck Nijhof
fd4f8d92d2 Upgrade dsmr_parser to 0.18, re-enable tests (#31256) 2020-01-28 23:35:28 +01:00
Franck Nijhof
747f5fd62c Upgrade iaqualink to 0.3.1 (#31257) 2020-01-28 23:33:27 +01:00
John Hollowell
c3cef7227c Add proxmoxve SSLError check and remove log spam (#30818)
* Add SSLError check and remove log spam

* Update homeassistant/components/proxmoxve/manifest.json

remove unnecessary requirement

* Remove log level change

Moved to proxmoxer library

* Update homeassistant/components/proxmoxve/__init__.py

* Update manifest.json

Update to new version of dependency which fixes log issue

* Run formatter and requires updates

* oops, tabs

* Fix quote marks

When you can't get black running, just fix whatever CI says is wrong!
2020-01-28 22:52:59 +01:00
Paulus Schoutsen
8ceef72853 Google Assistant: Track if request is local (#31226)
* Track if request is local

* Cancel early if 2FA disabled

* Allow disabling 2FA for ack

* Do not mark devices with 2FA as reachable

* Add request source to GA events
2020-01-28 10:54:39 -08:00
brefra
03954be12d Add brefra to codeowners list Velbus integration (#31245)
* Add myself to codeowners list

* Add myself to CODEOWNERS file
2020-01-28 09:25:15 -05:00
Daniel Høyer Iversen
a9c43c6c62 Mill, correct hvac_mode. Fixes #31236 (#31242) 2020-01-28 11:58:37 +01:00
Pascal Vizeli
259a7e8490 Add gammu to wheels (#31239) 2020-01-28 09:41:50 +01:00
Oscar Calvo
d813618d0d Add Gammu based local SMS notifications (#31233)
* Add sms integration

Committer: ocalvo <oscar@calvonet.com>

* Fix PyLint

* Update requirements
2020-01-28 09:35:41 +01:00
SukramJ
ec2d378a19 Add test for adding a device to HomematicIP Cloud (#31224)
* Add test for adding a hmip device

* refactor get_mock_hap to use config_entry setup

* remove unused parameters
2020-01-28 08:44:30 +01:00
Alexei Chetroi
9d8b4de09c Update ZHA entity discovery tests (#31191)
* ZHA registry test fixtures refactoring.

* Update ZHA test devices list.

* Use channel.id for event relay channels test.

* Add zigpy_device factory fixture.

* Add node descriptor to mock zigpy devices.

* Use node descriptor for ZHA device tests.

* Update ZHA discovery test.

check for unique_id and channels passed into each entity.

* Address comments.
2020-01-27 19:43:26 -05:00
HomeAssistant Azure
6daec557b4 [ci skip] Translation update 2020-01-28 00:31:59 +00:00
Paul Daumlechner
ed970797be Fix attribute in Alexa service call for cover tilt (#31223)
* Update attribute in Alexa service call for cover tilt

* Update Tests to fix Tilt Position call.

Co-authored-by: ochlocracy <5885236+ochlocracy@users.noreply.github.com>
2020-01-27 19:28:40 -05:00
aaska
1f7ab9091b Bump python-synology to 0.4.0 : Add support for DSM v5 + fix sensors unknown for 15 min (#31049)
* updating new api version

* Added new configuration option for updated API
2020-01-27 22:38:00 +01:00
SukramJ
1dbfc66669 Cleanup of HomematicIP Cloud tests (#31181)
* CleanUp tests for HomematicIP_Cloud

* Remove not required CoroutineMock

* remove None return in mocks, add asserts

* rewrite test
2020-01-27 21:34:15 +01:00
Christian Clauss
1d537ad416 Fix typo: serivce --> service (#31217) 2020-01-27 19:56:26 +01:00
Paulus Schoutsen
ab8b94382e Update Hue discovery (#31215) 2020-01-27 10:54:38 -07:00
Aaron Bach
f95a072877 Constrain SimpliSafe's check for emergency token usage (#31214) 2020-01-27 10:50:16 -07:00
Ron Klinkien
4e2737bfb7 Add Garmin Connect integration (#30792)
* Added code files

* Correctly name init file

* Update codeowners

* Update requirements

* Added code files

* Correctly name init file

* Update codeowners

* Update requirements

* Black changes, added to coveragerc

* Removed documentation location for now

* Added documentation url

* Fixed merge

* Fixed flake8 syntax

* Fixed isort

* Removed false check and double throttle, applied time format change

* Renamed email to username, used dict, deleted unused type, changed attr name

* Async and ConfigFlow code

* Fixes

* Added device_class and misc fixes

* isort and pylint fixes

* Removed from test requirements

* Fixed isort checkblack

* Removed host field

* Fixed coveragerc

* Start working test file

* Added more config_flow tests

* Enable only most used sensors by default

* Added more default enabled sensors, fixed tests

* Fixed isort

* Test config_flow  improvements

* Remove unused import

* Removed redundant patch calls

* Fixed mock return value

* Updated to garmin_connect 0.1.8 fixed exceptions

* Quick fix test patch to see if rest is error free

* Fixed mock routine

* Code improvements from PR feedback

* Fix entity indentifier

* Reverted device identifier

* Fixed abort message

* Test fix

* Fixed unique_id MockConfigEntry
2020-01-27 09:12:18 -08:00
Quentame
a73a1a4489 Use config_entry.unique_id in Linky (#31051)
* Use config_entry.unique_id in Linky

* Reviews

* _show_setup_form not async
2020-01-27 08:57:36 -08:00
ktnrg45
d3ac3e48a3 Fix ps4 errors if pin begins with a 0 (#31198)
* Fix errors if pin begins with a 0

* Test PIN leading with zero

* Edit tests
2020-01-27 10:32:14 -05:00
David F. Mulcahey
7d9c8fdfa0 update remove service (#31164) 2020-01-27 08:54:31 -05:00
Ron Klinkien
50b0e938e1 Added missing file (#31189) 2020-01-27 12:52:58 +01:00
Franck Nijhof
6be9a45333 Upgrade HAP-python to 2.7.0 (#31201) 2020-01-27 11:42:09 +01:00
Alan Tse
4f07ccd350 Fix unnecessary regeneration of access token in Tesla component (#31193)
* Fix unnecessary regeneration of access token

* Add manifest.json
2020-01-27 11:30:35 +01:00
Franck Nijhof
050e4afdc0 Disable failing dsmr tests (#31202)
* Disable failing dsmr tests

* Disable module, disable import of missing dep
2020-01-27 11:13:36 +01:00
Rohan Kapoor
52c1bc9c26 Check that documentation urls are valid (#31188)
* Check that documentation urls are valid

* Validate documentation url in pieces
2020-01-27 10:42:26 +01:00
starkillerOG
1278f32306 Add webostv sound_output capability (#31121)
* Webostv: add sound_output capability

Add the ability to read and set the sound_output

* Webostv: add sound_output capability

* Webostv: add sound_output capability

* fix blank spaces

* fix to long line

* add ,

* Import ATTR_SOUND_OUTPUT

Do not have the ability to test this change right now

* Add white space

* Create const.py

* Use const import

* Use import from const.py

* Add docstring

* Change order

* Change order

* Fix import

* Fix import

* Fix typo

* Change order again

* Change order again

* Change order of attributes
2020-01-27 10:40:48 +01:00
Paulus Schoutsen
1f0f62de7f Add unique IDs to automation/scenes (#31150)
* Add unique IDs to automation and scenes

* Fix typo
2020-01-26 23:01:35 -08:00
Ville Skyttä
8fff6462a1 Upgrade huawei-lte-api to 1.4.7 (#31155)
https://github.com/Salamek/huawei-lte-api/releases/tag/1.4.7
2020-01-27 08:50:01 +02:00
Aaron Bach
ac2172333c Use non-deprecated method of instantiating RainMachine client (#31149) 2020-01-26 18:01:59 -07:00
finnysamuel
9ba1a4a91a Bump aiobotocore to 0.11.1 (#30951)
* Bumped aiobotocore version to 0.11.1
* New dependencies are added to requirements_all.txt
2020-01-26 18:25:42 -05:00
Franck Nijhof
aa390efd69 Add hassfest URL validation to documentation link (#31143) 2020-01-26 21:32:20 +01:00
Tom Harris
4311b1ae65 Bump insteonplm to 0.16.6 (#31182) 2020-01-26 19:53:31 +01:00
brefra
51e032a7ca Add counters sensors for Velbus (#31165)
* Add counter sensor

* Apply black formatting

* Move all counter logic to sensor.py

* Code cleanup
2020-01-26 18:48:20 +01:00
SukramJ
1b3c4ed4b3 Use unique_id for config_entries of HomematicIP Cloud (#31133)
* use hapid as unique_id for config_entry of HomematicIP Cloud

* Add qualita_scale to manifest

* Update config_flow

* use core interface for config_flow tests

* refactor to fail earlier

* use asynctest

* rewrite tests

* rewrite tests

* fix test

* add assert
2020-01-26 14:54:33 +01:00
Maikel Punie
3f03848a07 Fix Velbus covers (includes velbus lib upgrade) (#31153)
* Fix velbus covers

* Update python-velbus lib

* flake8 and black fixes

* Fix comments

* fix codeowner
2020-01-26 14:36:29 +01:00
Malachi Soord
bc196a3c9f Introduce unique_id for lastfm to allow changing entity_id in backwards compatible way (#31163)
* Replace . with _ for lastfm entity_id

* lint

* double quotes

* Rollback change, add unique_id

* Expose prop

* Generate unique ID from user

* Linty

* FIx linter

* Revert changes for splitting entity_id

* Simplify
2020-01-26 14:28:42 +01:00
Jeff Irion
cd72128a80 Implement 'volume_set' service for Android TV devices (#31161) 2020-01-26 10:39:19 +01:00
Aaron Bach
4c4f726323 Refactor RainMachine switch platform (#31148)
* Import constants sanely

* Linting

* Rename data constants for consistency

* Refactor RainMachine switch platform

* Comments

* Cleanup

* Refactor switch and sensor API calls to be separate

* Linting

* Make sure zones are updated in appropriate service calls

* Correctly decrement

* Linting

* Don't do weird inheritance

* Ensure service calls update data properly

* Docstring

* Docstring

* Errors can be logged without string conversion

* Code review comments
2020-01-25 20:27:35 -07:00
Aaron Bach
37d1cdc4cb Add additional alarm states to SimpliSafe (#31060)
* Add additional alarm states to SimpliSafe

* Remove unused constant

* Remove redundant local variable
2020-01-25 18:41:49 -07:00
HomeAssistant Azure
d3511a3496 [ci skip] Translation update 2020-01-26 00:33:06 +00:00
Jens Østergaard Nielsen
353a014496 Fix the ihc.set_runtime_value_int service function not working with templates (#31145)
* Make the set_runtime_value_int function work with template values

* Use newest version of the ihcsdk library

* Make the set_runtime_value_int function work with template values

* Use newest version of the ihcsdk library

* Updated to the newest ihcsdk 2.5.0

* Formatted changes to make it pass CI tests
2020-01-26 00:37:31 +01:00
Matt Snyder
e4832ee4d0 Remove Owlet component (#31160)
* Remove owlet component

* Remove owlet from requirements_all.txt
2020-01-25 21:08:36 +01:00
Quentame
c481a48e3a Separate iCloud class (#31022)
* Separate iCloud class

* Update .coveragerc

* Fix pipe
2020-01-25 13:24:50 -05:00
Josh Bendavid
6f1c45257a Fix state handling for older webos versions (#31099)
* fix state handling for older webos versions

* update aiopylgtv to 0.3.2
2020-01-25 13:24:21 -05:00
Bill Durr
e16e192b3c improvements to zha cover (#31144) 2020-01-25 13:20:59 -05:00
Alexei Chetroi
217e280f8b Update ZHA remotes registry to proper identify "remotes (#31146)
* Update ZHA remote device types.

* Remove `binary_sensor` entity from affected devices.

* Update ZHA Profiles.

Prevent DeviceType.ON_OFF_LIGHT_SWITCH from creating entities.

* Update tests and remove unused entities.
2020-01-25 12:42:19 -05:00
Ville Skyttä
80a55360dc Remove no longer used Hound config (#31154) 2020-01-25 12:48:32 +01:00
Ville Skyttä
98ac84349c Fix Huawei LTE SMS recipient setting from options UI (#31117)
* Fix Huawei LTE SMS recipient setting from options UI

Refs https://github.com/home-assistant/home-assistant/issues/30827

* Use core interfaces in tests

* ...more
2020-01-25 13:09:43 +02:00
Aaron Bach
a007835293 Fix RainMachine update action (#31147) 2020-01-24 23:42:59 -07:00
Aaron Bach
550aa6a0a5 Add smarter API usage for RainMachine (#31115)
* Make RainMachine smarter with API usage

* Remove debug statements

* Fix deregistration

* Code review comments

* Code review

* Use an asyncio.Lock

* Remove unnecessary guard clause

* Ensure registation lock per API category
2020-01-24 21:31:14 -08:00
Aaron Bach
cf165cc35f Make SimpliSafe integration more resilient to SimpliSafe cloud issues (#31116)
* Make SimpliSafe integration more resilient to SimpliSafe cloud issues

* Clear emergency refresh token

* Stop listening when appropriate

* Cleanup

* Saving refresh token should happen after all updates

* Code review
2020-01-24 21:19:40 -07:00
ochlocracy
0eee152386 Include supported states in Alexa SecurityPanelController configuration object (#31120)
* Update Security Panel Controller.

* Update Security Panel Controller.

* Sort imports.
2020-01-24 17:57:58 -08:00
HomeAssistant Azure
71ae4b2623 [ci skip] Translation update 2020-01-25 00:31:41 +00:00
Paulus Schoutsen
f4626375f3 Fix when you have two wemo devices (#31139) 2020-01-24 14:59:54 -08:00
Franck Nijhof
c0bc4bb550 Add logo & icon support to Manifest (#31131)
* Add logo & icon support to Manifest

* Add URL validation
2020-01-24 14:36:22 -08:00
Ville Skyttä
9795449d22 Make pylint fail on informational messages too (#31136)
Refs https://github.com/PyCQA/pylint/issues/3250
2020-01-24 23:27:15 +02:00
Paulus Schoutsen
98bac43228 Validate coveragerc with hassfest (#31112)
* Validate coveragerc

* Test if files exists

* Print progress

* Flush
2020-01-24 10:25:46 -08:00
Franck Nijhof
7e4b9adc3d Rewrite of Spotify integration (#30717)
* Rewrite of Spotify integration

* Update homeassistant/components/spotify/config_flow.py

Co-Authored-By: Paulus Schoutsen <balloob@gmail.com>

* Remove configurator dependency

* Strip whitespace from device model in case Spotify product is missing

* Ensure domain dict exists in hass data on setup entry

* Simply config validation for client id and secret

* Abort flow on any exception from spotipy

* Add tests for config flow

* Gen requirements all

* Add test package __init__

* Remove Spotify from coveragerc

* Made alias handling more robuust

* Fix supported_features for Spotify free and open accounts

* Improve error message in the logs

* Re-implement Spotify media_player

* Change media content type when play a playlist

* Process review suggestions

* Move Spotify init, static current user and supported_features

* Remove unneeded me call

* Remove playlist content type due to frontend issues

* Improve playlist handling, when context is missing

* Handle entity disabled correctly

* Handle being offline/unavailable correctly

* Bump Spotipy to 2.7.1

* Update coverage RC, mark integration silver

* Remove URI limitation, lib supports all Spotify URI's now

* Final cleanup

* Addresses Pylint error

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-01-24 18:47:22 +01:00
Franck Nijhof
4571cf01e2 Update Hue existing config entry with discovery data (#31087)
* Update Hue existing config entry with discovery data

* Updated method documentation comments

* Update implementation to match latest dev

* Use named argument for clarity
2020-01-24 09:07:53 -08:00
SukramJ
1effd605a5 Remove unused async_setup_platform (#31132) 2020-01-24 17:33:23 +01:00
Michael Dokolin
30249d1428 Fix Template components to process entity_id configuration option (#31084)
* Fix Template Cover component to process entity_id configuration option

* Fix Template Light component to process entity_id configuration option

* Empty commit to re-trigger build

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2020-01-24 12:40:00 +01:00
Desausoi Laurent
6ff572d1dd Add Buienradar camera for Belgium (#30399)
* Buienradar Camera for Belgium

* Voluptuous check for country code

* Black formatting

* Testing for Buienradar Belgium

* Changed MULTIPLE CHOICE variable name

* Changes from frenck review
2020-01-24 12:38:35 +01:00
Paulus Schoutsen
b4f3415eb9 Update cast to 4.1.1 (#31113) 2020-01-24 09:20:47 +01:00
Josef Schlehofer
ca591d591f Upgrade youtube_dl to version 2020.01.24 (#31124) 2020-01-24 00:07:36 -08:00
Raman Gupta
1de003487e Fix connection failure log message in async_setup_entry for Vizio component (#31097)
* remove connection check during setup since it is already done during config flow

* revert change and fix log message

* demote connection setup to warning
2020-01-24 07:39:28 +01:00
HomeAssistant Azure
6da2904e12 [ci skip] Translation update 2020-01-24 00:31:41 +00:00
Franck Nijhof
47b708974d Add disabled entities support to AdGuard (#31106) 2020-01-24 00:50:59 +01:00
Markus Pöschl
7fed328e1c Use speak2mary for MaryTTS integration and enable sound effects (#30805)
* Use speak2mary for MaryTTS integration and enable sound effects

* Replace static defaults for effects with user configured ones
2020-01-23 22:45:06 +01:00
Paolo Tuninetto
fc95744bb7 Change Samsung TV state detection (#30236)
* Changed Samsung TV state detection

* Trying codecov fix

* Update Rewritten

* Changed update method

* Timeout handling

* Fixed autodetect tests

* Fixed last test

* Added test to complete codecov

* Removed state settings in send_key method

* Fixed pylint

* Fixed some tests

* codecov fix
2020-01-23 21:43:30 +01:00
Franck Nijhof
b743f9b8f6 Add update_entry dict to unique ID flow abort helper (#31090)
* Add update_entry dict to unique ID flow abort helper

* Process review suggestions

* Process review suggestions

* Add additional test
2020-01-23 11:21:19 -08:00
Fabian Affolter
bdd73b03b5 Upgrade shodan to 1.21.3 (#31111) 2020-01-23 19:49:01 +01:00
uvjustin
910a0bc870 Allow framerates less than 1 (#31108) 2020-01-23 10:14:47 -08:00
tetienne
1a1ef7680d Add temperature support to light template (#30595)
* Add temperature support

* Use guard clause
2020-01-23 09:18:59 -08:00
Michael Dokolin
894b841a15 Fix HomeKit window covering to support float numbers in the position (#31081)
* Fix HomeKit window covering to support float numbers in the position

* Fix HomeKit window covering to cast current position to an integer value
2020-01-23 09:02:44 -08:00
mindigmarton
bfea9863f1 Update emulated_roku to 0.2.1 (#31100) 2020-01-23 17:12:20 +01:00
Franck Nijhof
e9eaa6536d Upgrade sqlalchemy to 1.3.13 (#31101) 2020-01-23 17:10:40 +01:00
Franck Nijhof
c563652574 Cleanup of PR and issue templates (#31070)
* Remove old issue template

* Small wording improvement

* Consistency

* Configuration fix

* Process review suggestions
2020-01-23 11:55:29 +01:00
Robin
c71ae090fc Add sighthound integration (#28824)
* Add component files

* Add test state

* Adds person detected event

* Update CODEOWNERS

* Updates requirements

* remove unused datetime

* Bump sighthound version

* Update CODEOWNERS

* Update CODEOWNERS

* Create requirements_test_all.txt

* Address reviewer comments

* Add test for bad_api_key
2020-01-23 09:30:06 +01:00
Aaron Bach
73a55825af Remove monitored conditions from RainMachine (#31066)
* Remove monitored conditions from RainMachine

* Migrate config entry

* Revert "Migrate config entry"

This reverts commit 84fcf5120f.

* Code review comments

* Disable some entities by default
2020-01-22 20:49:47 -08:00
Fredrik Erlandsson
3fc86988fa pydaikin version bump (#31080) 2020-01-22 18:09:52 -08:00
James Hilliard
d8eca8e303 Add keep-alive which is required for some hlk-sw16 variants (#31062) 2020-01-22 17:57:55 -08:00
springstan
b7678f526c Deprecate hook integration (#31046) 2020-01-22 17:50:24 -08:00
Jonathan Keljo
572b81e7e0 Add myself to owners for components I contributed (#31020)
* Add myself to owners for components I contributed

* Update CODEOWNERS
2020-01-22 17:49:00 -08:00
Aaron Bach
288574b8d1 Remove monitored conditions from OpenUV (#31019)
* Remove monitored conditions from OpenUV

* Code review comments
2020-01-22 17:48:20 -08:00
Paulus Schoutsen
80887d757a Simplify automation services (#30996)
* Simplify automation services

* Empty commit to re-trigger build

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2020-01-22 17:46:12 -08:00
Raman Gupta
192b656635 Code Cleanup for Vizio component (#31076)
* code cleanup

* dont use named arguments for positional arguments

* remove extra comma
2020-01-23 01:55:34 +01:00
HomeAssistant Azure
a0d2a3c6c5 [ci skip] Translation update 2020-01-23 00:31:52 +00:00
Paulus Schoutsen
0fba9e44ed Migrate zone to use collection helpers (#30774) 2020-01-22 12:36:25 -08:00
Maciej Bieniek
4c27d6b9aa Add zeroconf discovery support to Brother Printer integration (#30959)
* Add zeroconf discovery support

* Fix data for config_entry

* Add sting for zeroconf confirm dialog

* Add and fix tests

* Fix pylint errors

* Suggested changes

* Tests

* Remove unnecessary object

* Add error handling

* Remove unnecessary objects

* Suggested change

* Suggested change

* Use core interfaces for tests
2020-01-22 11:34:11 -08:00
ochlocracy
4015a046d2 Update AdjustRange Handler Service Calls. (#31016)
Add a AlexaGlobalCatalog value to all labels.
2020-01-22 11:04:31 -08:00
thoscut
93d109e524 Add DIRECTORY and PLUGIN to kodi media types (#28336) 2020-01-22 19:31:03 +01:00
Josh Bendavid
fae74f7ed7 Improve state tracking for WebOsTV (#31042)
* upgrade to aiopylgtv 0.3.0 and corresponding simplification and cleanup of webostv state tracking

* properly handle case where Live TV is not reported in list of apps

* fix tests (entity state is no longer linked to source id)

* fix pylint checks

* avoid unnecessary retrieval of channel list

* use only standard home assistant states
2020-01-22 19:06:08 +01:00
Paulus Schoutsen
e5365779fe Allow unloading mobile app (#30995) 2020-01-22 09:57:47 -08:00
David F. Mulcahey
3c44a1353a change group id creation (#31075) 2020-01-22 09:23:35 -05:00
Franck Nijhof
db76b91ffa Add disabled entities support to WLED (#31040) 2020-01-22 10:45:38 +01:00
Dougal Matthews
96dba7b91f Add the Home Assistant version as a Sentry release (#31065)
This helps make it easier to identify which version of Home Assistant
first introduces a error.
2020-01-22 10:38:24 +01:00
Raman Gupta
463d949ee0 Add zeroconf discovery support for vizio integration (#30949)
* add missing tests

* readd removed test

* add zeroconf discovery support for vizio integration

* no mock_coro_func needed

* add reasonable timeout and don't log exceptions from pyvizio due to timeout

* add test to test options update and bump pyvizio to avoid timeout issues

* update requirements_*

* fix gaps in coverage

* change return hint for async_setup_entry

* use source variables instead of strings

* only get unique ID if about to create entry

* update based on review

* Revert "update based on review"

This reverts commit 0d612a90eb7d02c92061f902973e527267e3110a.

* f-string

* fix last review

* revert cleanup changes to simplify PR

* remove unnecessary ConfigFlow object variables to simplify logic

* revert cleanup changes to make review easier, noted for future cleanup

* revert cleanup changes to make review easier, noted for future cleanup

* move zeroconf service type constant to test module
2020-01-22 10:13:35 +01:00
Raman Gupta
ee74f95371 Enhance info_from_service function in zeroconf integration (#31059)
* enhance zeroconf service info decoding to include raw bytes

* Update homeassistant/components/zeroconf/__init__.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* fix test based on last commit

* fix test based on last commit

* remove .keys() when asserting processed and raw service info properties

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-01-21 21:24:59 -08:00
Quentame
bc600995c1 Do not stop fetching iCloud data after service error (#31069) 2020-01-22 01:39:12 +01:00
Leon Knauer
58973d5265 Fix luftdaten broken icon for "Pressure at sealevel" (#31053) 2020-01-22 01:34:19 +01:00
HomeAssistant Azure
7e604bed7d [ci skip] Translation update 2020-01-22 00:31:43 +00:00
springstan
c3888330c1 Fix fan_modes in tuya climate (#30942) 2020-01-22 01:28:19 +01:00
Jens
15f6e28a04 Add tahoma io:AwningValanceIOComponent (#30944) 2020-01-22 01:09:59 +01:00
Joe Gross
3b4c3e6e17 Fix prometheus component to fully sanitize Unicode characters (#31037)
* Fix prometheus component to fully santize Unicode characters.

Sanitization used isdigit() to match numerics but that also matches 
Unicode "digit" characters that require special handling, like 
superscripts. Failures would look like this:

ValueError: Invalid metric name: sensor_unit_u0x23_per_m³

Changed sanitize to use string.digits, which matches only ascii digits, 
and added test.

See 
https://stackoverflow.com/questions/44891070/whats-the-difference-between-str-isdigit-isnumeric-and-isdecimal-in-python 
for discussion.

https://docs.python.org/3/library/stdtypes.html#str.isdigit

https://docs.python.org/3.7/library/string.html#string.digits

* fix formatting to comply with black
2020-01-22 01:03:42 +01:00
Franck Nijhof
ff7d2ac681 Iteration on issue and PR templates (#31058)
* Iteration on issue and PR templates

* Some small improvements to make it look better in the PR editor

* Better English

* Please keep template

* Consistency

* Adds www to website link, to make more clear it is our website

* Process review suggestion by Martin

* Added dep bump as type of change

* English
2020-01-21 23:24:01 +01:00
Franck Nijhof
e8e7e66e2b Bump pytest to 5.3.4 (#31045) 2020-01-21 15:44:39 -05:00
David Bonnes
e00388eea0 switch evohome to use a whitelist for valid zonetype (#31047) 2020-01-21 18:49:15 +00:00
Franck Nijhof
19d30f0a1b Update issue and PR templates (#31056)
* Update issue and PR templates

* Empty commit to re-trigger build
2020-01-21 18:38:50 +01:00
zhumuht
27c25b6f44 Add xiaomi miio sensors cgllc.airmonitor.s1 & cgllc.airmonitor.b1 (#30345)
* support xiaomi miio sensor: cgllc.airmonitor.s1 & cgllc.airmonitor.b1

* support xiaomi miio sensor: cgllc.airmonitor.s1 & cgllc.airmonitor.b1

* rollback sensor,  modify air_quality

* only set air_quality props

* remove set state from "zhimi.airmonitor.v1"

* unit_of_measurement return None when the pm25 isn't reported

* import libs by isort
2020-01-21 17:06:17 +01:00
Abílio Costa
2aff913d9b Update pyipma to 2.0 (#30746)
* update ipma component for pyipma 2.0

* fix wind speed; refactor forecast

* update requirements*.txt

* fix tests; update CODEOWNERS; update pyipma to 2.0.1

* minor changes as suggested in PR

* make lint happy

* fix mocking coroutines

* restore old unique id

* fix station lat/lon; update pyipma version
2020-01-21 17:04:22 +01:00
James Nimmo
c2df4f56a3 Bump pyintesishome to v1.6 (#31044) 2020-01-21 16:57:27 +01:00
Franck Nijhof
a3bcf69adf 0.104.3 (#31048)
0.104.3
2020-01-21 13:25:53 +01:00
Franck Nijhof
fb35d382e1 Remove all empty *_setup_platform() from integrations (#31025)
* Remove all empty *_setup_platform() from integrations

* Fix tests for smartthings

* Fix tests for heos
2020-01-21 12:38:38 +01:00
Franck Nijhof
cfa74039bb Bumped version to 0.104.3 2020-01-21 12:18:07 +01:00
Franck Nijhof
ccf6ce71cf Fix deCONZ update entry from Hassio discovery (#31015)
* Fix deCONZ update entry from Hassio discovery

* Empty commit to re-trigger build
2020-01-21 12:14:31 +01:00
Jeff Irion
392cf57750 Fix capability_attributes when supported_features is None (#30993)
* Fix capability_attributes when supported_features is None (water_heater)

* Fix capability_attributes when supported_features is None (media_player)
2020-01-21 12:14:28 +01:00
steve-gombos
6889816704 Ring camera fix (#30975)
* Fix ring camera entities

* Reverted test refresh interval

* Fix black errors
2020-01-21 12:14:24 +01:00
Jan De Luyck
dde6220ca5 Update emulated_roku to 0.2.0 (#30974) 2020-01-21 12:14:16 +01:00
Paulus Schoutsen
dead2fe576 Catch all Ring timeout errors (#30960)
* Catch more Ring errors

* Fix comment & Disable wifi entities by default

Signed-off-by: Franck Nijhof <git@frenck.dev>
2020-01-21 12:13:11 +01:00
David F. Mulcahey
41014d73be Allow ZHA device creation for the Zigbee coordinator (#31032)
* allow zha device creation for coordinator

* don't let coordinator get removed

* fix truthy issue in logical device type
2020-01-21 06:07:47 -05:00
Josef Schlehofer
bc6603d8d7 Upgrade pyyaml to 5.3 (#31026) 2020-01-20 21:12:16 -08:00
Josef Schlehofer
0b72587af2 Upgrade importlib-metadata to version 1.4.0 (#31027) 2020-01-20 21:11:23 -08:00
HomeAssistant Azure
692e4f27c4 [ci skip] Translation update 2020-01-21 00:33:20 +00:00
David Bonnes
8f37c843f5 Handle ghost zones gracefully (#31008) 2020-01-20 20:49:04 +00:00
Aaron Bach
662c12715e Allow OpenUV entities to be unavailable (#31018)
* Allow OpenUV entities to be unavailable

* Empty commit to re-trigger build
2020-01-20 13:33:58 -07:00
Sébastien RAMAGE
1639432463 Bump zigpy-zigate to 0.5.1 (#31004)
* Bump zigpy-zigate to 0.5.1
Improve startup and channel setting
2020-01-20 13:09:20 -05:00
Quentame
8c22858ae3 Use config_entry.unique_id in iCloud (#30984)
* Use unique_id in iCloud

* Remove missed self._configuration_exists()

* Avoid breaking change

* Almost fix tests

* Add missing test

* Fix tests
2020-01-20 18:59:29 +01:00
Ville Skyttä
5e2ba2eb77 Enable some more bandit checks (#30857)
* Enable B108 (hardcoded tmp dir), address findings

* Enable B602 (subprocess popen with shell), address findings

* Enable B604 (start process with shell), address findings

* Enable B306 (mktemp), B307 (eval), and B325 (tempnam), no issues to address
2020-01-20 18:44:55 +02:00
Franck Nijhof
6cf20fc7fa Fix deCONZ update entry from Hassio discovery (#31015)
* Fix deCONZ update entry from Hassio discovery

* Empty commit to re-trigger build
2020-01-20 08:18:10 -08:00
Franck Nijhof
f7a97dae2d Adds missing strings to Withings (#31012) 2020-01-20 16:26:44 +01:00
Franck Nijhof
d2b0031f55 Adds missing strings to Almond (#31013) 2020-01-20 16:26:06 +01:00
David Bonnes
9b02ca96ba Small tweaks for evohome (#31007) 2020-01-20 13:39:02 +00:00
Bas Nijholt
a010577d6e Add kef supports_on option (#30937)
* add supports_on_off option

* modify support_kef inplace

* all speakers support turning off remotely
2020-01-20 14:24:13 +01:00
Josh Bendavid
a634e62dfc Minor fixes for webostv (#30998)
* restore emulation of play pause toggle

* add protection to notify setup

* add state check for power off to avoid switching tv back on
2020-01-20 10:43:20 +01:00
Ronald Dehuysser
053f18d6ce Add attributes departure_minutes and delay_minutes to the nmbs sensor (#30958)
* Improve sensor for automations

I've updated the sensor so that departure time and delay can be used in automatons.

Before, the departure time and delay time were only available wrapped in strings which makes it difficult to use them in automations. Using the extra attributes, one can easily use them in automations.

* Update homeassistant/components/nmbs/sensor.py

Co-Authored-By: springstan <46536646+springstan@users.noreply.github.com>

* Updates based on review

Changed min to minutes as requested

Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
2020-01-20 09:51:59 +01:00
Aaron Bach
9993333bf9 Add state reproduction to remotes (#30990) 2020-01-19 23:08:32 -08:00
Jeff Irion
bb37f7bb75 Fix capability_attributes when supported_features is None (#30993)
* Fix capability_attributes when supported_features is None (water_heater)

* Fix capability_attributes when supported_features is None (media_player)
2020-01-19 23:06:35 -08:00
Faucogney Anthony
b2212ad445 Add Derivative component (#26456)
* create derivation component

based on integration component
remove left and right

* Update test

(was'n saved)

* add some functionnal point test

* Change derivation to derivative

* Continue migration from derivation to derivative

* Add codeowners info

* fix tests typo and values

* Improve code from reviewer

add test case
fix test values
still a prefix issue that should not

* create derivation component

based on integration component
remove left and right

* Update test

(was'n saved)

* add some functionnal point test

* Change derivation to derivative

* Continue migration from derivation to derivative

* Add codeowners info

* fix tests typo and values

* Improve code from reviewer

add test case
fix test values
still a prefix issue that should not

* Update homeassistant/components/derivative/sensor.py

Fix test issue with unit of measurement

Co-Authored-By: Santobert <tobhaase@gmail.com>

* Fix review

Move ValueError to SyntaxError

* precise state test

* un comment original tests and remove error tests

* Fix isort issue

* Fix review

- update doc link
- migrate to general const import

* Rollback import conf_unit, just defined localy

Co-authored-by: Santobert <tobhaase@gmail.com>
2020-01-19 22:17:06 -08:00
zhumuht
5f31b48f1d print component import error to logfile (#30346) 2020-01-19 22:05:10 -08:00
Raman Gupta
e535133016 Fix options update during import config flow step for vizio component (Bugfix for #30653) (#30977)
* fix options update logic during import

* add missing tests

* fix abort reasons and strings, add missing test

* combine steps when testing esn already exists

* readd removed test

* no mock_coro_func needed

* add block_until_done and assert entry options
2020-01-19 20:13:15 -08:00
Paulus Schoutsen
0c3ffbe282 Add foundation for integration services (#30813)
* Add foundation for integration services

* Fix tests

* Remove async_get_platform

* Migrate Sonos partially to EntityPlatform.async_register_entity_service

* Tweaks

* Move other Sonos services to media player domain

* Move other Sonos services to media player domain

* Address comments

* Remove lock

* Fix typos

* Use make_entity_service_schema

* Add area extraction to async_extract_entities

Co-authored-by: Anders Melchiorsen <amelchio@nogoto.net>
2020-01-19 17:55:18 -08:00
HomeAssistant Azure
f20b3515f2 [ci skip] Translation update 2020-01-20 00:31:55 +00:00
David Bonnes
a40a5a754b initial commit (#30968) 2020-01-19 14:29:15 -08:00
Paulus Schoutsen
ecef0f6e93 Catch all Ring timeout errors (#30960)
* Catch more Ring errors

* Fix comment & Disable wifi entities by default
2020-01-19 13:39:16 -08:00
steve-gombos
8fcd0e9a79 Ring camera fix (#30975)
* Fix ring camera entities

* Reverted test refresh interval

* Fix black errors
2020-01-19 13:18:11 -08:00
Paulus Schoutsen
765b45c81b Improve Wemo config entry support, add device info (#30963)
* Improve config entry support, add device info

* async_dispatch_connect

* Fix I/O in event loop

* Do not raise PlatformNotReady inside dispatcher

* Make main discovery process async

* Do discovery as part of set up.

* Greatly simplify set up

* Add parallel updates to fan&switch

* mini cleanup

* Address comments
2020-01-19 13:13:10 -08:00
Paulus Schoutsen
e4a53d3a08 Improve Wemo config entry support, add device info (#30963)
* Improve config entry support, add device info

* async_dispatch_connect

* Fix I/O in event loop

* Do not raise PlatformNotReady inside dispatcher

* Make main discovery process async

* Do discovery as part of set up.

* Greatly simplify set up

* Add parallel updates to fan&switch

* mini cleanup

* Address comments
2020-01-19 12:57:48 -08:00
Paulus Schoutsen
f14d34560e Improve Wemo config entry support, add device info (#30963)
* Improve config entry support, add device info

* async_dispatch_connect

* Fix I/O in event loop

* Do not raise PlatformNotReady inside dispatcher

* Make main discovery process async

* Do discovery as part of set up.

* Greatly simplify set up

* Add parallel updates to fan&switch

* mini cleanup

* Address comments
2020-01-19 12:56:31 -08:00
Jan De Luyck
90e811df20 Update emulated_roku to 0.2.0 (#30974) 2020-01-19 21:01:16 +01:00
Quentame
7c155731fc Fix can't add multiple iCloud accounts (remove account name) (#30898)
* Fix can't add multiple iCloud accounts (remove account name)

* Update tests with flow.async_init()
2020-01-19 14:19:46 +01:00
HomeAssistant Azure
6c84c126ea [ci skip] Translation update 2020-01-19 00:32:00 +00:00
David F. Mulcahey
078ce24e5a Add logical Zigbee device type to ZHA device info (#30954)
* add device type to device info
* capitalize
* use zigpy logical device type
2020-01-18 19:27:55 -05:00
ajmarks
656ef6566b Minor enhancements to jewish_calendar (#30632)
* Minor enhancement to jewish_calendar:
 - Expose more halachic times from the underlying hdate module
 - Correct and standardize some transliterations

* Undo breking name change

* Add icon for talit time

Co-authored-by: Andrew Marks <52414333+amarks-coatue@users.noreply.github.com>
2020-01-18 21:33:18 +01:00
Barry Williams
afb1b0cd3c Add play media support and Spotify control to Openhome (#28698) 2020-01-18 18:37:39 +01:00
Alexei Chetroi
26fb1ce255 Don't use unit_of_measurement in state attributes. (#30941) 2020-01-18 10:03:59 -05:00
springstan
4b67508330 Revert "Pulseaudio: Changed default port from 4712 to 4713 (#28857)" (#30939)
This reverts commit e915dd0d95.
2020-01-18 14:02:15 +01:00
David Bonnes
a037c1d788 Add services to evohome (#29816) 2020-01-18 12:21:22 +00:00
David Bonnes
bfa8cb760f Add services to geniushub (#30918)
adds:
 - `set_zone_override`, and
 - `set_zone_mode`
2020-01-18 12:14:50 +00:00
Raman Gupta
8630a076a7 Use default media player device classes for vizio component (#30802)
* use media player defined device classes instead of custom ones, add options flow test, add timeout options parameter

* make options update error more generic

* fix config flow options update logic

* simplify logic for options update during import

* use platform list for load and unload

* update private config flow function name and description

* fix grammar in strings.json

* update mock config variable names to be more accurate

* remove timeout conf option, create device_class property

* update requirements

* update .coveragerc to indicate that config_flow has tests

* fix source of device_class property and move constants to const.py

* fix grammar in error message

* remove redundant device check in async_setup_entry since device connection is checked during config flow

* revert change to async_setup_entry, raise ConfigEntryNotReady if device can't be connected to

* update error text

* add more context to error text
2020-01-18 09:15:05 +01:00
springstan
52cee84c2c Update outdated documentation links in json files (#30916) 2020-01-17 21:41:42 -08:00
Alexei Chetroi
3bf657284c Refactor rounding for ZHA electrical measurement sensor (#30923) 2020-01-17 20:53:31 -05:00
Alexei Chetroi
58520aa733 Add battery voltage state attribute for ZHA devices (#30901)
* Add battery voltage state attribute for ZHA devices.

* Pylint.
2020-01-17 19:43:02 -05:00
Paulus Schoutsen
7ef7d1dfd0 Merge pull request #30925 from home-assistant/rc
0.104.2
2020-01-17 16:32:18 -08:00
HomeAssistant Azure
4d7c8e254b [ci skip] Translation update 2020-01-18 00:31:52 +00:00
Paulus Schoutsen
2c915af348 Bumped version to 0.104.2 2020-01-17 15:48:27 -08:00
Paulus Schoutsen
2b733917a4 Fix hue accepting filename (#30924) 2020-01-17 15:48:21 -08:00
Bram Kragten
353010712f pdated frontend to 20200108.2 (#30921) 2020-01-17 15:47:58 -08:00
Robert Svensson
07a0bc4abe Fix service device refresh calling state update (#30920) 2020-01-17 15:46:10 -08:00
Paulus Schoutsen
f9b48844e6 camera endpoint likes to timeout, catch it. (#30919) 2020-01-17 15:46:10 -08:00
ochlocracy
6053d02e44 Fix Alexa semantics for covers with tilt support. (#30911)
* Fix Alexa semantics for covers with tilt support.

* Clarify wording.

* Korrect grammar.
2020-01-17 15:45:41 -08:00
Robert Svensson
6ac33e5c7b Fix issue with group unique id when normalising bridge id (#30904) 2020-01-17 15:44:09 -08:00
SukramJ
586566e6ab Fix missing switch groups of HomematicIP Cloud (#30903) 2020-01-17 15:44:08 -08:00
David F. Mulcahey
5a46adfebf add multistate back (#30889) 2020-01-17 15:44:07 -08:00
Paulus Schoutsen
9f20185cee Fix hue accepting filename (#30924) 2020-01-17 15:38:38 -08:00
Robert Svensson
c9db21ffac Fix service device refresh calling state update (#30920) 2020-01-17 15:33:46 -08:00
Robert Svensson
7b29a498c6 Fix issue with group unique id when normalising bridge id (#30904) 2020-01-17 15:28:34 -08:00
ochlocracy
1d41cf96ca Fix Alexa semantics for covers with tilt support. (#30911)
* Fix Alexa semantics for covers with tilt support.

* Clarify wording.

* Korrect grammar.
2020-01-17 15:04:46 -08:00
Bram Kragten
e33698b17d Updated frontend to 20200108.2 (#30921) 2020-01-17 14:54:53 -08:00
Paulus Schoutsen
8cacef47f3 camera endpoint likes to timeout, catch it. (#30919) 2020-01-17 14:54:32 -08:00
Joakim Sørensen
a5a69bdf71 Adds icon endpoint to NO_AUTH (#30910)
* Adds icon endpoint to NO_AUTH

* Add test for no_auth icon get

* Blackout
2020-01-17 13:54:28 -08:00
Peter Nijssen
196bf2f3a0 remove PostNL component as it is no longer working (#30902) 2020-01-17 12:51:32 -08:00
Aaron Bach
847196dbe8 Remove option to configure SimpliSafe scan interval (#30909)
* Enforce minimum scan interval for SimpliSafe

* Remove scan interval all together

* Fix tests
2020-01-17 13:43:41 -07:00
David F. Mulcahey
31996120dd add multistate back (#30889) 2020-01-17 13:06:10 -05:00
SukramJ
d913d35fc3 Fix missing switch groups of HomematicIP Cloud (#30903) 2020-01-17 18:37:32 +01:00
Alexei Chetroi
8a78b65f0d Extract collection entity registry cleaner into a helper (#30844)
* Extract entity_registry_keeper into separate helper
* Refactor input_*, timer and person to use new helper.
* Make Mypy happy.
* Better name.
2020-01-17 11:41:46 -05:00
cgtobi
da368f0cb8 Update pyatmo to 3.2.2 and add available attribute (#30882)
* Update pyatmo to 3.2.1

* Update pyatmo to 3.2.2

* Remove accidentally added requirements

* Add availability property
2020-01-17 17:08:30 +01:00
Raman Gupta
d63ea198f2 Bump pyvizio version to 0.1.1 (#30867)
* bump pyvizio version to resolve setup issue

* update requirements*.txt
2020-01-17 08:48:59 +01:00
HomeAssistant Azure
24a381456a [ci skip] Translation update 2020-01-17 00:31:45 +00:00
Daniel Shokouhi
6678f8387f Remove unused import (#30858) 2020-01-16 16:26:10 -08:00
Paulus Schoutsen
09f7a09ce7 Merge pull request #30853 from home-assistant/rc
0.104.1
2020-01-16 12:47:51 -08:00
Aaron Bach
e2e01f5020 Fix sensor type creation with multiple Ambient weather stations (#30850) 2020-01-16 11:38:10 -08:00
Per-Øyvind Bruun
0e1450838e Fix for issue #29822 (#30849) 2020-01-16 11:38:10 -08:00
Per-Øyvind Bruun
a93088dafb Fix for issue #29822 (#30849) 2020-01-16 11:37:53 -08:00
Aaron Bach
9bfcd04a4f Fix sensor type creation with multiple Ambient weather stations (#30850) 2020-01-16 11:37:28 -08:00
Paulus Schoutsen
006419b96c Whitelist Frenck for release 2020-01-16 11:36:01 -08:00
Paulus Schoutsen
3f54533e72 Bumped version to 0.104.1 2020-01-16 11:33:54 -08:00
Paulus Schoutsen
cc126761e1 Reinstate and deprecate filename option for hue config (#30846) 2020-01-16 11:33:47 -08:00
Quentame
8fdf68c8d1 Fix iCloud when no family members (issue #30829) (#30836) 2020-01-16 11:33:46 -08:00
Josh Bendavid
6a8582750c Fix play_media in webostv (#30828) 2020-01-16 11:33:45 -08:00
Pascal Vizeli
5b51f740df Fix mpd time issue (#30825)
* Fix mpd time issue

* Update homeassistant/components/mpd/media_player.py

Co-Authored-By: Franck Nijhof <git@frenck.dev>
2020-01-16 11:33:45 -08:00
Paulus Schoutsen
881b35f9d6 Handle no host info in ignored config entries (#30822) 2020-01-16 11:33:44 -08:00
springstan
8f852bd656 Fix setup error of Mikrotik (#30810) 2020-01-16 11:33:43 -08:00
Josh Bendavid
368d04b2a1 update to aiopylgtv 0.2.7 (#30797) 2020-01-16 11:33:42 -08:00
Jan De Luyck
6d83dafff2 Update emulated_roku to 0.1.9 (#30791)
* Update emulated_roku to 0.1.9

* Update requirements_all
2020-01-16 11:33:42 -08:00
Paulus Schoutsen
7da84dca76 Reinstate and deprecate filename option for hue config (#30846) 2020-01-16 11:28:35 -08:00
Franck Nijhof
2a65da5db2 Deprecate history_graph integration (#30835) 2020-01-16 10:31:18 -08:00
Franck Nijhof
8861c80068 Deprecate hide_if_away from device_tracker (#30833) 2020-01-16 10:31:00 -08:00
Quentame
04b7d9e848 Fix iCloud when no family members (issue #30829) (#30836) 2020-01-16 09:27:43 -08:00
Franck Nijhof
235ab64066 Deprecate weblink integration (#30834) 2020-01-16 09:25:49 -08:00
Franck Nijhof
4544665749 Deprecate states UI options in group integration (#30831) 2020-01-16 09:25:39 -08:00
Paulus Schoutsen
e1205409f3 Handle location API being exhausted (#30798) 2020-01-16 17:31:12 +01:00
Alexei Chetroi
d9d5e06baf Use collection helpers for input_datetime component (#30815)
* Refactor input_datetime.
Keep the state as datetime, but format accordingly to has_time and
has_date.

* Use config dict for input_datetime.
* Add tests.
* Lint
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-01-16 09:16:57 -05:00
Josh Bendavid
d1da653e62 Fix play_media in webostv (#30828) 2020-01-16 12:30:55 +01:00
Pascal Vizeli
bef8600972 Fix mpd time issue (#30825)
* Fix mpd time issue

* Update homeassistant/components/mpd/media_player.py

Co-Authored-By: Franck Nijhof <git@frenck.dev>
2020-01-16 11:20:58 +01:00
springstan
9d5a391916 Fix setup error of Mikrotik (#30810) 2020-01-16 10:48:47 +01:00
Paulus Schoutsen
6f24fe3970 Handle no host info in ignored config entries (#30822) 2020-01-16 10:19:38 +01:00
Rick van Hattem
1566d963a8 Fixed pyyaml requirement from 5.2.0 to 5.2 (#30808) 2020-01-15 20:16:26 -05:00
HomeAssistant Azure
01520a32d3 [ci skip] Translation update 2020-01-16 00:31:45 +00:00
Franck Nijhof
b42134bbce Merge branch 'master' into dev 2020-01-15 22:18:51 +01:00
Franck Nijhof
4bb319e658 0.104.0 (#30803)
0.104.0
2020-01-15 21:38:22 +01:00
MatthewFlamm
b8feaba5cb Update pynws to v0.10.1 (#30662)
* update to pynws 0.10.1

* remove unneeded raw json files

* move test helper module to const
2020-01-15 12:01:47 -08:00
springstan
3899c6ae27 Bump librouteros to 3.0.0 (#30800) 2020-01-15 11:54:20 -08:00
Franck Nijhof
1e2c3cacf9 Mark hide_entity deprecated in automation integration (#30799) 2020-01-15 11:53:52 -08:00
Franck Nijhof
3d9b6332c8 Bumped version to 0.104.0 2020-01-15 20:22:09 +01:00
Jc2k
1a6535ff8b Restore unit_of_measurement from entity registry (#30780)
* Restore unit_of_measurement from entity registry

* Lint fix
2020-01-15 20:17:42 +01:00
Paulus Schoutsen
3fd14ca3cf Refactor Ring data handling (#30777)
* Refactor Ring data handling

* Add async_ to methods
2020-01-15 20:17:36 +01:00
Pascal Vizeli
1c70435df6 Revert #29701 (#30766)
* Revert #29701

* fix format

* Fix lint
2020-01-15 20:17:28 +01:00
Josh Bendavid
5393300086 update to aiopylgtv 0.2.7 (#30797) 2020-01-15 10:48:30 -08:00
ochlocracy
bb42ff93f4 Add support for vacuums to Alexa. (#30764) 2020-01-15 09:15:31 -08:00
Paulus Schoutsen
1e82813c3b Refactor Ring data handling (#30777)
* Refactor Ring data handling

* Add async_ to methods
2020-01-15 08:10:42 -08:00
Jc2k
de26108b23 Restore unit_of_measurement from entity registry (#30780)
* Restore unit_of_measurement from entity registry

* Lint fix
2020-01-15 08:09:05 -08:00
Miroslav Ždrale
36796ef649 Update pyubee to 0.8 (#30785) 2020-01-15 16:24:06 +01:00
Jan De Luyck
41469cec6c Update emulated_roku to 0.1.9 (#30791)
* Update emulated_roku to 0.1.9

* Update requirements_all
2020-01-15 16:21:55 +01:00
Raman Gupta
ac771addc1 Add Config Flow support, Device Registry support, available property to vizio component (#30653)
* add config flow support, device registry support, available property

* raise PlatformNotReady if HA cant connect to device

* remove test logging statement and fix integration title

* store import and last user input values so user can see errors next to value that caused error

* add PARALLEL_UPDATES

* add missing type hints

* add missing type hints to tests

* fix options config flow title

* changes based on review

* better key name for message when cant connect

* fix missed update to key name

* fix comments

* remove logger from test which was used to debug and update test function names and docstrings to be more accurate

* add __init__.py to vizio tests module

* readded options flow and updated main component to handle options updates, set unique ID to serial, fixes based on review

* pop hass.data in media_player unload instead of in __init__ since it is set in media_player

* update requirements_all and requirements_test_all

* make unique_id key name a constant

* remove additional line breaks after docstrings

* unload entries during test_user_flow and test_import_flow tests to hopefully reduce teardown time

* try to speed up tests

* remove unnecessary code, use event bus to track options updates, move patches to pytest fixtures and fix patch scoping

* fix comment

* remove translations from commit

* suppress API error logging when checking for device availability as it can spam logs

* update requirements_all and requirements_test_all

* dont pass hass to entity since it is passed to entity anyway, remove entity unload from tests, other misc changes from review

* fix clearing listeners

* use config_entry unique ID for unique ID and use config_entry entry ID as update signal

* update config flow based on suggested changes

* update volume step on config import if it doesn't match config_entry volume step

* update config_entry data and options with new volume step value

* copy entry.data and entry.options before updating when updating config_entry

* fix test_import_entity_already_configured
2020-01-15 11:43:55 +01:00
Alexei Chetroi
5fa7d6f22a Allow input_* and timer component setup without config (#30772)
* Allow input_boolean setup without config.

* Allow input_number setup without config.

* Allow input_select setup without config.

* Allow input_text setup without config.

* Allow timer setup without config.
2020-01-14 22:15:59 -05:00
Bram Kragten
8af946fba5 Search: Add search to default config and don't resolve area (#30762)
* Add search to default config and don't resolve area

* Move to frontend

* Minor update

Co-authored-by: Jason Hu <awarecan@users.noreply.github.com>
2020-01-14 18:36:21 -08:00
HomeAssistant Azure
8093da6a0c [ci skip] Translation update 2020-01-15 00:31:56 +00:00
Alexei Chetroi
0a7feba855 Use storage based collections for Timer platform (#30765)
* Use config dict for timer entity.

* Manage timer entities using collection helpers.

* Add tests.

* Make Timer duration JSON serializable.
2020-01-14 15:32:48 -08:00
Josef Schlehofer
6f84723fec Upgrade youtube_dl to version 2020.01.15 (#30767) 2020-01-14 15:31:51 -08:00
Paulus Schoutsen
fbf5e320f7 Whitelist Frenck for release 2020-01-14 15:06:30 -08:00
Pascal Vizeli
4731f7c721 Hass.io allow to reset password with CLI (#30755)
* Hass.io allow to reset passwort with CLI

* Add improvments

* fix comments

* fix lint

* Fix tests

* more tests

* Address comments

* sort imports

* fix test python37
2020-01-14 23:49:56 +01:00
Pascal Vizeli
9f62b58929 Revert #29701 (#30766)
* Revert #29701

* fix format

* Fix lint
2020-01-14 23:02:49 +01:00
Paulus Schoutsen
5fdc60e067 Add Safe Mode (#30723)
* Store last working HTTP settings

* Add safe mode

* Fix tests

* Add cloud to safe mode

* Update logging text

* Fix camera tests leaving files behind

* Make emulated_hue tests not leave files behind

* Make logbook tests not leave files behind

* Make tts tests not leave files behind

* Make image_processing tests not leave files behind

* Make manual_mqtt tests not leave files behind
2020-01-14 13:03:02 -08:00
Paulus Schoutsen
8dbdf0b0e1 Bumped version to 0.104.0b5 2020-01-14 12:59:50 -08:00
Franck Nijhof
fe9c85aaf1 Fix HomeKit behavior with lights supporting color and temperature (#30756) 2020-01-14 12:59:41 -08:00
Bas Nijholt
9de800ab6a bump aiokef to 0.2.5 which uses locks (#30753) 2020-01-14 12:59:41 -08:00
Pascal Vizeli
f530ea10af Refactor HomeMatic / Fix issue with 0.104/dev (#30752)
* Refactor HomeMatic / Fix issue with 0.104/dev

* Fix lock
2020-01-14 12:59:40 -08:00
Daniel Perna
64224f46ec Update pyhomematic to 0.1.63 (#30594) 2020-01-14 12:59:39 -08:00
Alan Tse
413545bd91 Bump teslajsonpy to 0.2.3 (#30750) 2020-01-14 12:57:34 -08:00
Paulus Schoutsen
f5af77d00c Set default locale for cloud Alexa config (#30749) 2020-01-14 12:57:33 -08:00
Paulus Schoutsen
4bc520c724 Update Ring to 0.6.0 (#30748)
* Update Ring to 0.6.0

* Update sensor tests

* update -> async_update

* Delete temp files

* Address comments

* Final tweaks

* Remove stale print
2020-01-14 12:57:32 -08:00
David F. Mulcahey
8e5f46d5b5 Bump ZHA quirks to 0.0.31 (#30740)
* Bump ZHA quirks version

* update requirements
2020-01-14 12:57:31 -08:00
Josh Bendavid
9fa0779c1f update aiopylgtv to 0.2.6 (#30739) 2020-01-14 12:57:30 -08:00
Josh Bendavid
c138a93454 update aiopylgtv to 0.2.5 (#30702) 2020-01-14 12:57:30 -08:00
Paulus Schoutsen
c6b96f7250 Fix Ring wifi sensors (#30735)
* Fix Ring wifi sensors

* Update before adding
2020-01-14 12:56:01 -08:00
Phil Bruckner
4a8ecb82a8 Revert "Forget auth token when going offline so we can reconnect (#26630)" (#30705)
This reverts commit 2d6d6ba90e.
2020-01-14 12:56:00 -08:00
Franck Nijhof
80f3cb7d79 Fix discovery for oauth2 flow implementations (#30700)
* Fix discovery for oauth2 flow implementations

* Fix user step

* Add tests
2020-01-14 12:55:59 -08:00
Paulus Schoutsen
c4673ddee1 Update Ring to 0.6.0 (#30748)
* Update Ring to 0.6.0

* Update sensor tests

* update -> async_update

* Delete temp files

* Address comments

* Final tweaks

* Remove stale print
2020-01-14 12:54:45 -08:00
Tim Rightnour
ba3c3057da Add support for the voltage sensor on the greeneye GEM (#30484)
* Add support for the voltage sensor on the greeneye GEM

* Changed per suggestion @springstan
2020-01-14 20:46:04 +01:00
springstan
297c360d04 Fix supported_features in MQTT fan (#28680)
* Added custom validator function for speed list

* Replace CONF_SPEED_STATE_TOPIC with CONF_SPEED_COMMAND_TOPIC to determine SUPPORT_SET_SPEED

* Revert "Added custom validator function for speed list"

This reverts commit f000396fa6.

* Replace CONF_OSCILLATION_STATE_TOPIC with CONF_OSCILLATION_COMMAND_TOPIC to determine SUPPORT_OSCILLATE
2020-01-14 09:17:44 -08:00
Akın Ömeroğlu
0b8a269b23 Fix small typo in alarmdotcom component (#30758) 2020-01-14 17:47:59 +01:00
Bas Nijholt
a26fef38a2 bump aiokef to 0.2.5 which uses locks (#30753) 2020-01-14 17:41:52 +01:00
Franck Nijhof
6b49bea6c4 Fix HomeKit behavior with lights supporting color and temperature (#30756) 2020-01-14 07:09:35 -08:00
Alan Tse
aeb789ddcc Bump teslajsonpy to 0.2.3 (#30750) 2020-01-14 11:27:49 +01:00
Pascal Vizeli
ced6df158b Refactor HomeMatic / Fix issue with 0.104/dev (#30752)
* Refactor HomeMatic / Fix issue with 0.104/dev

* Fix lock
2020-01-14 11:26:59 +01:00
Bas Delfos
0d688faa56 Fix 'NewIPAddress' error in component fritz (#30210)
* Fix 'NewIPAddress' error in component fritzbox

* Upgrade to fritzconnection 1.2.0
2020-01-14 09:46:16 +01:00
Paulus Schoutsen
1e3b3ecbe6 Set default locale for cloud Alexa config (#30749) 2020-01-14 08:33:45 +01:00
HomeAssistant Azure
f9fe91ee74 [ci skip] Translation update 2020-01-14 00:31:46 +00:00
Steven Looman
75f0fedd68 Fix translation from HA playlist to UPnP playlistItem (#30743) 2020-01-13 23:52:49 +01:00
Franck Nijhof
658d338058 Removes Cisco Spark integration (#30738) 2020-01-13 10:23:26 -08:00
Josh Bendavid
f639a8fbaa update aiopylgtv to 0.2.6 (#30739) 2020-01-13 13:11:06 -05:00
David F. Mulcahey
1b730b3055 Bump ZHA quirks to 0.0.31 (#30740)
* Bump ZHA quirks version

* update requirements
2020-01-13 13:10:22 -05:00
Paulus Schoutsen
10e89bbc8c Fix Ring wifi sensors (#30735)
* Fix Ring wifi sensors

* Update before adding
2020-01-13 09:13:46 -08:00
Paulus Schoutsen
f50714d7e9 Update config flow test scaffolding (#30694)
* Update config flow test scaffolding

* asyncpatch -> patch

* Update classname
2020-01-13 15:20:25 +01:00
Franck Nijhof
040b283a14 Fix hassfest allowing omitting discovery methods when using OAuth2Flow (#30732) 2020-01-13 05:36:47 -08:00
Paulus Schoutsen
1f9d6ba541 Update Hue SSDP discovery (#30695) 2020-01-13 05:30:07 -08:00
Franck Nijhof
1b739f9555 Removes unneeded abort if unique id in Oauth2 discovery flow (#30733) 2020-01-13 05:29:19 -08:00
michaeldavie
3c2b57afaf Bump env_canada to 0.0.34 (#30713) 2020-01-13 14:27:53 +01:00
Franck Nijhof
7143ed7ceb Remove hidden property from fibaro integration (#30730) 2020-01-13 14:23:08 +01:00
Franck Nijhof
0c14d4e067 Remove hidden property from emby integration (#30729) 2020-01-13 14:22:48 +01:00
Franck Nijhof
c8a52d4566 Remove hidden property from egardia integration (#30728) 2020-01-13 14:22:06 +01:00
Franck Nijhof
3df329b8ec Bump apprise to 0.8.3 (#30731) 2020-01-13 08:20:09 -05:00
Franck Nijhof
56dc5298fc Remove hidden property from xiaomi_miio.remote integration (#30727) 2020-01-13 13:50:01 +01:00
Maciej Bieniek
15645ab0c9 Add unique ID to Airly config entries (#30681)
* Add unique ID to Airly config entries

* Update tests

* Update tests

* Fix typo

* Remove unnecesary and undo changes in first test

* Suggested change
2020-01-13 13:28:07 +01:00
zewelor
ce13fb8d73 Support yeelight color light with nightlight (#30194)
* Support color light with nightlight

* Better nightlight mode support check

* Lint fixes

* Remove brightness control for color light with nightlight mode
2020-01-13 06:03:48 +01:00
Franck Nijhof
96c11bc6d7 Unhide SPC binary sensors by default (#30699) 2020-01-12 20:47:07 -08:00
Aaron Bach
b585feb109 Consolidate SimpliSafe property services (#30567)
* Consolidate SimpliSafe property services

* Code review comments

* Code review comments

* Ensure all services are admin services

* Code review comments
2020-01-12 21:32:08 -07:00
Quentame
123bef4f1e Fix SynologyDSM sensor if network_sensors is None (#30718) 2020-01-13 04:42:37 +01:00
HomeAssistant Azure
0534153ae7 [ci skip] Translation update 2020-01-13 00:31:54 +00:00
Phil Bruckner
89c04c94e0 Revert "Forget auth token when going offline so we can reconnect (#26630)" (#30705)
This reverts commit 2d6d6ba90e.
2020-01-12 14:21:07 -06:00
Yarmo Mackenbach
96bf8bc395 Update NSAPI to version 3.0.0 (#30599)
* Updated NSAPI to version 3.0.0

* Fixed code style error

* Restructured API access

* Improved construction of attributes

* Fixed handling of API output

* Added @YarmoM as code owner

* Updated CODEOWNERS

* Reverted changes for full backwards compatibility

* Fixed bad conditional

* Simplify conditional
2020-01-12 20:30:26 +01:00
Bogdan Vlaicu
5f5e8d81e1 Bumped oru to 0.1.11 (adds a timeout to the api request) (#30704) 2020-01-12 17:55:33 +01:00
Josh Bendavid
c798413971 update aiopylgtv to 0.2.5 (#30702) 2020-01-12 17:55:11 +01:00
Franck Nijhof
6729902010 Fix discovery for oauth2 flow implementations (#30700)
* Fix discovery for oauth2 flow implementations

* Fix user step

* Add tests
2020-01-12 07:37:34 -08:00
Paulus Schoutsen
1b89fef888 Bumped version to 0.104.0b4 2020-01-11 20:16:43 -08:00
Paulus Schoutsen
3715f821d7 Fix update person validation (#30691) 2020-01-11 20:16:18 -08:00
Paulus Schoutsen
dc57d670d8 Log error when integration is missing platform setup (#30690) 2020-01-11 20:16:17 -08:00
Paulus Schoutsen
c00af14ee2 Ring OTP improvement (#30688)
* Fix otp flow

* Update Ring to 0.5

Co-authored-by: steve-gombos <3118886+steve-gombos@users.noreply.github.com>
2020-01-11 20:16:17 -08:00
SukramJ
b383a5195f Fix Error with HomematicIP Cloud Cover (#30667) 2020-01-11 20:16:16 -08:00
SukramJ
4c5ea54df9 Fix Error with HomematicIP Cloud Cover (#30667) 2020-01-11 20:01:13 -08:00
Martin Hjelmare
030a399b09 Make hue config flow tests more robust (#30678)
* Make hue config flow tests robust

* Fix io on setup

* Update last tests
2020-01-11 20:00:49 -08:00
Martin Hjelmare
91f738127d Make met config flow tests robust (#30689)
* Make met config flow tests more robust

* Fix test with default form values

* Remove not needed test

* Clean create entry test

* Clean double test

* Clean last tests

* Fix docstring
2020-01-11 20:00:02 -08:00
Paulus Schoutsen
117efb5a04 Fix update person validation (#30691) 2020-01-11 19:59:43 -08:00
inputd
4dc39492a5 Drop timer component microseconds (#30198)
* Update __init__.py
2020-01-11 22:55:28 -05:00
Bill Durr
4d6417295b ZHA cover device support (#30639)
* ZHA cover device support
* flake8
* flake8, black
* isort
* pylint
* more test
* use zigpy provided functions
* black
* handle command errors, better state handling
* black
* more test
* lint
* Update ZHA cover tests coverage.
Co-authored-by: Alexei Chetroi <lexoid@gmail.com>
2020-01-11 22:42:14 -05:00
Robert Van Gorkom
a0b0dc0aca Optimistically set tplink light states (#30189)
* Optimistically handling state changes.
Using retries when command fail.

* Fixing endless update loop.

* Address PR comments.
2020-01-12 03:45:01 +01:00
Paulus Schoutsen
9266fc0cd7 Ring OTP improvement (#30688)
* Fix otp flow

* Update Ring to 0.5

Co-authored-by: steve-gombos <3118886+steve-gombos@users.noreply.github.com>
2020-01-11 18:22:08 -08:00
Paulus Schoutsen
abe727fbbc Log error when integration is missing platform setup (#30690) 2020-01-11 18:21:57 -08:00
Robert Van Gorkom
672db9cfe9 Fixing unit of measure for withings hydration. Fixes #30570 (#30685) 2020-01-11 20:58:06 -05:00
HomeAssistant Azure
8b46b5591f [ci skip] Translation update 2020-01-12 00:32:04 +00:00
Paulus Schoutsen
e3b37c44d6 Bumped version to 0.104.0b3 2020-01-11 16:17:03 -08:00
Paulus Schoutsen
718f3438ea Upgrade Ring to new version (#30666)
* Upgrade Ring to new version

* Move legacy cleanup down

* Fix test
2020-01-11 16:16:58 -08:00
Paulus Schoutsen
7073b0eb88 Upgrade Ring to new version (#30666)
* Upgrade Ring to new version

* Move legacy cleanup down

* Fix test
2020-01-11 16:04:39 -08:00
Alexei Chetroi
4972b249bf Use collection helpers for input_text entities (#30633)
* Refactor input_text to use config dict.
* Use collections for input_text.
* Update homeassistant/components/input_text/__init__.py
Better logging names.
Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Update homeassistant/components/input_text/__init__.py
Correct artifacts.
Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Update homeassistant/components/input_text/__init__.py
Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Cleanup.
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-01-11 17:37:39 -05:00
Ville Skyttä
4a66eb0a69 Upgrade huawei-lte-api to 1.4.6 (#30683)
https://github.com/Salamek/huawei-lte-api/releases/tag/1.4.6
https://github.com/Salamek/huawei-lte-api/releases/tag/1.4.5
2020-01-11 23:36:40 +01:00
Quentame
519c1fa2da Update iCloud sensors when service finish its update (#30680)
* Update iCloud sensors when needed

* Add sensor should_poll
2020-01-11 23:12:55 +01:00
Ville Skyttä
62f53b656d Fix test_scenes_with_entity (#30684)
Don't assume any particular order for returned scenes; it's undefined
(currently uses dict values()).
2020-01-11 22:25:59 +01:00
Alexei Chetroi
7d506bc38b Use storage collections for input_select entity management (#30604)
* Refactor input_select to use _config dict.
* Use collections for input_select.
* Add tests.
* Move async_setup to top.
* Cleanup.
* async_write_ha_state()
* Update homeassistant/components/input_select/__init__.py
Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>
2020-01-11 11:37:57 -05:00
cgtobi
e793ed9ab0 Refactor Netatmo integration (#29851)
* Refactor to use ids in data class

* Use station_id

* Refactor Netatmo to use oauth

* Remove old code

* Clean up

* Clean up

* Clean up

* Refactor binary sensor

* Add initial light implementation

* Add discovery

* Add set schedule service back in

* Add discovery via homekit

* More work on the light

* Fix set schedule service

* Clean up

* Remove unnecessary code

* Add support for multiple entities/accounts

* Fix MANUFACTURER typo

* Remove multiline inline if statement

* Only add tags when camera type is welcome

* Remove on/off as it's currently broken

* Fix camera turn_on/off

* Fix debug message

* Refactor some camera code

* Refactor camera methods

* Remove old code

* Rename method

* Update persons regularly

* Remove unused code

* Refactor method

* Fix isort

* Add english strings

* Catch NoDevice exception

* Fix unique id and only add sensors for tags if present

* Address comments

* Remove ToDo comment

* Add set_light_auto back in

* Add debug info

* Fix multiple camera issue

* Move camera light service to camera

* Only allow camera entities

* Make test pass

* Upgrade pyatmo module to 3.2.0

* Update requirements

* Remove list comprehension

* Remove guideline violating code

* Remove stale code

* Rename devices to entities

* Remove light platform

* Remove commented code

* Exclude files from coverage

* Remove unused code

* Fix unique id

* Address comments

* Fix comments

* Exclude sensor as well

* Add another test

* Use core interfaces
2020-01-11 12:20:00 +01:00
etheralm
5ffbf55170 Add support for Dyson TP06 fan (#30611)
* initial commit

* update manifest.json

* update CODEOWNERS

* remove unnecessary else

* add rest of asserts for TP06 state test
2020-01-11 10:41:52 +01:00
Jörg Thalheim
b128814acf pushover: improve error when image download fails (#30615) 2020-01-11 10:36:50 +01:00
Alexei Chetroi
9c551ae85d Use storage based collections for input_number entities (#30576)
* Use collections for input_number.
* Add tests.
* Typo fix.
* Make editable a public attribute.
* Move async_setup to top.
* Update homeassistant/components/input_number/__init__.py
Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Update homeassistant/components/input_number/__init__.py
Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Cleanup.
* async_write_ha_state()
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-01-10 23:27:41 -05:00
Paulus Schoutsen
86bdba2ea2 Bumped version to 0.104.0b2 2020-01-10 20:18:35 -08:00
HomeAssistant Azure
77d184ee25 [ci skip] Translation update 2020-01-10 20:18:20 -08:00
HomeAssistant Azure
d0357ceecd [ci skip] Translation update 2020-01-10 20:18:20 -08:00
HomeAssistant Azure
0fc2cce4dc [ci skip] Translation update 2020-01-10 20:18:20 -08:00
Dave T
80a1084f2d Update ON/OFF condition and triggers to match documentation and UI, issue #30462 (#30663) 2020-01-10 20:17:13 -08:00
Alexei Chetroi
2eff988a5c Fix ZHA temperature sensor restoration (#30661)
* Add test for restoring state for zha temp.

* Don't restore unit of measurement for ZHA sensors.

Properly restore ZHA temperature sensor state.
2020-01-10 20:17:12 -08:00
Jc2k
449e6841a7 Fix HomeKit with entity registry restoration where supported_features is a non-None falsey (#30657)
* Fix homekit with #30094

* Fix test
2020-01-10 20:17:12 -08:00
Dave T
c1c90b8034 Update ON/OFF condition and triggers to match documentation and UI, issue #30462 (#30663) 2020-01-10 19:59:11 -08:00
Alexei Chetroi
008dddb17c Fix ZHA temperature sensor restoration (#30661)
* Add test for restoring state for zha temp.

* Don't restore unit of measurement for ZHA sensors.

Properly restore ZHA temperature sensor state.
2020-01-10 20:30:58 -05:00
ochlocracy
605b0ceb5f Add support for variable fan speed list length. (#30574) 2020-01-10 17:26:37 -08:00
Jc2k
669c89e8c0 Fix HomeKit with entity registry restoration where supported_features is a non-None falsey (#30657)
* Fix homekit with #30094

* Fix test
2020-01-10 16:33:48 -08:00
HomeAssistant Azure
d6512c8a9f [ci skip] Translation update 2020-01-11 00:31:55 +00:00
ochlocracy
74a198e37b Implement TimeHoldController Interface in Alexa (#30650)
* Implement Alexa.TimeHoldController Interface

* Add test for timer resume directive.
2020-01-10 23:11:50 +01:00
Paulus Schoutsen
f505310f11 Bumped version to 0.104.0b1 2020-01-10 13:37:13 -08:00
Phil Bruckner
626c01b4a0 Do not save last_seen if older than prev_seen (#30647)
Also add warnings when updates skipped similar to google_maps
2020-01-10 13:37:03 -08:00
springstan
c785b791a2 Bump Adafruit_BBIO to 1.1.1 (#30630) 2020-01-10 13:37:02 -08:00
Pascal Vizeli
a6492cc7bb Set body size for Proxy / streams to 16mb (#30608) 2020-01-10 13:37:02 -08:00
Robert Svensson
5a8311e9d8 Fix problem with restoring POE control (#30597) 2020-01-10 13:37:01 -08:00
Paulus Schoutsen
0b3b589457 Add Ring config flow (#30564)
* Add Ring config flow

* Address comments + migrate platforms to config entry

* Migrate camera too

* Address comments

* Fix order config flows

* setup -> async_setup
2020-01-10 13:36:34 -08:00
Paulus Schoutsen
e58b41ef23 Implement capability attributes (#30545)
* Implement capability attributes

* Fix HeOS update order

* Fix test
2020-01-10 13:35:44 -08:00
Phil Bruckner
c7e300e5b1 Fix upnp raw sensor state formatting when None (#30444) 2020-01-10 13:35:43 -08:00
NobleKangaroo
e2f591e5bc Remove self as Emulated Hue codeowner (#30654) 2020-01-10 22:35:18 +01:00
ochlocracy
d0062fc740 Fix Alexa ChangeReports Filter non-proactively_reported_properties (#30655)
* Fix Change Report Properties.

* Fix Change Report Properties.
2020-01-10 22:34:50 +01:00
Paulus Schoutsen
3f29c234b8 Add Ring config flow (#30564)
* Add Ring config flow

* Address comments + migrate platforms to config entry

* Migrate camera too

* Address comments

* Fix order config flows

* setup -> async_setup
2020-01-10 21:35:31 +01:00
Paulus Schoutsen
3348f4f6d1 Add search integration (#30511)
* Add search integration

* Add scenes and config entry support

* Update comments

* Add support for groups

* Allow querying config entry

* Update manifest

* Fix scene tests
2020-01-10 19:57:37 +01:00
Robert Svensson
d883ee62f8 deCONZ - Disable daylight sensor by default (#30625)
* Dont enable daylight sensor by default

* Fix tests
2020-01-10 19:57:08 +01:00
springstan
c13b461737 Bump Adafruit_BBIO to 1.1.1 (#30630) 2020-01-10 19:56:41 +01:00
Ville Skyttä
74cde3de6e Upgrade pydocstyle to 5.0.2 (#30648)
https://github.com/PyCQA/pydocstyle/blob/5.0.2/docs/release_notes.rst
2020-01-10 19:56:07 +01:00
Fabian Affolter
fb2e059346 Upgrade colorlog to 4.1.0 (#30642) 2020-01-10 19:55:49 +01:00
Phil Bruckner
d65f2ac31a Do not save last_seen if older than prev_seen (#30647)
Also add warnings when updates skipped similar to google_maps
2020-01-10 19:55:39 +01:00
Fabian Affolter
53a42ccd5d Upgrade pylast to 3.2.0 (#30644) 2020-01-10 16:59:40 +01:00
Fabian Affolter
5e3747a058 Upgrade shodan to 1.21.2 (#30641) 2020-01-10 16:58:13 +01:00
Fabian Affolter
ec1109329b Upgrade praw to 6.5.0 (#30643) 2020-01-10 16:57:52 +01:00
Raman Gupta
d25aa1f183 Convert vizio component from sync to async component (#30605)
* add device_info property and move component to async

* use new VizioAsync class to have proper async support

* remove hass from VizioDevice init since it is not needed

* update requirements_all

* missed type hint

* updates based on review

* pyvizio version bump

* additional fixes based on review

* mistake in last commit

* remove device_info property because it can't be used unless this integration has config flow support
2020-01-10 03:53:47 +01:00
escoand
ef05aa2f39 Add Samsung TV config flow (#28306)
* add config flow

* add tests

* add user step error handling

* remove unload function

* add missing test file

* handle authentication correctly

* remove old discovery mode

* better handling of remote class

* optimized abort messages

* add already configured test for user flow

* Import order

* use ip property instead context

* Black

* small syntax

* use snake_case

* Revert "use ip property instead context"

This reverts commit 91502407eb216f8a0b1b90e3e6fb165b81406f8f.

* disable wrong pylint errors

* disable wrong no-member

* Try to fix review comments

* Try to fix review comments

* Fix missing self

* Fix ip checks

* methods to functions

* simplify user check

* remove user errors

* use async_setup for config

* fix after rebase

* import config to user config flow

* patch all samsungctl

* fix after rebase

* fix notes

* remove unused variable

* ignore old setup function

* fix after merge

* pass configuration to import step

* isort

* fix recursion

* remove timeout config

* add turn on action (dry without testing)

* use upstream checks

* cleanup

* minor

* correctly await async method

* ignore unused import

* async call send_key

* Revert "async call send_key"

This reverts commit f37057819f.

* fix comments

* fix timeout test

* test turn on action

* Update media_player.py

* Update test_media_player.py

* Update test_media_player.py

* use async executor

* use newer ssdp data

* update manually configured with ssdp data

* dont setup component directly

* ensure list

* check updated device info

* Update config_flow.py

* Update __init__.py

* fix duplicate check

* simplified unique check

* move method detection to config_flow

* move unique test to init

* fix after real world test

* optimize config_validation

* update device_info on ssdp discovery

* cleaner update listener

* fix lint

* fix method signature

* add note for manual config to confirm message

* fix turn_on_action

* pass script

* patch delay

* remove device info update
2020-01-10 03:19:10 +01:00
HomeAssistant Azure
4fb36451c2 [ci skip] Translation update 2020-01-10 00:31:50 +00:00
Nathan
955aa1de39 Add INFO logging to generic_thermostat component for keep-alive turn … (#28740)
* Add INFO logging to generic_thermostat component for keep-alive turn on/off

* run black
2020-01-10 00:20:16 +01:00
tiagofreire-pt
7052cdded1 Change nomenclature for Roborock fan speeds (#30614)
* Change nomenclature for Roborock fan speeds 

* Update test_vacuum.py

* Update test_vacuum.py
2020-01-09 23:49:13 +01:00
Daniel Lashua
669844e4dd Check netgear device_tracker link_rate to ensure device is connected (#30581)
* check link_rate to ensure device is connected

* black
2020-01-09 20:45:42 +01:00
Davide Varricchio
208a123c47 Update PYAEHW4A1 to version 0.3.4 (#30616)
* Update manifest.json

* Update requirements_all.txt

* Update requirements_test_all.txt
2020-01-09 13:07:23 -05:00
Nikolay Vasilchuk
f878fabd09 Fix TOD component incorrectly determining the state between sunrise and sunset (#30199)
* TOD fix

* Comment added

* Review

* Review

* Review
2020-01-09 17:17:16 +01:00
William Sutton
3a3d448f17 Add preset scheduling to radiothermostat (#29847)
* Added preset scheduling to radiothermostat. Added alternate scheduling & religious scheduling to climate/const.py

* Fix Flake8 Errors in climate.py

* Fixing more flake8 errors in climate.py

Removed duplicate set_preset_mode def

* Fixed more flake8 errors. 

Please be the end of these errors.

* Fixed black formatting

* Fixed black, broke flake8, fixed flake8

* Fixed CODE_TO_FAN_STATE black error

* Fixed isort issues

* Local isort broke black formatting

Docs should run isort before black. Default isort will undo certain black formatting.

* Removed last commas from imports

* Added removed line

* Fixed formatting

Hopefully this is what the CI pipeline is looking for.

* Ran isort from git repo root, utilizing setup.cfg.

* One more try

* fixed added definition and fixed logger string

* fixed formatting

* lost a close-paren

* Update const.py

Removed radiotherm specific presets

* Update climate.py

Moved preset definitions into radiotherm climate.py
2020-01-09 15:25:19 +01:00
Malte Franken
4149bd653d Fix statistics sensor honouring max_age (#27372)
* added update listener if max_age is set

* remove commented out code

* streamline test code

* schedule next update based on the next state to expire

* fixed update process

* isort

* fixed callback function

* fixed log message

* removed logging from test case
2020-01-09 14:03:27 +01:00
David Bonnes
a99135a09e tweak honeywell manifest (#30612) 2020-01-09 12:36:32 +00:00
Pascal Vizeli
a4c1114c8e Set body size for Proxy / streams to 16mb (#30608) 2020-01-09 11:09:34 +01:00
Martin Hjelmare
9ebf5ea413 Fix aurora import order (#30606) 2020-01-09 10:25:03 +01:00
Olen
290043aed6 Add neato boundary name to state if it exists (#29915)
* Add boundary name to state if it exists

If the robot is cleaning a pre defined area with a name, add the name to the state-attribute.

* Reformat patch

* Removing whitespace

* Even more formatting 

That black did not catch on first run...
2020-01-09 09:42:18 +01:00
Watchfox
6b7be35f4a Fix aurora sensor not converting latitude and longitude correctly (#28643) 2020-01-09 08:40:10 +01:00
Phil Bruckner
260596d11b Fix upnp raw sensor state formatting when None (#30444) 2020-01-09 06:51:30 +01:00
Alistair Galbraith
fe0b537291 Template alarm panel (#30487)
* Added support for template alarm panel

* Rewrote tests in new async format

* Fix stale docstring

* Update to tests, standardization on NAME vs FRIENDLY_NAME
2020-01-09 06:03:26 +01:00
HomeAssistant Azure
8062bed53e [ci skip] Translation update 2020-01-09 00:31:49 +00:00
Daniel Perna
9ce5c65b14 Update pyhomematic to 0.1.63 (#30594) 2020-01-09 00:32:57 +01:00
Robert Svensson
ff5f890e79 Fix problem with restoring POE control (#30597) 2020-01-08 22:33:51 +01:00
Matt Snyder
103d352b1f Add Doorbird events to logbook (#30588)
* Add Doorbird events to logbook

* Add logbook to dependencies
2020-01-08 21:27:48 +01:00
Paulus Schoutsen
ed6aef2fd7 Implement capability attributes (#30545)
* Implement capability attributes

* Fix HeOS update order

* Fix test
2020-01-08 21:22:56 +01:00
Paulus Schoutsen
4cd83e71dd Version bump to 0.105.0dev0 2020-01-08 21:07:04 +01:00
Paulus Schoutsen
5d850c5b19 Bumped version to 0.104.0b0 2020-01-08 21:06:22 +01:00
Paulus Schoutsen
95bc539bab Merge remote-tracking branch 'origin/master' into dev 2020-01-08 21:05:53 +01:00
Mariano Faraco
9e885112ec Add last_online and level attribute to steam online (#30321)
* Steam Online: Add last_online and Level attributes

* Steam Online: Add last_online and Level attributes

* Fixes from comments on initial pull request

* Push attributes only if they are not None
2020-01-08 21:04:42 +01:00
mohmacht
d048233776 The MFI Dimmer Switch model is missing from the list, causing the mfi Wall switches not to be recognized. (#30572)
Please add this one model to support my mfi switches, thank you.

 python 1.py dump_sensors --noverify
               Model |                Label |             Tag |      Value | Extra
------------------------------------------------------------------------------
       Dimmer Switch |        Bedroom2Light |      active_pwr |  22.047071 | 1.0
       Dimmer Switch |      LivingRoomLight |      active_pwr |        0.0 | 0.0
       Dimmer Switch |      FamilyRoomLight |      active_pwr |  42.803919 | 1.0
       Dimmer Switch |   MasterBedroomLight |      active_pwr |        0.0 | 0.0
2020-01-08 21:04:33 +01:00
fwestenberg
498bec4a61 Add Stookalert integration (#30306)
* Added Stookalert integration

* Added Stookalert integration

* Added Stookalert integration

* Solved comments

* Flake8 change

* Bump stookalert to version 1.1.2

* Fixed attributes and state

* Get method for private variables

*  Update to stookalert 0.1.4

* Code optimization

* Update requirements
2020-01-08 21:03:50 +01:00
Franck Nijhof
d659807b6f Fix WLED transition time unit (#30583) 2020-01-08 21:03:36 +01:00
Bram Kragten
6112092949 Updated frontend to 20200108.0 (#30591) 2020-01-08 21:02:07 +01:00
David Bonnes
2c1e354537 evohome: allow two round thermostats per gateway (#30589)
* bugfix issue #30517
* bump library, tweak name in manifest
* remove lint hint
2020-01-08 18:57:28 +00:00
Maciej Bieniek
4cd2e09fb3 Add missing string for already_configured in GIOS integration (#30590) 2020-01-08 19:44:03 +01:00
Franck Nijhof
120a96ff59 Bump adguardhome to 0.4.1 (#30586) 2020-01-08 10:48:57 -05:00
Maciej Bieniek
6e3e383b3f Add missing string for already_configured in Brother integration (#30584) 2020-01-08 16:15:05 +01:00
Franck Nijhof
0e9b414c26 Migrate Integration Quality Scale from docs to manifest (#30579) 2020-01-08 14:19:42 +01:00
Alexei Chetroi
ae8957ae12 Use more consts for person implementation (#30553)
* Use more consts for person implementation.

* Use ATTR_ENTITY_ID.
2020-01-08 07:35:34 -05:00
Santobert
3d7488d188 Trigger automation without skipping condition (#28484)
* Trigger automation without skipping condition

* [] instead of .get()

* Update __init__.py

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-01-08 10:36:11 +01:00
Robert Svensson
84a1afc785 deCONZ - Fix device automations (#30577) 2020-01-08 10:06:33 +01:00
Robert Svensson
0d48d682dc deCONZ - Make sensors sorted on creation for deterministic order (#30569)
* Make sensors sorted on creation for deterministic order

* Martins comment
2020-01-08 09:30:02 +01:00
Ernst Klamer
31553796da Bump pyRFXtrx to 0.25 (#30566) 2020-01-08 09:20:50 +01:00
Daniel Shokouhi
130a577e67 Add android repo to issue template (#30571) 2020-01-07 22:10:04 -05:00
HomeAssistant Azure
8b7ffcdaf1 [ci skip] Translation update 2020-01-08 00:31:50 +00:00
Bram Kragten
16199b7a52 Add command to delete lovelace config (#30558)
* Add command to delete lovelace config

* Test + decorator for WS
2020-01-07 22:59:04 +01:00
Bram Kragten
1ce662d699 Updated frontend to 20200107.0 (#30561) 2020-01-07 22:55:10 +01:00
Franck Nijhof
bfa0edaf92 Migrate Integration Quality Scale from docs to manifest: internal (#30551) 2020-01-07 20:58:49 +01:00
Sascha Kühndel
23700e4db8 Fix hue flashing innr lights (#29828) 2020-01-07 20:56:57 +01:00
FrengerH
83d18c183b Fix missing strings for deconz magic cube rotation support (#30552)
* Fix missing strings for deconz magic cube rotation

* Fix missing strings for deconz magic cube rotation
2020-01-07 19:06:25 +01:00
Aaron Bach
856db4d122 Fix incorrect Rainmachine dict lookups (#30550) 2020-01-07 10:43:12 -07:00
Paulus Schoutsen
9aa02e35a7 Entity Component to no longer generate automatic groups (#23789) 2020-01-07 17:30:53 +01:00
tetienne
13e6479b6e Ease code before adding color and temperature to light template (#30455)
* Split async_update

* Use pytest parameters to avoid duplicate code

* Fix UnboundLocalError

* Test error rendering for template state

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-01-07 17:22:42 +01:00
Franck Nijhof
e18426051b Add Integration Quality Scale to manifest (#30547) 2020-01-07 17:21:56 +01:00
SukramJ
a4c830b5e4 Add reset_energy_counter service to Homematic IP Cloud (#30256)
* Add reset_energy_counter service to Homematic IP Cloud

* Fix isort

* Register service as admin service
2020-01-07 10:24:46 -05:00
Aleix Murtra
1d1aa06d05 Add TMB sensor (#27964)
* Add TMB i-Bus sensor

* Raise exception if HTTP error

* Addressed comments

* Fixed format

* Fixed format

* Addressed comments

* Remove guard before add_entities method

* Remove unauthorized exception

* Make CONF_BUS_STOPS option required
2020-01-07 16:22:16 +01:00
Franck Nijhof
b4d6d238e5 Correct names in manifests (T-Z) (#30546) 2020-01-07 14:31:18 +01:00
springstan
a5cc08c8b6 Update featured integrations screenshot in README (#30134)
* Update featured integrations in README

* Update screenshot to include Somfy and exclude Almond

* Update outdated screenshot of featured components
2020-01-07 14:30:52 +01:00
Franck Nijhof
22760a0bee Correct names in manifests (Q-S) (#30543) 2020-01-07 08:19:44 -05:00
Paulus Schoutsen
b27e05fc8d Use capability attributes in climate (#30544)
Co-authored-by: Jc2k <john.carr@unrouted.co.uk>
2020-01-07 14:14:46 +01:00
Raman Gupta
a9f6dd698e Remove suppress_warning from config options for vizio component (#30536)
* move constants, move schema validation to init, prepare for zeroconf/config flow

* mistake in refactor

* update .coveragerc, move validate_auth to __init__, only attempt to get ESN if device setup is validated

* fix schema validation

* remove suppress warning config option

* remove config_flow from manifest since its not ready yet

* update requirements_all.txt

* fix issue with merge conflict
2020-01-07 13:31:13 +01:00
Jeff Irion
73af75cb41 Catch UnicodeDecodeError exceptions in 'androidtv.adb_command' service (#30538)
* Catch UnicodeDecodeError exceptions in 'androidtv.adb_command' service

* Replace "adb_command" with SERVICE_ADB_COMMAND
2020-01-07 13:30:34 +01:00
Jeff Irion
98bb400f3a Bump adb-shell to 0.1.1 and androidtv to 0.0.38 (#30539)
* Bump adb-shell to 0.1.1 and androidtv to 0.0.38

* Bump adb-shell to 0.1.1 and androidtv to 0.0.38

* Bump adb-shell to 0.1.1 and androidtv to 0.0.38
2020-01-07 13:30:15 +01:00
Franck Nijhof
dc02c28891 Correct names in manifests (M-P) (#30541) 2020-01-07 13:28:35 +01:00
Paulus Schoutsen
c963128306 Upgrade to use new version of HASS-nabucasa (#30506)
* Upgrade to use new version of HASS-nabucasa

* Update hass-nabucasa to 0.31
2020-01-07 13:25:57 +01:00
Casper
6dc49a44d9 Update manifest.json: Typo fixed (#30542) 2020-01-07 13:23:52 +01:00
Colin Frei
b3f429eefa Swiss Transport Data: Save delay on sensor (#30526) 2020-01-07 12:27:34 +01:00
Jason Ross
692e87f5cc Add venstar PIN to config and client initialization (#30300)
* Add PIN to config and client  initialization

* Fix Formatting Error

* update PLATFORM_SCHEMA validation with the new option.
2020-01-07 10:20:46 +01:00
Alexei Chetroi
6740249bef Use collection helpers for input_boolean (#30514)
* Refactor input_boolean to use config dict for instantiation.

* Refactor input_boolean to use YamlCollection.

* Add storage collection to input_boolean.

* Update homeassistant/components/input_boolean/__init__.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Doh.

* Address comments.

* Add editable device state attribute.

* Clean up entities from entity registry on removal.

Reload yaml from correct source.

* Add tests.

* Update homeassistant/components/input_boolean/__init__.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Don't reset entity state on updates.

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-01-07 08:53:43 +01:00
Franck Nijhof
345cc244ed Correct names in manifests (C-L) (#30532) 2020-01-07 08:19:17 +01:00
Raman Gupta
7d58de1bda Update vizio component to prepare for config flow and zeroconf support (#30522)
* move constants, move schema validation to init, prepare for zeroconf/config flow

* update requirements_all and make setup validation more pythonic

* mistake in refactor

* un-revert change from previous PR

* rename schema var

* update .coveragerc, move validate_auth to __init__, only attempt to get ESN if device setup is validated

* reinstate validate_setup but change logic to use new connection test function

* fix schema validation

* simplify string empty check logic

* missed commit
2020-01-06 20:32:31 -05:00
Eleftherios Chamakiotis
e22742550c Add "autobypass" option when arming AlarmDecoder integration (#30002)
* Initial implementation

* Passing autobypass parameter to constructor, as suggested

* Black formatting

* Removed default value from autobypass parameter of the constructor, as it's redundant
2020-01-06 20:17:21 -05:00
Trekky12
5ed1f16f25 Add pilight dimmer as light component (#30107)
* Add pilight dimmer as light component

* fix CI errors

* fix missing new lines

* improve formatting and addresses comments of @springstan

* rename config parameter and remove super() call to match pylint

* import only used constants of the pilight component

* Add myself to the code owners

* fix CODEOWNERS
2020-01-06 20:13:08 -05:00
HomeAssistant Azure
8c70fb5463 [ci skip] Translation update 2020-01-07 00:32:07 +00:00
Quentame
1587603c4c Bump synologydsm to 0.3.0 (#30529) 2020-01-06 17:38:42 -06:00
Markus Nigbur
453f7c7294 Fire restarted event on restarting active timer (#30475)
* Fire restarted event on restarting active timer

* Added test for the restart event
2020-01-07 00:00:23 +01:00
Franck Nijhof
6f92c19302 Correct integration names in manifests (A-B) (#30527)
* Correct names in manifests (A-B)

* Just Baidu

* Asterisk Call Detail Records
2020-01-06 23:59:12 +01:00
rccoleman
4a2987e790 Allow specific status codes while notifying mobile_app devices (#30496)
* Removed check and return with a notification status of 201

* Allow additional result codes

Allow 200, 201, and 202 as valid result codes
2020-01-06 23:41:07 +01:00
Jeff Irion
5ec5df77cc Register 'androidtv.download' and 'androidtv.upload' services (#30086)
* Add tests

* Add FileSync test

* Fill in services.yaml for 'androidtv.adb_filesync' service

* Update example paths in services.yaml

* Bump androidtv to 0.0.37

* Bump androidtv to 0.0.37

* Bump androidtv to 0.0.37

* Import LockNotAcquiredException

* Import LockNotAcquiredException from androidtv.exceptions

* Rename 'host' to 'address'

* Add a logging statement when an ADB command is skipped

* Check hass.config.is_allowed_path(local_path)

* Add return

* Fix pylint

* Reduce duplicated code (AndroidTVDevice vs. FireTVDevice)

* Split 'adb_filesync' service into 'download' and 'upload' services

* Don't use '.get()' for required data; return if the services are already registered

* Replace "command" with ATTR_COMMAND

* Don't try to connect to a device if it is a duplicate
2020-01-06 23:10:13 +01:00
Paulus Schoutsen
fbc53a886f Merge pull request #30525 from home-assistant/rc
0.103.6
2020-01-06 22:43:24 +01:00
Alexxander0
e88bfda2a8 Fix AVM FRITZ!DECT switch total consumption (#30478)
actor.get_energy() returns Wh, so division by 1000 is correct
2020-01-06 22:23:26 +01:00
Paulus Schoutsen
5675f16b61 Bumped version to 0.103.6 2020-01-06 22:02:31 +01:00
Paulus Schoutsen
4d0a093ec4 Fix google sync (#30524) 2020-01-06 22:02:25 +01:00
michaeldavie
60a9de40aa Bump env_canada to 0.0.31 (#30409) 2020-01-06 22:02:24 +01:00
Andrew Sayre
ed6b95f14a Bump pysmartthings 0.7.0 (#30302) 2020-01-06 22:01:06 +01:00
Robert Svensson
ce114b81c3 Handle wired bug on restart (#30276) 2020-01-06 22:01:05 +01:00
Paulus Schoutsen
05374d7c85 Fix google sync (#30524) 2020-01-06 22:00:39 +01:00
Franck Nijhof
a84741392b Format all manifests with prettier (#30521) 2020-01-06 21:28:23 +01:00
Maciej Bieniek
21029b1d7b Add Brother Printer integration (#30359)
* Init entities as unavailable when offline

* Initial commit

* Fix CODEOWNERS

* CODEOWNERS

* Run script.hassfest

* Add initial test

* Bump library

* More tests

* Tests

* Add new sensors and fix KeyError

* Fix unique_id and device_info

* Fix check for configured device

* More tests

* Bump library version

* Add uptime sensor

* Use config entry unique ID

* Run python3 -m script.gen_requirements_all

* Fix pylint error

* Remove pysnmp dependency

* Raise ConfigEntryNotReady when device offline at HA start

* Remove period from logging message

* Generator simplification

* Change raise_on_progress

* Rename data to printer

* Move update state to async_update

* Remove unused _unit_of_measurement

* Remove update of device_info

* Suggested change for tests

* Remove unnecessary argument

* Suggested change
2020-01-06 11:06:16 -06:00
Jc2k
8257ea30c0 Set required_features field when registering fan services (#30516)
* Set required_features on fan services

* Fix mqtt fan test

* Update fan.py
2020-01-06 17:10:51 +01:00
Jc2k
a58c796641 Add support for homekit air quality sensors (#30510)
* Add air quality sensor

* Fix comment from review

* Fix comment from review

* Lint fix
2020-01-06 16:35:10 +01:00
Ben
1fffa210e1 Add surepetcare component (#24426)
* add surepetcare

* cleanup

* remove unused imports and comments

* remove comment

* fix bug which prevented updating the sensors

* improve config validation

* fix voluptuous usage

* fix format & credential storage

* various fixes to hass-conform

* small format fixes

* change False to None

* still trying to be hass-conform

* remove unused class

* fix imports

* fix f-string

* add guard clause?!

* central data fetch

* do not pass in hass, will be provided automatically

* make the linters happy

* disable constant-test warning and add commas

* worksforme

* fix link in manifest

* remove icon

* bump surepy to 0.1.5

* worksforme

* small doc fixes

* add discovery_info guard

* result of another awesome review

* and again :)

* exclude surepetcare in .coveragerc
2020-01-06 09:00:01 -05:00
SukramJ
0971c681af Add HmIP-PMFS and HmIP-WHS2 to HomematicIP Cloud (#30325)
* update test data

* Update homematicip_cloud.json

* Add HmIP-WHS2

* Add HmIP-PMFS
2020-01-06 08:35:41 -05:00
Gido
10e698e0b2 Update GarbageTypeCodes for rova
Updating rova/sensor.py. Rova json format changed for garbage collection.
2020-01-06 08:34:15 -05:00
Ville Skyttä
80cbc32c49 Spell Zigbee consistently, with lowercase "b" (#30440)
https://zigbeealliance.org/developer_resources/zigbee-specification/
"Please note that this uses old branding, Zigbee is always a lowercase
 B, not a capital. This change occurred shortly after the official
 release of this document."

Also other docs at https://zigbeealliance.org/solution_type/zigbee/,
https://github.com/zigpy/zigpy/issues/111
2020-01-06 08:32:10 -05:00
FrengerH
0d1da9f5cb deCONZ - Rotation support for Xiaomi magic cube (#30472)
* Added rotation to deconz magic cube event

* Device trigger support
2020-01-06 12:34:27 +01:00
Alan Tse
f4f7c25f74 Bump teslajsonpy to 0.2.2 (#30512)
Fixes #30235
2020-01-06 09:52:26 +01:00
HomeAssistant Azure
d1ed67f44a [ci skip] Translation update 2020-01-06 00:32:11 +00:00
brefra
4efbe7135c Add LED control of push buttons and bump velbus-library (#30445)
* Add LED control

* Bump python-velbus library to 2.0.35

To have LED control available in library

* Apply black formating

* Fix no-else-return pylint error

* Changed to f-string and more dry code

* Rewrite turn_on for LED control
2020-01-06 01:28:10 +01:00
Franck Nijhof
e642d95d0f Migrate collection of component tests from coroutine to async/await (#30504) 2020-01-06 01:22:22 +01:00
Ville Skyttä
f400b77837 Preserve new BLE tracker item name if seen before adding discovery (#30318)
* Preserve new BLE device name if one seen before the last scan but not on it

* Save an indented else block

* Use async_fire_time_changed and mock_device_tracker_conf in tests
2020-01-05 23:13:54 +02:00
Jc2k
fffc5a5fbb Add support for v1 and v2 HomeKit fans. (#30503)
* Add support for v1 and v2 HomeKit fans.

* Lint fix
2020-01-05 15:56:46 +01:00
Paulus Schoutsen
8625e962ce Remove double person data validation (#30501) 2020-01-05 15:50:59 +01:00
Franck Nijhof
0a9ac91dec Migrate automatic tests from coroutine to async/await (#30371)
* Migrate automatic tests from coroutine to async/await

* Remove unneeded side effect

* Replace unittest with asynctest, add additional asserts to tests
2020-01-05 07:23:22 -06:00
Ville Skyttä
5216477353 Be consistent with Home Assistant and Hass.io spelling (#30500)
* Be consistent with Home Assistant spelling

* Be consistent with Hass.io spelling
2020-01-05 14:09:17 +02:00
Paulus Schoutsen
24b25b8917 Restore state helper to work with entity registry restoration (#30451)
* Restore state helper to work with entity registry restoratino

* Update restore_state.py
2020-01-05 11:58:59 +01:00
Raman Gupta
2ac5862eda Add unique id property for Vizio devices so they get added to entity registry (#30497)
* add unique id property for Vizio devices so they get added to entity registry

* update requirements

* small change to make code more readable

* update to use f-string for consistency

* fix property name

* set unique_id to none if serial number couldnt be found

* set unique_id to none

* ESN should be globally unique so no device type needed. pyvizio will set ESN to None if ESN is unobtainable
2020-01-05 11:20:06 +01:00
Paulus Schoutsen
30076d1843 Add person reload service (#30493) 2020-01-05 11:16:37 +01:00
Robert Svensson
35e19eec18 Axis - Allow manual configuration to update existing configuration (#30467)
* Allow manual configuration to update existing configuration

* Harmonize tests

* Understand what Elupus means...
2020-01-05 10:11:17 +01:00
HomeAssistant Azure
063193e6e5 [ci skip] Translation update 2020-01-05 00:32:15 +00:00
Pascal Vizeli
e95a04b6f6 bump hassio-builder version 2020-01-05 00:28:42 +01:00
Pascal Vizeli
8c2858ebde support odroid-n2 on release 2020-01-05 00:26:39 +01:00
Paulus Schoutsen
95cd0a2c68 Mobile App add device tracker to person registering app (#30460) 2020-01-04 23:15:50 +01:00
Phil Bruckner
e233dd7cbe Fix timer with empty config (#30463) 2020-01-04 23:01:58 +01:00
David F. Mulcahey
6c89b6c5a2 Add Zigbee group binding to ZHA (#30433)
* initial group binding work
* add group cluster binding
2020-01-04 16:58:51 -05:00
Robert Svensson
967fe89f6d deCONZ - Allow manual configuration to update existing configuration (#30469)
* Allow manual configuration to update existing configuration

* Harmonize tests
2020-01-04 22:55:57 +01:00
Franck Nijhof
639cdf5eef Bump twentemilieu to 0.2.0 (#30471) 2020-01-04 22:55:04 +01:00
Franck Nijhof
42b86d4b4e Bump wled to 0.2.1 (#30474)
* Bump wled to 0.2.0

* Bump wled to 0.2.1
2020-01-04 22:52:37 +01:00
Franck Nijhof
4e62da9c8e Improve WLED pure white support for RGBW (#30477) 2020-01-04 22:52:10 +01:00
Franck Nijhof
51db9bdfce Add unique ID to WLED config entries (#30480)
* Add unique ID to WLED config entries

* Improve robustness of the tests
2020-01-04 22:48:31 +01:00
Franck Nijhof
bf9418e51a Bump adguardhome to 0.4.0 (#30483) 2020-01-04 22:47:34 +01:00
Franck Nijhof
3b14d9f375 Add unique ID to elgato config entries (#30486) 2020-01-04 22:45:11 +01:00
Franck Nijhof
4ea0754094 Fix WLED light transition (#30490) 2020-01-04 22:44:28 +01:00
Franck Nijhof
049ced63b1 Bump elgato to 0.2.0 (#30485) 2020-01-04 20:25:07 +01:00
Paulus Schoutsen
2f362b44c4 Allow adding unique device ID to mobile app registration (#30457)
* Allow adding unique device ID to mobile app registration

* Remove unknown data

* Better fix
2020-01-04 13:45:03 +01:00
Paulus Schoutsen
6e909ab3f1 Only return remote UI url if remote UI enabled (#30453) 2020-01-04 13:43:59 +01:00
Robert Svensson
63347ebeb5 Make Axis integration use config entry unique id (#30461)
* Make Axis integration use config entry unique id
2020-01-04 08:58:18 +01:00
HomeAssistant Azure
075d3f6e32 [ci skip] Translation update 2020-01-04 00:32:23 +00:00
Joakim Plate
8dc57a3700 Allow all sources and sound modes to be selected in google assistant (#30418)
* Simplify media player source list

Google don't need a whitelisted set of modes anymore. So let's just forward any mode that we have.

* Report current mode with the setting name, not a synonym

* Refactor mode generation to support other modes

* Support sound mode as mode as well

* Adjust failing test now with sound modes
2020-01-04 00:39:03 +01:00
Phil Bruckner
d6e230e66b Fix counter with empty config (#30454) 2020-01-04 00:03:54 +01:00
brefra
b75aa7eb3a Fix async call inside sync context (#30458)
* Fix async call inside sync context

* Apply black formatting
2020-01-04 00:01:37 +01:00
Paulus Schoutsen
b9aba30a6e Extract Collection helper from Person integration (#30313)
* Add CRUD foundation

* Use collection helper in person integration

* Lint/pytest

* Add tests

* Lint

* Create notification
2020-01-03 21:37:11 +01:00
David Cramer
3033dbd86c Add Sentry component (#30422) 2020-01-03 21:34:20 +01:00
Robert Svensson
bb55606d29 Axis - Remove manual configuration and legacy config file import (#30365)
* Remove manual configuration and legacy config file import

* Remove unused imports in tests after rebase
2020-01-03 14:25:31 -06:00
ochlocracy
6387a50697 Implement supported locales for Alexa capabilities (#30285)
* Implement Alexa capability supported locales.

* Check config for supported locales.

* Removed unused import.

* Applied some potpourri to improve code smell.

* Change supported_locales to set.
2020-01-03 21:23:22 +01:00
Jc2k
80701c8f2a Defer homekit_controller initial poll after all entities are created (#30355)
* Make sure first poll happens after sub-platforms are loaded and entities are created.

* Function dosn't need to return anything

* Don't forward entry if already forwarded it
2020-01-03 21:22:27 +01:00
Robert Svensson
2b26af89df Improve tests based on Martins feedback from Axis improve tests (#30442) 2020-01-03 12:23:17 -06:00
Marcelo Moreira de Mello
e7af759330 Bump ring to 0.2.9 (#30439) 2020-01-03 12:19:14 -06:00
Robert Svensson
ec61342ec3 deCONZ - Improve tests based on Martins feedback in Axis integration (#30438) 2020-01-03 18:11:04 +01:00
Josh Anderson
8a1fc8b8f0 Check status field for UPS online binary sensor (#30144)
Avoids issue where status was previously reported as offline when
battery was low or UPS was over voltage
2020-01-03 17:40:36 +01:00
Jc2k
6b519499a7 Don't expose flows that aren't initialised. (#30432)
* Don't expose flows that aren't initialised.

If a flow init does not return immediately then there is a window where our
behaviour is screwy:

 * Can try to configure a flow that isn't ready
 * Can show notifications for discoveries that might yet return an abort

This moves the flow discovery events and notifications to after the flow is
initialised and hides flows that don't have a cur_step from async_progress

* Fix tradfri test

* Black.

* Lint fixes
2020-01-03 17:28:05 +01:00
Jc2k
df6c7b97f5 isort homekit (#30437) 2020-01-03 15:00:44 +00:00
Robert Svensson
536b201472 WIP deCONZ - Support Fyrtur/Kadrilj battery sensors (#30403)
* Sensor.binary is None means unsupported sensor
* Don't create ordinary sensor on ZHABattery type
2020-01-03 15:15:32 +01:00
Bas Nijholt
0d5486f772 Add KEF speakers integration (#28959)
* add KEF speakers platform for the integration

This will work with the KEF LS50 Wireless and KEF LSX speakers.
The development of this code happened on https://github.com/basnijholt/media_player.kef

* rename DATA_KEF -> DOMAIN

* use aiokef v0.2.0 and support LSX and new features

* sort imports

* fix @MartinHjelmare's suggestions

* remove _CONFIGURING

* change STATE_UNKNOWN to None

* use lat and long for unique_id

* bump aiokef to v0.2.2

* use config[ATTR] instead of config.get(ATTR)

* use getmac

* fix case when MAC is None

* use host as instance lifetime id

* fix requirements
2020-01-03 14:59:44 +01:00
Ville Skyttä
fa4fa30461 Various string cleanups (#30435)
* Remove some unnecessary string concatenations

* Replace some simple str.formats with f-strings

* Replace some string concatenations with f-strings
2020-01-03 14:47:06 +01:00
Sérgio
5ad209c6fd Handle telegram event commands with args (#30254)
* Handle telegram event commands with args

* Parse message regargless of command

* Lint

* Use multiple assignment
2020-01-03 08:22:14 -05:00
David K
859935e8bc Update HomeKit position state characteristic for covers (#27867)
* HomeKit: update position state characteristic for covers

position state is a mandatory characteristic for HK window coverings

* Test position state characteristic
2020-01-03 08:19:03 -05:00
Robert Svensson
b57da2f862 Axis - Improve tests based on feedback (#30430)
* Use MockConfigEntry, add_to_hass and hass.config_entries.async_setup

* Mock method instead of handling paths
2020-01-03 13:27:14 +01:00
Joakim Plate
0944d02262 Mark API key as deprecated (#30402)
Service account should be used instead
2020-01-03 12:12:29 +01:00
Ian Duffy
5580ee3fa1 Don't allow badly formed upnp devices to kill auto discovery (#30342)
Prevent the following from occurring:

```
2019-12-31 22:38:41 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 85, in async_init
    return await self._async_handle_step(flow, flow.init_step, data)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 145, in _async_handle_step
    result: Dict = await getattr(flow, method)(user_input)
  File "/usr/src/homeassistant/homeassistant/components/deconz/config_flow.py", line 182, in async_step_ssdp
    if discovery_info[ssdp.ATTR_UPNP_MANUFACTURER_URL] != DECONZ_MANUFACTURERURL:
KeyError: 'manufacturerURL'
2019-12-31 22:38:41 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 85, in async_init
    return await self._async_handle_step(flow, flow.init_step, data)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 145, in _async_handle_step
    result: Dict = await getattr(flow, method)(user_input)
  File "/usr/src/homeassistant/homeassistant/components/deconz/config_flow.py", line 182, in async_step_ssdp
    if discovery_info[ssdp.ATTR_UPNP_MANUFACTURER_URL] != DECONZ_MANUFACTURERURL:
KeyError: 'manufacturerURL'
```
2020-01-03 12:08:40 +01:00
Stefan Agner
3f33fc6122 convert to integer if rounding precision is zero (#30226)
Convert values to integer if rounding precision is zero. With that a
value which is an integer before filtering can be configured to stay
integer when using precision = 0. This also aligns behavior of filters
to how rounding behaves in tempaltes (homeassistant/helpers/template.py,
function forgiving_round).
2020-01-03 11:54:19 +01:00
Jc2k
fdfedd086b Rework FlowManager to use inheritance (#30133)
* Pull async_finish_flow/async_create_flow out of ConfigEntries

* Towards refactoring

* mypy fixes

* Mark Flow manager with abc.* annotations

* Flake8 fixes

* Mypy fixes

* Blacken data_entry_flow

* Blacken longer signatures caused by mypy changes

* test fixes

* Test fixes

* Fix typo

* Avoid protected member lint (W0212) in config_entries

* More protected member fixes

* Missing await
2020-01-03 11:52:01 +01:00
Robert Svensson
0a4f3ec1ec Use config entry unique id for deCONZ (#30122)
* Use config entry unique id

* Clean up

* Backwards compatiblity note

* Fix some of Balloobs comments

* Bump dependency to v66

* Black somehow missed config flow tests...

* Move set unique ID til after possibility to update existing entry
2020-01-03 11:50:53 +01:00
Ville Skyttä
c130e81638 Fix number of times seen in debug message (#30429) 2020-01-03 11:31:50 +01:00
tetienne
f5aa89dd06 Fix set tilt position (#30428) 2020-01-03 11:31:05 +01:00
ochlocracy
3a18ef219b Add RTSP stream support for UVC (Unifi Video Client) integration (#30297)
* Add SUPPORT_STREAM to supported_features.

* Implement stream_source with channel RTSP URIs.

* Add Tests for Stream Support.

* Make stream_source async.

* Removed unused import.

* Re-wrote test to remove warning, and lint error.
2020-01-03 11:30:26 +01:00
Oliver
b097a64010 Implemented media_play & media_pause / push to version 0.7.11 of denonavr (#30421)
* Implement media_play & media_pause / push to version 0.7.11 of denonavr

* fix denonavr version in requirements_test_all.txt
2020-01-02 22:06:33 -06:00
David F. Mulcahey
ef8eefc7a0 Remove ZHA establish device mappings function (#30423)
* remove establish_device_mappings
* inline init
2020-01-02 21:21:09 -05:00
Josh Bendavid
4c6e10a988 Cleanup of state handling in webostv (#30416)
* cleanup unnecessary manipulation of state variables

* update unit test
2020-01-03 02:46:32 +01:00
HomeAssistant Azure
4bf15a07a3 [ci skip] Translation update 2020-01-03 00:32:16 +00:00
Robert Svensson
9b961632af Axis - Improve tests (#30415) 2020-01-03 00:02:59 +01:00
Josh Bendavid
c1936f6fe4 Add generic command/button functionality to webostv (#30379)
* add generic command/button functionality to webostv

* update codeowners
2020-01-02 22:32:56 +01:00
Josh Bendavid
9064058a03 Add generic command functionality to denonavr (#29295)
* Add generic command functionality to denonavr

* add minimal unit tests for denonavr

* fix import order

* simplify denonavr unit test

* handle domain specific service calls with dispatcher

* update unit tests

* update unit tests

* remove unnecessary return value

* fix handling of mock instances in unit tests
2020-01-02 22:30:20 +01:00
michaeldavie
b91cbb50c8 Bump env_canada to 0.0.31 (#30409) 2020-01-02 15:24:43 -06:00
springstan
8e5ccfcb8a Bump miflora and bluepy (#30411) 2020-01-02 15:24:29 -06:00
Franck Nijhof
4f8663846b Migrate frontend tests from coroutine to async/await (#30386) 2020-01-02 14:23:56 -06:00
Franck Nijhof
4e6d415541 Migrate media_player tests from coroutine to async/await (#30387) 2020-01-02 14:23:35 -06:00
Franck Nijhof
b9fcb87d2c Migrate generic tests from coroutine to async/await (#30388) 2020-01-02 14:23:16 -06:00
Franck Nijhof
1e3822bdd7 Migrate group tests from coroutine to async/await (#30389) 2020-01-02 14:22:49 -06:00
Franck Nijhof
332cbbd8b1 Migrate freedns tests from coroutine to async/await (#30390) 2020-01-02 14:22:30 -06:00
Franck Nijhof
5b2b86987b Migrate fido tests from coroutine to async/await (#30391) 2020-01-02 14:22:13 -06:00
Franck Nijhof
7b00e94184 Migrate local_file tests from coroutine to async/await (#30392) 2020-01-02 14:21:54 -06:00
Aaron David Schneider
5edf72c9ea fix issuecomment-570284682 (#30405) 2020-01-02 14:17:37 -06:00
Franck Nijhof
24d5e54eed Bump pre-commit to 1.21.0 (#30406) 2020-01-02 14:16:58 -06:00
Ville Skyttä
e6388e186c Remove unnecessary string literal concatenations (#30360) 2020-01-02 21:17:10 +02:00
Ernst Klamer
cac750066a Remove unnessecary rfxtrx light property def (#30397) 2020-01-02 16:44:29 +01:00
Ernst Klamer
77978a979b Restore state for Rfxtrx devices (#30309)
* Restore state rfxtrx switch

* Restore state RFXtrx lights

* Restore state RFXtrx covers

* Restore comment

* Remove line

* Remove logging

* fix black

* Fix typo
2020-01-02 07:59:13 +01:00
HomeAssistant Azure
769cf19052 [ci skip] Translation update 2020-01-02 00:32:24 +00:00
Alan Tse
fc08c62a31 Add charging rate sensor to Tesla (#30286)
* Add charging rate sensor to Tesla

* Remove reference to bin_type
2020-01-02 00:36:14 +01:00
Franck Nijhof
37d1771400 Migrate google_* tests from coroutine to async/await (#30377) 2020-01-01 17:24:30 -06:00
Franck Nijhof
bcb47dab45 Migrate discovery tests from coroutine to async/await (#30376) 2020-01-01 17:22:32 -06:00
Franck Nijhof
b43b50b6d2 Migrate ffmpeg tests from coroutine to async/await (#30375) 2020-01-01 17:22:08 -06:00
Franck Nijhof
c5298dc4dc Migrate cast tests from coroutine to async/await (#30374) 2020-01-01 17:21:42 -06:00
Franck Nijhof
c837f185f7 Migrate camera tests from coroutine to async/await (#30372) 2020-01-01 17:21:21 -06:00
Franck Nijhof
8814e1eadc Migrate no_ip tests from coroutine to async/await (#30370) 2020-01-01 17:18:40 -06:00
Franck Nijhof
47aa0043bf Migrate owntracks tests from coroutine to async/await (#30369) 2020-01-01 17:18:20 -06:00
Franck Nijhof
1a2a976be2 Migrate counter tests from coroutine to async/await (#30368) 2020-01-01 17:17:55 -06:00
Franck Nijhof
320dc52bb3 Migrate config tests from coroutine to async/await (#30366) 2020-01-01 17:16:27 -06:00
Franck Nijhof
4e7b35355d Migrate websocket_api tests from coroutine to async/await (#30364) 2020-01-01 17:15:29 -06:00
Franck Nijhof
0fb5fbd85c Migrate hassio tests from coroutine to async/await (#30363) 2020-01-01 17:13:43 -06:00
Franck Nijhof
3a4db2fae7 Migrate mailbox tests from coroutine to async/await (#30361) 2020-01-01 17:13:04 -06:00
Aaron David Schneider
99bc911f7f Add attributes to fritz device_tracker (#30350)
* add attributes to device_tracker

* fix pylint

* requested changes

* docstring updated
2020-01-01 22:03:37 +01:00
Alan Tse
790b2d00c7 Fix HVAC mode for Tesla (#30287)
* Fix HVAC mode for Tesla

* Change HVAC_MODE to HEAT_COOL
2020-01-01 20:49:20 +01:00
Fabian Affolter
0479e93de7 Upgrade python_opendata_transport to 0.2.1 (#30348) 2020-01-01 14:06:20 -05:00
Jeff Irion
83e05da0b3 Fix media_player example for select_source service (#30358) 2020-01-01 19:40:11 +01:00
Franck Nijhof
bc6e2a06e6 Migrate yr tests from coroutine to async/await (#30351) 2020-01-01 16:21:37 +01:00
Franck Nijhof
33828ae514 Migrate timer tests from coroutine to async/await (#30352) 2020-01-01 16:20:18 +01:00
Franck Nijhof
9ba0daa358 Migrate teksavvy tests from coroutine to async/await (#30353) 2020-01-01 16:18:17 +01:00
Franck Nijhof
9fbe6d60cb Migrate startca tests from coroutine to async/await (#30354) 2020-01-01 16:17:35 +01:00
Fabian Affolter
e099d57bde Upgrade zeroconf to 0.24.4 (#30347) 2020-01-01 14:04:37 +01:00
Josef Schlehofer
298d898627 Upgrade youtube_dl to version 2020.01.01 (#30341) 2020-01-01 12:36:43 +01:00
Alan Tse
272c00e81b Remove use of bin_type in Tesla component (#30315)
* Remove use of bin_type

* Convert _unit attribute to units

* Remove unnecessary variable assignment

* Change to using util library convert
2020-01-01 12:23:29 +01:00
HomeAssistant Azure
bb2d8e3f7d [ci skip] Translation update 2020-01-01 00:32:22 +00:00
Franck Nijhof
52ed9608e2 Migrate input_* tests from coroutine to async/await (#30336) 2020-01-01 01:22:44 +01:00
Josh Bendavid
fc23b4f83f Migrate webostv to new library and make integration async with callback state updates (#29296)
* migrate webostv to new aiopylgtv version of the library and add support
for generic commands, input/button commands, and callback state updates

* update requirements

* cleanup and bump aiopylgtv version

* update webostv unit tests

* make webostv unit tests work with python 3.7

* cleanup for code checks

* cleanup and code review

* make all client request functions coroutines

* make host required for webostv configuration

* remove generic command and button functionality plus related cleanup

* fix previous track function

* update unit tests

* fix imports for unit tests

* update unit test

* further unit test updates

* remove unnecessary setup call in unit tests

* restore previous behaviour with client key config file in hass configuration directory
2020-01-01 00:26:35 +01:00
Franck Nijhof
af153521dc Migrate emulated_hue tests from coroutine to async/await (#30331) 2019-12-31 16:50:07 -06:00
Franck Nijhof
194cb8dbf5 Migrate xiaomi_miio tests from coroutine to async/await (#30329) 2019-12-31 16:49:00 -06:00
Franck Nijhof
2ac5537495 Migrate alexa tests from coroutine to async/await (#30332) 2019-12-31 16:48:17 -06:00
Franck Nijhof
0280862780 Migrate api tests from coroutine to async/await (#30338) 2019-12-31 22:58:40 +01:00
Franck Nijhof
687a052d40 Migrate python_script tests from coroutine to async/await (#30335) 2019-12-31 22:48:43 +01:00
springstan
f11d39f8eb Bump alarmdecoder to 1.13.9 (#30303) 2019-12-31 15:54:31 -05:00
Franck Nijhof
d8d75d882b Bump pyps4-2ndscreen to 1.0.4 (#30327) 2019-12-31 15:52:45 -05:00
Franck Nijhof
cd8f954a4d Migrate wunderground tests from coroutine to async/await (#30330) 2019-12-31 21:04:24 +01:00
Franck Nijhof
30dbed3f98 Migrate dsmr tests from coroutine to async/await (#30333) 2019-12-31 21:03:21 +01:00
Franck Nijhof
2620a95944 Improve Withings tests in different time zone (#30326)
* Improve Withings tests in different time zone

* Address code review comment

* Spelling error in code doc
2019-12-31 11:10:39 -05:00
Alexei Chetroi
a3061bda60 Make the rest of ZHA platforms to use ZHA class registry (#30261)
* Refactor ZHA component tests fixtures.

* Add tests for ZHA device discovery.

* Refactor ZHA registry MatchRule.

Allow callables as a matching criteria.
Allow sets for model & manufacturer.

* Minor ZHA class registry refactoring.

Less cluttered strict_matching registrations.

* Add entities only if there are any.

* Migrate rest of ZHA platforms to ZHA registry.

* Pylint fixes.
2019-12-31 11:09:58 -05:00
Alan Tse
5ed44297e6 Simplify Tesla icon get code (#30301)
* Simplify icon get code

* Remove extraneous None
2019-12-31 16:27:39 +01:00
Lars-P
4031596aa7 Fix luftdaten integration by adding a sensor for pressure at sealevel (#30317) 2019-12-31 15:58:54 +01:00
brefra
3c8ebf1844 Add light support to Velbus integration (#30323)
* Add light support to Velbus integration

* Add Velbus light.py to .coveragerc

* Applied black formatting
2019-12-31 15:46:02 +01:00
Fabian Affolter
734ef5a7a9 Upgrade Sphinx to 2.3.1 (#30310) 2019-12-31 15:32:26 +01:00
Iulius
1c2618d99a Add separate command and state topics for mqtt lock (#29808)
* Update lock.py

Allow different command and state topic + different command and state values.

* Formatting updated after black run

* TC updated to reflect different state & cmd values

* Abbreviations for lock states added

* additional non-default state test

* whitespaces fixed

* black formatting run
2019-12-31 15:24:09 +01:00
Christian
fd0375ac20 Add support for Velux garage doors (#30214)
* Update manifest.json

* Update cover.py

Add GarageDoor

* Update to pyvlx 0.2.12

* Sort
2019-12-31 15:17:17 +01:00
Phil Bruckner
609bf445f0 Remove Amcrest deprecated sensors and switches (#30308) 2019-12-31 08:16:41 -06:00
Shawn Wilsher
e68cd339b9 Reduce solaredge logging severity (#30305)
* [solaredge] Reduce Severity of Log Line

This log error happens frequently for some sites, but it shouldn't be an error.
It is expected, per the SolarEdge Monitoring API, that some sites do not
support this information, and the expected result is that this would be
empty (see comments on #27959).

Fixes #27959

* Fix a typo

Co-authored-by: Fabian Affolter <mail@fabian-affolter.ch>
2019-12-31 08:56:23 -05:00
rhadamantys
dedd1aec8c Add support for Somfy RTS power socket and Somfy io Temperature sensor (#30053)
* Added support for Somfy RTS wireless power socket and
Somfy Temperature Sensore Thermos Wirefree io

* Added code formatting fixes for commit 5faaf9c

* added support for RollerShutterRTSComponent from Somfy

* Added support for RTS roller shutter in set_cover_position

* Add support for Somfy RTS power socket and Somfy io temperature sensor

* black and isort fixes
2019-12-31 14:48:31 +01:00
SukramJ
b0a0871bed Bump dependency for HomematicIP Cloud (#30319) 2019-12-31 14:45:17 +01:00
Steven Barth
4bfc7b9848 Add homematic host port config for HMIP-only CCUs (#30077)
* homematic: Add host port config for HMIP-only CCUs

When adding a host (CCU) to the homematic component currently the hardcoded port 2001 is used to communicate with it.
However that port is only available on the target if the target supports HM (wireless) protocol which is not the case e.g. for
the Hass.io Homematic CCU addon when running in HMIP-only mode with the HMIP-RFUSB stick.

This allows to change the port home assistant uses to talk to the CCU in order to provide services under hte homematic homain, e.g. homematic.set_variable_value

The default value for this option is the old hardcoded value this the change should be backwards compatible with existing configurations.

* Change style of config retrieval
2019-12-31 08:41:44 -05:00
Philipp Schmitt
72e97792bd Update liveboxplay and pyteleloisirs (#30093) 2019-12-31 08:38:46 -05:00
Issac
3f570245aa Add local_ip component (#29973)
* Added localip component

* Split config and core logic, and migrate to sensor platform (requested by @MartinHjelmare)
Also allow overriding the sensor name via the config

* Tweak docstring

Co-Authored-By: Fabian Affolter <mail@fabian-affolter.ch>

* Initial support for config entries

* Rename localip to local_ip (1/2)

* Rename localip to local_ip (2/2)

* Add test for config_flow

* Split and rename tests

* Remove unneeded code from config_flow

* Implement configuration as config entry import.  Other misc requested changes from code review.

* Fix tests

* minor code review fixes

* remove unneeded code

Co-authored-by: Fabian Affolter <mail@fabian-affolter.ch>
2019-12-31 14:34:53 +01:00
Franck Nijhof
5414e9d155 Fix Withings leaking time zone change into other tests (#30320)
* Fix Withings leaking time zone change in other tests

* Fix spelling error in code doc
2019-12-31 14:30:09 +01:00
Paulus Schoutsen
bb14a083f0 Store capabilities and supported features in entity registry, restore registered entities on startup (#30094)
* Store capabilities and supported features in entity registry

* Restore states at startup

* Restore non-disabled entities on HA start

* Fix test

* Pass device class from entity platform

* Clean up restored entities from state machine

* Fix Z-Wave test?
2019-12-31 14:29:43 +01:00
Maciej Bieniek
2c1a7a54cd Add GIOS integration (#28719)
* Initial commit

* Add gios to requirements

* Add tests

* Update .coveragerc file

* Run gen_requirements_all.py

* Change DEFAULT_SCAN_INTERVAL

* Better strings

* Bump library version

* run script.hassfest

* run isort

* Add icons mapping

* Remove unnecessary f-string

* Remove unnecessary listener

* Refactoring config_flow

* Add unique_id to config entry

* Change AQI states to consts in English

* Remove unused init

* Remove unused exception

* Remove private instance attribute

* Remove overwrite state property

* Fix pylint error

* Add SCAN_INTERVAL for air_quality entity

* Add _abort_if_unique_id_configured()
2019-12-31 13:05:31 +01:00
Phil Bruckner
1ee299b079 Ignore google_maps updates when last_seen goes backwards (#30178) 2019-12-30 19:30:45 -06:00
HomeAssistant Azure
ae51331d49 [ci skip] Translation update 2019-12-31 00:32:20 +00:00
Andrew Sayre
914aea9446 Bump pysmartthings 0.7.0 (#30302) 2019-12-30 14:49:56 -06:00
Robert Svensson
41d2d1f309 Handle wired bug on restart (#30276) 2019-12-30 12:40:52 -06:00
Tais Hedegaard Holland
bad35577cb Bump ihcsdk to 2.4.0 (#30279)
* Update requirements_all.txt

update ihcsdk to version 2.4.0

* Update manifest.json

upgrade to version 2.4.0 of ihcsdk
2019-12-30 12:38:17 -06:00
Andy Grunwald
3b9f48b51d Contributing: Add note about feature suggestions and bug tracking (#30225) 2019-12-30 17:54:16 +01:00
Alan Tse
40e3d6f773 Change default icons for Tesla components (#30288) 2019-12-30 17:52:34 +01:00
Fabian Affolter
d0c9a42b81 Add custom validator for countries (#30280) 2019-12-30 17:51:25 +01:00
Fabian Affolter
33738cc83a Upgrade beautifulsoup4 to 4.8.2 (#30274) 2019-12-30 17:51:11 +01:00
Jc2k
fccb13b762 Add homekit_controller service.sensor.smoke (#30269) 2019-12-30 08:05:49 +00:00
Jc2k
8a22a38353 Accept homekit_controller pairing codes both with and without dashes (#30273)
* Handle MalformedPinError from homekit_python
* Handle both formats of pin codes
2019-12-30 07:36:01 +00:00
HomeAssistant Azure
13116d8d3f [ci skip] Translation update 2019-12-30 00:32:19 +00:00
Ville Skyttä
9892564ab5 Upgrade rflink to 0.0.50, ignore_devices now supports * and ? anywhere (#30268)
https://github.com/aequitas/python-rflink/releases/tag/0.0.50
https://github.com/aequitas/python-rflink/releases/tag/0.0.49
https://github.com/aequitas/python-rflink/releases/tag/0.0.48
https://github.com/aequitas/python-rflink/releases/tag/0.0.47
2019-12-29 21:12:49 +02:00
François
85624e8031 Fix creating smappee sensors when remote is not active (#30270) 2019-12-29 17:18:23 +01:00
LE LAY Olivier
a91b005822 Fix ble_tracker randomly pygatt thrown error (#28671)
* fix(ble_tracker): catch randomly pygatt thrown error

* fix(ble_tracker): merge except errors
2019-12-29 09:26:43 +02:00
HomeAssistant Azure
5d8dda4f68 [ci skip] Translation update 2019-12-29 00:32:14 +00:00
Pascal Vizeli
79b47157b8 Merge pull request #30260 from home-assistant/rc
0.103.5
2019-12-28 22:16:11 +01:00
Alexei Chetroi
36585558a5 Refactor ZHA channel logging (#30259)
Add channel.id property -- id unique for this the device only.
2019-12-28 15:41:55 -05:00
Pascal Vizeli
ae42736235 Bump version 0.103.5 2019-12-28 20:26:06 +00:00
Robert Van Gorkom
08af989658 Fixing timezone issue which caused wrong selection of data to be used. (#30011) 2019-12-28 21:25:37 +01:00
Marcelo Moreira de Mello
fdd090bae0 Bump ring to 0.2.8 to fix Oauth issues (#30245) 2019-12-28 20:24:29 +00:00
Paulus Schoutsen
5a9e543087 Whitelist Android/iOS auth callbacks (#30082)
* Whitelist Android/iOS

* Add iOS alternate flavor URLs

* Update indieauth.py

Co-authored-by: Robbie Trencheny <me@robbiet.us>
2019-12-28 21:20:18 +01:00
Maikel Punie
e1e8d6a562 Bump python-velbus library to 2.0.32 to fix problems with the glaspanels (#30257) 2019-12-28 21:16:52 +01:00
Ville Skyttä
4e50a402c7 Note Huawei LTE notify service change requires restart (#30223)
Refs https://github.com/home-assistant/home-assistant/issues/30222
2019-12-28 16:31:42 +01:00
SukramJ
658ec309aa Add HmIP-MOD_TM to HomematicIP Cloud (#30255) 2019-12-28 16:29:14 +01:00
Ville Skyttä
c5a280c064 Huawei LTE: Fix YAML options overriding ones set from GUI (#30249)
Closes https://github.com/home-assistant/home-assistant/issues/30221
2019-12-28 16:27:49 +01:00
Felix Barbalet
0323b246bd Bump libpurecool to 0.6.0 (#30247)
* bump libpurecool to 0.6.0 - fixes home-assistant/home-assistant#26367

* update manifest too
2019-12-28 16:19:18 +01:00
SukramJ
134dc45b77 Bump dependency for HomematicIp cloud (#30237)
* Bump dependency for HomematicIp cloud

* Update test_data
2019-12-28 13:46:04 +01:00
Ville Skyttä
e4cda9ae0b Fix Huawei LTE error message on service call without URL and routers (#30250) 2019-12-28 12:55:45 +01:00
Marcelo Moreira de Mello
59fee12b45 Bump ring to 0.2.8 to fix Oauth issues (#30245) 2019-12-28 10:15:35 +01:00
springstan
cf7b70dd8c Bump python-qbittorrent to 0.4.1 (#30239) 2019-12-28 10:09:42 +01:00
HomeAssistant Azure
2e07902999 [ci skip] Translation update 2019-12-28 00:32:22 +00:00
Kerwood
9d6f3654ad DECONZ - Added support for Aqara single switch WXKG03LM (#30240) 2019-12-27 21:47:45 +01:00
Franck Nijhof
9159da6583 Bump shodan to 1.21.1 (#30234) 2019-12-27 20:35:25 +01:00
HomeAssistant Azure
39d38923b7 [ci skip] Translation update 2019-12-27 00:32:13 +00:00
David F. Mulcahey
05a0922dc0 Bump ZHA dependencies (#30228)
* bump dependencies
* requirement files
* bump quirks to 0.0.30
2019-12-26 17:08:14 -05:00
Josh Bendavid
d6744fbc4e Fix handling of symlinked device descriptors in keyboard_remote and move remaining sync io to executor thread pool (#30206)
* fix handling of symlinked device decriptors

* make check for symlinked paths more efficient

* make variable names pylint compliant

* move sync io during setup and device connect/disconnect to executor thread pool

* move remaining sync io during setup to executor thread pool

* remove unnecessary lambda functions
2019-12-26 19:06:57 +01:00
Paul Annekov
b2753b7578 bump tuyaha 0.0.5 (#30213) 2019-12-26 13:27:59 +01:00
Alan Tse
e58ef36adc Bump teslajsonpy to 0.2.1 (#30217)
Closes #29922
2019-12-26 13:25:49 +01:00
HomeAssistant Azure
169c4089ff [ci skip] Translation update 2019-12-26 00:32:16 +00:00
Ville Skyttä
50a87bbe18 Add Huawei LTE integration suspend and resume services (#30207)
Useful e.g. if accessing the router web interface from another source
such as a web browser is temporarily required.
2019-12-25 12:43:51 +01:00
Ville Skyttä
a5c4508571 Make Huawei LTE notify service name configurable (#30208)
* Default Huawei LTE notify service name to notify.huawei_lte, make configurable

Closes https://github.com/home-assistant/home-assistant/issues/29409

* Set default notify service name for uninvoked options flow
2019-12-25 13:42:28 +02:00
Kevin McCormack
f56797e413 Update Vivotek camera component (#30191)
- Bump libpyvivotek version to 0.4.0
- Add digest authentication
2019-12-25 11:45:49 +01:00
rhadamantys
89450f405c Add support for enocean window handle FA 10 00 (Hoppe) (#29968)
* Added support for Somfy RTS wireless power socket and
Somfy Temperature Sensore Thermos Wirefree io

* Added code formatting fixes for commit 5faaf9c

* added support for RollerShutterRTSComponent from Somfy

* Added support for RTS roller shutter in set_cover_position

* added support for enocean window handle FA 10 00 (Hoppe)

* removed spaces in empty lines

* removal of rawdata attribute / code style

* isort fix

* PyLint fixes

* Improvements after review suggestions: rename device class to sensor type to avoid ambiguousness

* added import for DEVICE_CLASS_POWER from const.py

* removed window handle unit
2019-12-25 11:41:00 +01:00
Niall Donegan
5e3102b2d6 Pull track position from MPD status (#28579)
* Pull track position from MPD status()

This allows the progress bar to work when using the media-control card in lovelace.

* Actually commit flake8 fix!

* Extra documentation.

Mainly to trigger CI rerun.

* Updated to use self._media_position
2019-12-25 11:09:03 +01:00
Josef Schlehofer
217b974cef Upgrade youtube_dl to 2019.12.25 (#30203) 2019-12-25 10:18:10 +01:00
HomeAssistant Azure
bb35d93fde [ci skip] Translation update 2019-12-25 00:32:06 +00:00
ochlocracy
25f78dd1a9 Implement EqualizerController in Alexa for media_player. (#30159) 2019-12-24 17:06:39 -05:00
springstan
4ea42c2479 Bump datapoint to 0.9.5 (#30185) 2019-12-24 12:00:32 -07:00
springstan
482ff4061e Bump importlib-metadata to 1.3.0 (#30196)
* Bump importlib-metadata to 1.3.0

* Include setup.py and package_constraints.txt
2019-12-24 12:00:05 -07:00
Tim Rightnour
f32eaa2fdd Add onewire devices and owserver remote host support (#29948)
* Add support for HobbyBoards sensors: Hub, Humidity, Moisture, PulseCounter
Add support for an owserver running on a remote host

* Cleanup and fixes for style/etc

* Forgot to convert to f-strings.

* Update with changes requested by @MartinHjelmare

* Pylint

* Fix to None

* Reverse logic for hobbyboard test to eliminate pylint complaint

* Modified manifest to list myself as codeowner

* Move some functions down into OneWireProxy instead of the top OneWire

* Oops, missed some decode()'s

* And another!
2019-12-24 14:41:29 +01:00
Quentame
2113d65c06 Fix AdGuard Home safe search sensor name (#30171)
* Fix AdGuard Home safe search sensor name

* Fix typo
2019-12-24 14:14:58 +01:00
Fabian Affolter
783672d305 Upgrade zeroconf to 0.24.3 (#30187) 2019-12-24 14:11:01 +01:00
HomeAssistant Azure
8add6c5f2e [ci skip] Translation update 2019-12-24 00:32:12 +00:00
David F. Mulcahey
85d2ba047b Protect against bad data stored in ZHA (#30183) 2019-12-23 19:11:35 -05:00
Alan Tse
3aa2ae1700 Enable config flow for Tesla (#28744)
* build: bump teslajsonpy to 0.2.0

* Remove tests

* feat: add config flow

* feat: add async

* perf: convert unnecessary async calls to sync

* feat: add charger voltage and current sensor

* feat: add options flow

* build: bump teslajsonpy to 0.2.0

* Remove icon property

* Revert climate mode change

* Remove charger sensor

* Simplify async_setup_platform

* Update homeassistant/components/tesla/sensor.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Update homeassistant/components/tesla/binary_sensor.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Address requested changes

* Fix pylint error

* Address requested changes

* Update codeowners

* Fix pylint error

* Address requested changes

* Address requested change

* Remove unnecessary check for existing config entry

* Load scan_interval in async_setup_entry

* Include coverage of config_flow

* Add tests for full coverage

* Address requested test changes

* Remove unnecessary init lines

* Remove unnecessary init

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2019-12-23 21:54:25 +01:00
Claudio Heckler
edce497a0d New date_time_utc display option added to the time_date sensor platform (#30158) 2019-12-23 21:48:24 +01:00
P-Verbrugge
059e8722b6 Updated formatting of total_blocks value (#30170)
The number of total blocks is always a round number. There can't be .1 or .11 blocks for example. The output is now always formatted with two decimals that are always 00.
2019-12-23 21:42:44 +01:00
Greg
f23cc16660 Upgrade envoy_reader to 0.11.0 (#30179) 2019-12-23 21:35:54 +01:00
Quentame
f72ba0c716 Add icons to Freebox sensors (#30132) 2019-12-23 09:37:41 -07:00
springstan
4c5801ee8c Add cast to state of Dyson Air Quality Sensor (#30100) 2019-12-23 09:34:57 -07:00
Quentame
e3a3964911 Add icon to Plex sensor (#30172) 2019-12-23 09:25:57 -07:00
ochlocracy
a2678b2aff Add support for input_number entities in Alexa integration (#30139)
* Add support for input_number entities

* Update homeassistant/components/alexa/capabilities.py

Co-Authored-By: Paulus Schoutsen <paulus@home-assistant.io>

* Removed get methods to directly access required attributes dicts.

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2019-12-23 15:17:37 +01:00
Paulus Schoutsen
7f2921b0e6 Merge remote-tracking branch 'origin/master' into merge-master 2019-12-22 23:42:46 +01:00
Paulus Schoutsen
48d35a4550 Merge pull request #30154 from home-assistant/rc
0.103.4
2019-12-22 23:41:22 +01:00
Robert Svensson
31b17e2b95 Allow battery value of 0 as well as make sure to not create a battery tracker if one already exist (#30155) 2019-12-22 22:58:36 +01:00
Robert Svensson
e9dc404de1 Allow battery value of 0 as well as make sure to not create a battery tracker if one already exist (#30155) 2019-12-22 22:58:22 +01:00
Paulus Schoutsen
720d63f496 Bumped version to 0.103.4 2019-12-22 22:34:57 +01:00
Franck Nijhof
e9b19e0465 Fix deconz SSDP updating Hassio discovery (#30153) 2019-12-22 22:34:14 +01:00
springstan
e74c4c5d99 Move imports into setup function in homekit __init__.py (#30137) 2019-12-22 22:25:27 +01:00
Paulus Schoutsen
697833bc91 Remove requirement from entity integration (#30113) 2019-12-22 22:25:03 +01:00
Franck Nijhof
d101d4449f Fix deconz SSDP updating Hassio discovery (#30153) 2019-12-22 22:24:18 +01:00
Alexei Chetroi
fdaaabf070 ZHA binary_sensor cleanup. (#30149) 2019-12-22 14:07:49 -05:00
cgtobi
d4ff214fce Clean up scaffold (#30135) 2019-12-22 19:53:03 +01:00
Franck Nijhof
b1bb2298e0 Bump sqlalchemy to 1.3.12 (#30142) 2019-12-22 19:52:39 +01:00
Ville Skyttä
868eb3c735 More helpers type improvements (#30145) 2019-12-22 19:51:39 +01:00
Philipp Danner
70f8bfbd4f Update Integration of Keba charging station (#30125)
* fixed parsing of current to float in service set_current

* Added optional name in the config file in order to get a better entety naming (easier to find)

* fix parsing of all parameters to service calls

* addressed code review comments + updated pypi dependency

* config name imported from cont.py + minor naming changes to be more clear about the meaning of a sensor

* removed name in config again, use product name gathered from the charging station instead

* implemented suggested changes

* changed variable naming as requested
2019-12-22 19:46:53 +01:00
Alexei Chetroi
83768be814 Refactor ZHA binary_sensor (#30138)
* Refactor ZHA binary_sensor.

Use ZHA entity class registry for channel specific implementations.

* Remove registries.BINARY_SENSOR_TYPES dict.

* Address PR comments.
2019-12-22 13:24:57 -05:00
Fabian Affolter
ed0ee3100d Upgrade zeroconf to 0.24.2 (#30140) 2019-12-22 12:01:22 +01:00
Paulus Schoutsen
32aae7017e Remove requirement from entity integration (#30113) 2019-12-22 10:32:42 +01:00
Paulus Schoutsen
63a843c19c Fix test 2019-12-22 10:31:23 +01:00
springstan
251808874f Move imports into setup function in homekit __init__.py (#30137) 2019-12-22 10:23:44 +01:00
Alexei Chetroi
9c23c4adf2 Cleanup ZHAEntity class (#30131)
Remove `_domain` attribute since we're not using it anymore.
2019-12-21 18:33:00 -05:00
Alexei Chetroi
8e3dfbd5c9 Refactor ZHA electrical measurement sensor. (#30130) 2019-12-21 17:15:50 -05:00
Paulus Schoutsen
834929a14e Clean up mobile app webhooks (#30123) 2019-12-21 22:45:06 +01:00
Alexei Chetroi
fb3bb8220b Implement ZHA entity classes registry (#30108)
* ZHA Entity registry.
Match a zha_device and channels to a ZHA entity.

* Refactor ZHA sensor to use registry.
* Remove sensor_types registry.
* Fix ZHA device tracker battery remaining.
* Remove should_poll/force_update attributes.
* Fix binary_sensor regression.
* isort.
* Pylint.
* Don't access protected members.
* Address comments and fix spelling.
* Make pylint happy again.
2019-12-21 16:26:58 -05:00
Jc2k
b41480ae46 Add a config entry mechanism to rediscover a discovery that was ignored (#30099)
* Mechanism to rediscover a discovery that was ignored

* Add core config entry tests for new rediscover step

* Add tests for homekit_controller implementation of async_step_rediscover

* Rename rediscover to unignore

* Comment the new ignore/unignore mechanisms
2019-12-21 11:22:07 +01:00
Maikel Punie
3911f24f75 Upgrade python-velbus (#30110) 2019-12-21 11:20:31 +01:00
Vladimír Záhradník
0fc92928a4 Add device class attribute to modbus sensors (#30030) 2019-12-21 10:54:48 +01:00
Ville Skyttä
6604680793 Helpers type hint improvements (#30106) 2019-12-21 09:23:48 +02:00
Ville Skyttä
ecdc1adf90 Upgrade mypy to 0.761 (#30104)
https://mypy-lang.blogspot.com/2019/12/mypy-0760-released.html
https://github.com/python/mypy/releases/tag/v0.761
2019-12-20 22:35:02 +01:00
Bas Nijholt
de94afd090 add --show-diff-on-failure to pre-commit (#30097)
This makes the traceback on a failing CI pipeline much more useful.
2019-12-20 22:00:31 +01:00
Jc2k
4ef04840e9 Don't error on removal of an ignored homekit_controller config entry (#30083)
* Don't error on ignored entries

* Don't ever call async_remove_entry or async_unload_entry for an unignored ignore config entry
2019-12-20 21:49:07 +01:00
Paulus Schoutsen
3e7699b886 Merge pull request #30096 from home-assistant/rc
0.103.3
2019-12-20 21:28:49 +01:00
Paulus Schoutsen
d448ed9f6d Bump ring to 0.2.5 (#30103) 2019-12-20 20:44:46 +01:00
springstan
f229cf2796 Bump starlingbank to 3.2 (#30098) 2019-12-20 20:44:46 +01:00
Paulus Schoutsen
b3098c9f2c Bump ring to 0.2.5 (#30103) 2019-12-20 20:42:13 +01:00
springstan
27f35f86ad Bump starlingbank to 3.2 (#30098) 2019-12-20 20:29:12 +01:00
ochlocracy
0faca57e8b Explicitly include Alexa interface for image_processing entities. (#30101) 2019-12-20 20:28:23 +01:00
gppanayotov
84e1b3d07f Add an open window sensor for heating zones (#30090) 2019-12-20 19:02:46 +01:00
Pascal Vizeli
5def51835e Fix v2 2019-12-20 17:10:04 +00:00
Pascal Vizeli
12f1a322a7 Fix test 2019-12-20 16:20:10 +00:00
Fazli Sapuan
488f26d55b Fix homekit handling of 0 light brightness and fan speed (#29962)
* Fix homekit handling of 0 light brightness and fan speed

* Update homekit tests for new initial brightness/speed value
2019-12-20 16:08:08 +00:00
Wim Haanstra
20a0557be7 Fix failure in transform method (#30023)
* Fix failure in transform method

* Fix formatting issue
2019-12-20 16:07:07 +00:00
omriasta
e58291015c Patch rachio (#30031)
* fix binary sensor offline/online

fixed self._handle_update on line 66 to produce args, kwargs.
Updated the binary sensor to check the correct index in the tuple.

* Fixed Standby switch

Set standby switch to poll in order to get status when homeassistant starts up.
Updated the index for the switch to get the status from the tuple.
2019-12-20 16:05:28 +00:00
Pascal Vizeli
e6a27983d3 Bump version 0.103.3 2019-12-20 14:16:39 +00:00
Franck Nijhof
939ca63cbc Fix update port and api key on deconz discovery config entry u… (#30088)
* Fix update port and api key on discovery config entry update

* Remove coroutine from _update_entry
2019-12-20 14:15:45 +00:00
Michaël Arnauts
04b5d6c697 Rework tado component (#29246)
* Fix imports so it works in custom_components

* Rework tado component

* Code cleanup

* Remove water_heater

* Address pylint warnings

* Remove water_heater from components

* Raise PlatformNotReady when we couldn't connect

* Revert PlatformNotReady since we are not a platform

* Add debugging information

* Add fallback setting

* Import with relative path

* Address race condition

* Cleanup

* Catch 422 Errors and log the real error

* Use async_schedule_update_ha_state to update the entities

* Forgot the True
2019-12-20 13:24:43 +01:00
Fazli Sapuan
92fd3e3ad5 Fix homekit handling of 0 light brightness and fan speed (#29962)
* Fix homekit handling of 0 light brightness and fan speed

* Update homekit tests for new initial brightness/speed value
2019-12-20 11:00:21 +01:00
Franck Nijhof
eb0aed3653 Fix update port and api key on deconz discovery config entry u… (#30088)
* Fix update port and api key on discovery config entry update

* Remove coroutine from _update_entry
2019-12-20 10:29:18 +01:00
HomeAssistant Azure
3a610edb78 [ci skip] Translation update 2019-12-20 00:32:22 +00:00
Ville Skyttä
d236a19139 Include all SSDP data in discovery info (#28197)
* Include all SSDP data in discovery info

* Use UPnP device description as discovery info, inject some SSDP attrs

* Clean up attribute names

* Adapt existing SSDP flows to changed attribute names

* Prefix all SSDP UPnP attribute name constants with ATTR_UPNP, tweak a bit
2019-12-19 19:28:03 +02:00
springstan
0cb468d7b0 Make name of nmbs live sensor customizable via unique_id (#29662)
* Make name customizable for nmbs live sensors

* Change order of the live name

* Added unique id to live nmbs sensor

* Revert changing the name of the live sensor
2019-12-19 17:45:52 +01:00
Maciej Bieniek
80be3b74a9 Init entities as unavailable when offline (#29738) 2019-12-19 14:10:27 +01:00
Paulus Schoutsen
52818bdb89 Make Hassfest stricter pt 2 (#30068)
* Make Hassfest stricter

* Fix if-condition

* Small cleanup
2019-12-19 14:00:22 +01:00
ochlocracy
5baaa852dd Refactor Alexa capabilityResources object into class, Implement Alexa semantics object (#29917)
* Refactor capabilityResources object into class.
Implement semantics object to support open, close, raise, lower utterences.
Replace covers PercentageController with RangeController.
Add semantics for covers.
Remove PowerController for covers.
Add new display categories.
Add new items to Alexa Global Catalog.
Implement garage door voice PIN code support though Alexa app.
Fixed bug with getting property for ModeController.
Fixed bug were PercentageController AdjustPercentage would exceed 100.

* Comment fixes in Tests.

* Reorder imports.

* Added additional tests for more code coverage.

* Added and additional test for more code coverage.

* Explicitly return None for configuration() if not instance of AlexaCapabilityResource.
2019-12-19 12:44:17 +01:00
Yuchen Ying
9804fbb527 Add unit_of_measurement to various Transmission sensors (#30037)
* Add unit_of_measurement to various Transmission sensors 

Without unit_of_measurement, the history graph card will not show those sensors as line chart.

* Change Counts to Torrents.
2019-12-19 11:23:46 +01:00
Paulus Schoutsen
e0d6810134 Remove stream from camera after deps (#30057) 2019-12-19 11:23:19 +01:00
Jc2k
c3144eddbb Set unique id on homekit_controller config entries (#30035)
* Set unique id on config entries

* Changes from review
2019-12-19 09:45:22 +01:00
Paulus Schoutsen
50714fbedf Merge pull request #30064 from home-assistant/rc
0.103.2
2019-12-19 08:03:47 +01:00
Paulus Schoutsen
c9de5b9fef Bumped version to 0.103.2 2019-12-19 07:53:38 +01:00
Paulus Schoutsen
aae80dca1c Fix recursion 2019-12-19 07:53:32 +01:00
Aaron Bach
9e5de1a106 Guard against future unknown SimpliSafe entity types (#30059)
* Guard against future unknown SimpliSafe entity types

* Updated log message
2019-12-18 17:52:56 -07:00
HomeAssistant Azure
5ea4ba6a2e [ci skip] Translation update 2019-12-19 00:32:16 +00:00
Paulus Schoutsen
f5c7d23b0f Merge remote-tracking branch 'origin/master' into dev 2019-12-18 22:18:35 +01:00
Wim Haanstra
36f7096f09 Fix failure in transform method (#30023)
* Fix failure in transform method

* Fix formatting issue
2019-12-18 13:18:14 -07:00
Alexei Chetroi
41bef4b919 Add timer reload service. (#30015) 2019-12-18 21:15:11 +01:00
Aaron Bach
0adb88156d Bump simplisafe-python to 5.3.6 (#30055) 2019-12-18 21:06:57 +01:00
omriasta
bdef54de0c Patch rachio (#30031)
* fix binary sensor offline/online

fixed self._handle_update on line 66 to produce args, kwargs.
Updated the binary sensor to check the correct index in the tuple.

* Fixed Standby switch

Set standby switch to poll in order to get status when homeassistant starts up.
Updated the index for the switch to get the status from the tuple.
2019-12-18 21:04:54 +01:00
Erik Kastelec
d16011b849 changed Venstar component temperature to half degree accuracy (#30034) 2019-12-18 08:47:01 -05:00
Paulus Schoutsen
9c7caaa142 Add option to ignore flows (#30008) 2019-12-18 07:41:01 +01:00
Greg
feb39c39a3 Update Envoy sensor to configure credentials and grab Inverter Date from updated API (#28837)
* Update manifest.json

Updated sensor to use the latest version of the API to be able to use the new features.

* Updated sensor to use new API features.  Configurable credentials and Inverter last reported date.

* EnvoyReader is passed to Envoy uses async update()

* Fixed pydocstyle warnings

* Fixed merge issue. Had extra variable.

* Added warning message when authentication for Inverter data fails

* Added continue after exception for loop

* Moved if statement outside of try/except

* Removed unneeded boolean attribute
2019-12-18 01:51:19 +01:00
HomeAssistant Azure
0135b988ff [ci skip] Translation update 2019-12-18 00:32:19 +00:00
Fabian Affolter
876195a8a8 Upgrade zeroconf to 0.24.1 (#30028) 2019-12-17 17:00:00 +01:00
Fabian Affolter
31cd0af47a Upgrade matrix-client to 0.3.2 (#30027) 2019-12-17 16:26:36 +01:00
Andre Richter
115aa2e49c Z-Wave: Fibaro FGR*-222: Add venetian blind support (#29701)
The Fibaro FGR-222/FGRM-2222 ZWave roller shutter devices have a proprietary
command class to support setting the tilt angle of venetian blinds (= type of
window cover). This PR adds the support to HA for this. This allows the user to
set the height of the blinds and the tilt angle separately.

Original patch by @ChristianKuehnel #24405.
2019-12-17 09:26:19 -05:00
Robert Van Gorkom
78e831b08e Make tplink light more responsive (#28652)
* Making tplink light more responsive.

* Adding light platform tests.

* Addressing PR feedback.

* Mocking the module, not the api.

* Using sync method for background update.
2019-12-17 02:24:50 +01:00
HomeAssistant Azure
ad8278c078 [ci skip] Translation update 2019-12-17 00:32:23 +00:00
Franck Nijhof
0439d6964c Fix persistent setup error notification content (#29995)
* Fix persistent setup error notification content

* Use documentation from manifest, enriched error messages

* Fix issue caught by mypy
2019-12-16 20:16:23 +01:00
Vladimír Záhradník
c16fae2c0b Fix modbus service description (#30005) 2019-12-16 20:07:46 +01:00
Paulus Schoutsen
58b5833d64 Convert Hue to use unique ID (#30000)
* Convert Hue to use unique ID

* Fix normalization

* Store/restore unique ID

* Fix tests
2019-12-16 19:45:09 +01:00
zewelor
575eb48feb Show current effect in yeelight device (#28975)
* Show current effect in yeelight device

* Use device_state_attributes instead of state_attributes

* Add early return in set effect

* Make single if elif chain

* Fix if elif

* Fix if elif
2019-12-16 16:23:05 +01:00
Paulus Schoutsen
d851cb6f9e Add unique ID to config entries (#29806)
* Add unique ID to config entries

* Unload existing entries with same unique ID if flow with unique ID is
finished

* Remove unused exception

* Fix typing

* silence pylint

* Fix tests

* Add unique ID to Hue

* Address typing comment

* Tweaks to comments

* lint
2019-12-16 12:27:43 +01:00
Franck Nijhof
87ca61ddd7 Add check-json to CI and Pre-commit (#29912)
* Add check-json to CI and Pre-commit

* Add ignore pre-commit hooks to gen_requirements_all
2019-12-16 11:06:16 +01:00
Franck Nijhof
d1e59b20c8 Bump pytest to 5.3.2 (#29990) 2019-12-16 10:59:32 +01:00
Franck Nijhof
dd0f0034f3 Bump shodan to 1.21.0 (#29991) 2019-12-16 10:57:42 +01:00
Emacee
be042f3d91 Update binary_sensor.py (#29977)
Change sensor type for central locking from safety into lock.
2019-12-16 09:42:48 +01:00
Louis-Dominique Dubeau
33cbb398ad Don't use the locals parameter on exec. (#29979)
Using the locals parameter makes it so that the code of a Python script runs as
if it were in the body of a ``class``. One effect of this is that functions
defined as part of a script cannot call one another directly.

Fixes: #24704, #13653
2019-12-16 09:39:20 +01:00
Paulus Schoutsen
b058742404 Fix condition typo (#29989) 2019-12-16 09:33:11 +01:00
Ryan
3f32490ae6 Fixed "condtion_type" to "condition_type" (#29984)
Fixed "condtion_type" to "condition_type"
2019-12-16 08:41:32 +01:00
Paulus Schoutsen
9e51a18845 Make hassfest import detection better (#29932)
* Make hassfest import detection better

* Fix tests
2019-12-16 08:22:20 +01:00
Jeff Irion
8fe17c0933 Remove 'SUPPORT_PLAY_MEDIA' from Volumio (#29969) 2019-12-16 08:21:29 +01:00
Kevin Eifinger
fc01da8933 Migrate to api_key (#29966) 2019-12-16 08:20:41 +01:00
Joakim Plate
039cc98278 Support case of unknown/unavailable temperature/humidity (#29959)
* Support case of unknown/unavailable temperature/humidity

State is never None, just a string.

* Lint suggestion
2019-12-16 08:04:59 +01:00
Ville Skyttä
445fd15f76 Drop Python 3.6 support (#29978) 2019-12-16 07:29:19 +01:00
Andrew Onyshchuk
bfafa77016 Fix support for legacy Z-Wave thermostats (#29955)
This brings back support for Z-Wave thermostats
of SETPOINT_THERMOSTAT specific device class.
Such devices don't have COMMAND_CLASS_THERMOSTAT_MODE
and are now handled separately.
2019-12-15 20:02:18 -05:00
HomeAssistant Azure
95a6a7502a [ci skip] Translation update 2019-12-16 00:32:25 +00:00
Ville Skyttä
d6f317c0a9 Remove deprecated rflink configs (#29972)
They've been deprecated and automatically replaced since July 2017
already, fe6a4b8ae5
2019-12-15 22:57:23 +02:00
Aaron Godfrey
012c09ce00 Fix example value for Todoist service (#29953) 2019-12-15 18:47:11 +01:00
Fabian Affolter
9c0799eb0a Upgrade keyring to 20.0.0 and keyrings.alt to 3.4.0 (#29960) 2019-12-15 17:41:56 +01:00
Chris Caron
09f3362cc6 isort fix on test_media_player (#29965) 2019-12-15 16:07:57 +01:00
Joakim Plate
84a7115435 Start of using hass state for tests rather than direct object (#29377) 2019-12-15 13:14:50 +01:00
Jeff Irion
8a5bce81c8 Bump adb-shell to 0.1.0 and androidtv to 0.0.36 (#29938)
* Bump adb-shell to 0.1.0 and androidtv to 0.0.36

* Add test for setting up two devices

* Add test_setup_same_device_twice

* Fix test_setup_two_devices

* Fix coverage

* Coverage

* Fix flaky 'test_setup_two_devices'

* Another stab at coverage

* Rename 'address' back to 'host'
2019-12-15 11:31:59 +01:00
Tyler
a28545b69b bump venstar 0.12 (#29954)
* bump venstar 0.12

* Update manifest.json
2019-12-15 08:16:20 +01:00
Chris Mandich
6dd496deb4 Fix loading flume integration (#29926)
* Fix https://github.com/home-assistant/home-assistant/issues/29853

* Run script.gen_requirements

* Update to store Token File in config directory

* Update to store Token File in config directory

* Update to store Token File in config directory
2019-12-15 03:45:29 +01:00
Quentame
820780996a Add battery sensor to iCloud (#29818)
* Add battery sensor to iCloud

* Update .coveragerc

* Review: @balloob & @MartinHjelmare

* Review: use f string
2019-12-14 23:06:00 +01:00
Raman Gupta
003658a3f0 Update androidtv version to improve source selection support (#29579)
* Change androidtv module versions and add support for select_source for all device types

* Update and add tests

* Update requirements_test_all.txt

* Update requirements_all.txt

* Consolidate tests

* Fix typo

* Remove 'self._device'
2019-12-14 16:54:41 +01:00
ochlocracy
3db7e8f5e9 Implement Alexa.EventDetectionSensor for Alexa (#28276)
* Implement Alexa.EventDetectionSensor Interface

* Removed references to PR #28218 not yet merged into dev.

* Update tests to include Alexa Interface

* Guard for `unknown` and `unavailible` states.

* Fixed Unnecessary "elif" after "return"
2019-12-14 08:47:45 +01:00
DjMoren
3c86825e25 Update Tahoma component's tahoma-api requirement's version (#29918) 2019-12-14 08:00:19 +01:00
Anders Melchiorsen
2cb92c66ef Support entity_id: all in lifx.set_state (#29919) 2019-12-14 07:36:33 +01:00
Justin Bassett
114390c95e Fix mobile app device identifiers (#29920)
Fix identifiers when updating device registration.
2019-12-14 07:36:12 +01:00
HomeAssistant Azure
8f5a00a98b [ci skip] Translation update 2019-12-14 00:32:08 +00:00
Paulus Schoutsen
a470a72ec5 Add integration platform helper (#29914) 2019-12-13 15:38:41 +01:00
springstan
6b3260357f Fix setup error for logbook (#29908)
* Fix setup error by moving an import back into the setup function

* Revert c741664d4d

* Add homekit as after_dependency to logbook manifest.json
2019-12-13 14:08:30 +01:00
Franck Nijhof
c8cc8acc81 Fixes invalid JSON syntax in devcontainer (#29911) 2019-12-13 12:41:56 +01:00
Franck Nijhof
b91a8f510c Fix incorrect file format yr test fixure (#29910) 2019-12-13 12:29:24 +01:00
Fabian Affolter
1301a4fcc6 Upgrade Sphinx to 2.2.2 and sphinx-autodoc-typehintsi to 1.10.3 (#29906) 2019-12-13 11:15:26 +01:00
Ville Skyttä
4d57de335c Make Python deprecation notice easier to maintain (#29900) 2019-12-13 10:39:57 +01:00
springstan
9fbb6d981a Fix setup for tank_utility component (#29902) 2019-12-13 10:31:53 +01:00
Bas Nijholt
c59bf0bff6 genericpath is an internal Python module and shouldn't be imported according to core Python devs. (see [this](https://bugs.python.org/msg358136) comment) (#29903)
For a reason unknown to me, @exxamalte introduced this in https://github.com/home-assistant/home-assistant/pull/14342.

The problem is that Linux and macOS implement `os.path` differently, one imports from [`ntpath.py`](https://github.com/python/cpython/blob/master/Lib/ntpath.py) and the other one from [`posixpath.py`](https://github.com/python/cpython/blob/master/Lib/posixpath.py), and both these files use `genericpath.py`.

Somehow, `isort` on macOS will see `genericpath` as a third party library and sort it accordingly.
Other Unix-based OSes will correctly treat `genericpath` as an internal library.

This problem led to a sorting sequence in the following commits:

- ca0fad2cbb
- f5d4878992
- 7d68e88d31
- 1fee400dcd

This supersedes https://github.com/home-assistant/home-assistant/pull/29893.
2019-12-13 09:47:09 +01:00
HomeAssistant Azure
5b32ee566c [ci skip] Translation update 2019-12-13 00:32:17 +00:00
Sebastian Muszynski
c051ae0bfb Bump python-miio version to 0.4.8 (#29890) 2019-12-12 22:39:11 +01:00
Alexei Chetroi
7685c76b9b Defer log formatting. (#29888) 2019-12-12 14:16:02 -05:00
randellhodges
9d662d6114 ISY994 Node Filter Update (#28155)
* Adding filters for keypad dimmers and smoke sensor

* ran black --fast as suggested

* Adding filters for keypad dimmers and smoke sensor

* ran black --fast as suggested
2019-12-12 19:47:38 +01:00
John Luetke
7c42f4b45b (Re)Add support for multiple Pi-Holes (#27569)
* Update configuration schema to support multiple Pi-holes

* Construct sensors for each configured Pi-hole

* Ensure each Pi-hole has a unique name

* Update services to handle multiple Pi-holes

* Update tests for multiple configurations

* Refactor tests to support service testing

* Fix else-raise per pyliunt

* Per code review, add all entities in a single call

* Per code review, add the default name as default.

* Per code review, add cv.ensure_list to prevent breaking change

* Per code review, move name validation to schema

* Remove default name

* Per code review, validate api_key in schema definition

* Per code review, rename variables

* Per code review, use list comprehension

* Ensure unique slug names in config validation

* Per code review, refactor to CoroutineMock

* Fix adding sensor entities

* Per code review, refactor mock function creation

* Per code review, refactor mock function return values
2019-12-12 19:43:49 +01:00
Alexei Chetroi
327b5c3c94 Log ZHA bind/unbind operations status (#29842)
* Log bind/unbind operation result.
* Use ZDO consts.
* Use device logger for bind/unbind results.
* Lint.
2019-12-12 12:16:51 -05:00
Alexei Chetroi
1fee400dcd Revert "Sort import for tests/components/feedreader/test_init.… (#29882)
This reverts commit 7d68e88d31.
2019-12-12 17:10:43 +01:00
Ville Skyttä
130571c478 Remove no longer needed auth.util, use secrets instead (#29861) 2019-12-12 16:46:33 +01:00
Bas Nijholt
c58c10ab7c Add isort to CI and pre-commit (#29739)
* add isort to CI and pre-commit

* disable wrong-import-order in pylintrc

* ✏️ Tweak


Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2019-12-12 15:58:47 +01:00
Bas Nijholt
7d68e88d31 Sort import for tests/components/feedreader/test_init.py (#29878)
This unblocks https://github.com/home-assistant/home-assistant/pull/29739
2019-12-12 15:56:32 +01:00
Franck Nijhof
4b33578757 Fix package import sort on dwd_weather_warnings (#29874) 2019-12-12 14:45:00 +01:00
Aaron Bach
914b49566a Bump aioambient to 1.0.2 (#29850) 2019-12-12 10:24:57 +01:00
Ville Skyttä
7931a0b675 Use Bionic's ffmpeg on Travis, jonathonf/ffmpeg-4 is N/A at the moment (#29860) 2019-12-12 07:15:32 +01:00
Paulus Schoutsen
b9eb831d29 Revert Tahoma removal (#29840)
* Revert "Remove Tahoma component #29744 (#29745)"

This reverts commit df74272ba6.

* Revert "Cleanup removed component (#29788)"

This reverts commit 3a28361beb.
2019-12-12 06:37:55 +01:00
HomeAssistant Azure
7bd98d1082 [ci skip] Translation update 2019-12-12 00:32:15 +00:00
foxy82
a08e3d7352 Update rfxtrx component so it can be run as a custom_component (#29638)
* Updating rfxtrx component so it can be run as a custom_component

* Fix pylint errors

* Fix pylint errors

* Fix pylint error on dict.

* isort
2019-12-11 15:58:49 +01:00
Robert Svensson
856dd63680 Add more logging to help future debug situations (#29800) 2019-12-11 15:45:21 +01:00
springstan
7b8dff2aa9 Add user-agent to fix dwd_weather_warnings setup error (#29596)
* Added dummy user-agent to http request to fix setup error

* Replace dummy user-agent with the user-agent of the global home assistant session

* Adjust comment and rename user-agent constant
2019-12-11 15:43:54 +01:00
Pascal Vizeli
0c796fc3c3 Remove uvloop event policy (#29835)
* Remove uvloop event policy

* Clean tests

* Fix lint

* Cleanup statment
2019-12-11 13:28:50 +01:00
Tiit Rätsep
01ef44fd68 Fix Soma integration connection issue (#27692)
* Added a check for Connect actually returning something before telling the user the setup succeeded

* Added handling for KeyError in case API returns empty response, formatting

* Trying to please the linter
2019-12-11 13:27:28 +01:00
Bas Nijholt
004af97699 Sort imports for requirements.py and its test using isort (#29836)
Unblocks https://github.com/home-assistant/home-assistant/pull/29739
2019-12-11 12:12:06 +01:00
HomeAssistant Azure
c2357d843b [ci skip] Translation update 2019-12-11 00:32:21 +00:00
Ville Skyttä
a12cf7211d Upgrade pydocstyle to 5.0.1 (#29830)
* Upgrade pydocstyle to 5.0.1

http://www.pydocstyle.org/en/5.0.1/release_notes.html

* Pydocstyle and other docstring fixes
2019-12-10 23:25:06 +01:00
Alexei Chetroi
3ed1738f76 Fix input_text initialization with empty config. (#29829) 2019-12-10 23:24:33 +01:00
Robert Van Gorkom
66d2f5f61d Fix withings wrong sleep state entry (#29651)
* Fixing issue where wrong sleep state entry was being used. closes #28370,#29397

* Fixing formatting.

* Sorting imports to get black checks to pass.

* Using lambda for getting latest sleep serie.
2019-12-10 21:54:50 +01:00
Ville Skyttä
899f6cf1a3 Re-authorize Huawei LTE on login required error (#29597)
* Re-authorize Huawei LTE on login required error

Closes https://github.com/home-assistant/home-assistant/issues/29531

* Eliminate one indented "else" block

* Convert get_data from inline to instance method

* Use .get instead of [] for checking subscriptions for clarity
2019-12-10 22:41:29 +02:00
Robert Svensson
99328bd4c1 UniFi - honor detection time when UniFi wire bug happens (#29820) 2019-12-10 20:05:18 +01:00
Robert Svensson
47e5142ddb UniFi - Handle disabled switches (#29824) 2019-12-10 20:04:48 +01:00
proferabg
e28fd16c84 Fix tank utility token (#29801)
* Tank Utility Token Fix

Fix 400 Bad Request on Invalid Token

* Format Fix for Pull Request #29801

* Pylint Annotation Fix for Pull Request #29801
2019-12-10 19:25:21 +01:00
Robert Svensson
db0baab692 Only update disabled_by when enabled default and entity enabled states differ (#29643) 2019-12-10 11:02:26 +01:00
Franck Nijhof
f5d4878992 Fix isort on a small set of misc files (#29803) 2019-12-10 09:25:42 +01:00
Paulus Schoutsen
27244e29c4 Install discovery requirements if used (#29795)
* Install discovery requirements if used

* Update loader.py

* Fix types
2019-12-10 09:24:49 +01:00
Franck Nijhof
0ed6a434f8 Adjusts repository README (#29805) 2019-12-10 09:22:37 +01:00
Ian
4f1f4a1b4f Nextbus: Sort results for upcoming times (#29811)
Sort upcoming times across all direction's for a particular route and
stop.
2019-12-10 09:22:13 +01:00
Brett T. Warden
9049e090f9 Bump Roku to 4.0.0 (#29809) 2019-12-10 09:20:52 +01:00
Alexei Chetroi
315d0064fe Fix zha circular import (#29802)
* Refactor zha.core.helpers.
* Make zha isort-able.
* Const import reorg.
* Keep DATA_ZHA config key on entry unload.
* Cleanup ZHA config flow.
* isort.
* Add test.
2019-12-10 00:00:04 -05:00
HomeAssistant Azure
12f273eb11 [ci skip] Translation update 2019-12-10 00:32:16 +00:00
Franck Nijhof
38a6fffecb Add JSON files validation to hassfest (#29799) 2019-12-09 22:43:38 +01:00
Alexei Chetroi
454cc684e4 Add input_select reload service. (#29647)
* Add input_select reload service.

* Add test.
2019-12-09 21:15:32 +01:00
Alexei Chetroi
8c1cdc0cf7 Add input_text reload service. (#29644)
* Add input_text reload service.

* Add test.
2019-12-09 21:15:24 +01:00
David F. Mulcahey
1222aa8c56 Add ZHA group API (#29641)
* add skeleton to retrieve zigbee groups
* get single group
* add a group
* return group members with group
* add comment
* fix group members
* add function to add device to group
* add group members
* add remove from group method
* add api to remove members from group
* add remove groups method
* clean up group add and remove
* fix remove group
* fix remove groups
* add api to get only groupable devices
* change var init
* add tests
* address review comment
2019-12-09 14:50:04 -05:00
Bas Nijholt
7f948594eb Sort imports according to PEP8 for google_assistant (#29633)
* sort imports and fix flake8 issue for google

* add isort:skip to EVENT_SYNC_RECEIVED
2019-12-09 20:00:14 +01:00
Franck Nijhof
bc3b7ed06b Fix build, invalid JSON file in icloud component (#29798) 2019-12-09 19:18:41 +01:00
Bas Nijholt
e37443f10c Sort imports according to PEP8 for components starting with "U" (#29779)
* use isort to sort imports for components starting with 'u'

* add 'pylint: disable=import-error' to the right place
2019-12-09 19:07:32 +01:00
Bas Nijholt
80c344d3a8 Sort imports according to PEP8 for huawei_lte (#29664) 2019-12-09 19:06:25 +01:00
Bas Nijholt
897522a82d Fix 'pytest.register_assert_rewrite("tests.common")' warning (#29797)
see fea243c035 (r355533273)
2019-12-09 19:04:38 +01:00
Bas Nijholt
080c702d4f Sort imports according to PEP8 for components starting with "C" (#29763) 2019-12-09 18:56:21 +01:00
Bas Nijholt
6cc75fc6f3 Sort imports according to PEP8 for components starting with "Z" (#29784)
* use isort to sort imports for components starting with 'z'

* add skip to end of zha/core/channels/__init__.py

* put 'pylint: disable=import-error' at the right place

* remove the import of config_flow in zha/__init__.py

According to @balloob it is no longer needed.

* revert previous commit

* isort:skip homeassistant/components/zha/__init__.py completely
2019-12-09 18:54:54 +01:00
springstan
6b6570e7ca Move imports to top for ness_alarm (#29518)
* Move imports to top for ness_alarm

* Added patch for the ArminState in alarm_control_panel.py
2019-12-09 18:46:56 +01:00
Bas Nijholt
08f128e9c7 Sort imports according to PEP8 for components starting with "D" (#29764)
* use isort to sort imports for components starting with 'd'

* fix isort mistake
2019-12-09 17:42:00 +01:00
Quentame
c804f8f961 Add config flow to iCloud (#28968)
* iCloud: setup ConfigFlow and prepare for more platforms

- add config flow + tests
- fix existing services
- add play_sound & display_message services
- document services
- can use devices with the same name
- prepare to add sensor platform

* Review : not copy account conf

* Review: Safer test patch

* Review: remove reset_account

* Review: Use executor_job while IO

* Review: Use executor_job while IO 2

* Review: use hass.helpers.storage.Store()

* Review: no IO in tests

* Remove reset from services.yaml

* Review: remove authenticate.return_value = Mock()

* Review: do not initialize the api with the mocked service

* isort

* Review: @MartinHjelmare Test config flow with all steps

* Review: Fix failed tests names

* Codevov: Add one missing test
2019-12-09 17:19:42 +01:00
Bas Nijholt
f60125b5c9 Sort imports according to PEP8 for 'tests' (#29791) 2019-12-09 16:52:24 +01:00
Bas Nijholt
67c56c860d Sort imports according to PEP8 for 'homeassistant' folder (#29789)
Components are already done
2019-12-09 16:42:10 +01:00
Bas Nijholt
29ec17d50d use isort to sort imports for "setup.py" (#29792) 2019-12-09 16:30:16 +01:00
Bas Nijholt
5cb6d1b21f Sort imports according to PEP8 for 'script' folder (#29790) 2019-12-09 16:24:03 +01:00
Pascal Vizeli
3a28361beb Cleanup removed component (#29788) 2019-12-09 16:21:12 +01:00
springstan
72f336a2dd Move imports to top for homekit (#29560)
* Move imports to top for homekit

* Moved back a couple imports, added annotation to disable import-outside-toplevel

* Fix all tests in test_homekit.py
2019-12-09 16:10:02 +01:00
Bram Kragten
bb3fa6990a Updated frontend to 20191204.1 (#29787) 2019-12-09 15:10:03 +01:00
Bas Nijholt
96a6a44411 Sort imports according to PEP8 for components starting with "X" (#29782) 2019-12-09 14:58:51 +01:00
Bas Nijholt
9bcd4653e0 Sort imports according to PEP8 for components starting with "Y" (#29783) 2019-12-09 14:57:42 +01:00
Bas Nijholt
4035fda659 Sort imports according to PEP8 for components starting with "Q" (#29785) 2019-12-09 14:56:20 +01:00
Bas Nijholt
fbf1836997 Sort imports according to PEP8 for components starting with "W" (#29781) 2019-12-09 14:47:53 +01:00
Bas Nijholt
1ab1808307 Sort imports according to PEP8 for components starting with "N" (#29773) 2019-12-09 14:46:24 +01:00
Bas Nijholt
ee1cc3b3dd Sort imports according to PEP8 for components starting with "V" (#29780) 2019-12-09 14:42:53 +01:00
Bas Nijholt
de915e1bf0 Sort imports according to PEP8 for components starting with "T" (#29778) 2019-12-09 14:41:48 +01:00
Bas Nijholt
485761bbaf Sort imports according to PEP8 for components starting with "R" (#29776) 2019-12-09 14:39:51 +01:00
Bas Nijholt
23b92b2a56 Sort imports according to PEP8 for components starting with "S" (#29777) 2019-12-09 14:38:01 +01:00
Bas Nijholt
21816eeed4 Sort imports according to PEP8 for components starting with "P" (#29775) 2019-12-09 14:29:39 +01:00
Bas Nijholt
5cdaff5405 Sort imports according to PEP8 for components starting with "O" (#29774) 2019-12-09 14:26:53 +01:00
Bas Nijholt
c49e423c78 Sort imports according to PEP8 for components starting with "K" (#29770) 2019-12-09 14:25:18 +01:00
Bas Nijholt
1dea0c9e34 Sort imports according to PEP8 for components starting with "L" (#29771) 2019-12-09 14:22:30 +01:00
Bas Nijholt
14779ce3d0 Sort imports according to PEP8 for components starting with "I" (#29769) 2019-12-09 14:21:24 +01:00
Bas Nijholt
710680d604 use isort to sort imports for components starting with 'm' (#29772) 2019-12-09 18:50:40 +05:30
Bas Nijholt
8b39957c56 Sort imports according to PEP8 for components starting with "H" (#29768) 2019-12-09 14:19:48 +01:00
Bas Nijholt
d58e6e924a Sort imports according to PEP8 for components starting with "G" (#29767) 2019-12-09 14:17:36 +01:00
Bas Nijholt
ca0fad2cbb Sort imports according to PEP8 for components starting with "F" (#29766) 2019-12-09 14:14:40 +01:00
Bas Nijholt
f9e06ca2fd Sort imports according to PEP8 for components starting with "E" (#29765) 2019-12-09 14:10:04 +01:00
Bas Nijholt
96961b9bcc Sort imports according to PEP8 for components starting with "A" (#29761) 2019-12-09 13:57:24 +01:00
Bas Nijholt
73de69896b Sort imports according to PEP8 for components starting with "B" (#29762) 2019-12-09 13:52:18 +01:00
tetienne
df74272ba6 Remove Tahoma component #29744 (#29745) 2019-12-09 13:35:14 +01:00
Pascal Vizeli
4bb670cdf7 HomeAssistant-pyozw 0.1.7 (#29743) 2019-12-09 13:33:28 +01:00
Bas Nijholt
9b27e5b86c Sort imports according to PEP8 for vultr (#29760) 2019-12-09 13:33:08 +01:00
Bas Nijholt
c7cf1b820c Sort imports according to PEP8 for hue (#29757) 2019-12-09 13:25:04 +01:00
Bas Nijholt
abfcc18004 Sort imports according to PEP8 for mobile_app (#29758) 2019-12-09 13:22:42 +01:00
Bas Nijholt
53012a548b Sort imports according to PEP8 for sleepiq (#29759) 2019-12-09 13:21:45 +01:00
Bas Nijholt
60e1789557 Sort imports according to PEP8 for emulated_roku (#29756) 2019-12-09 13:20:51 +01:00
Bas Nijholt
991834f337 Sort imports according to PEP8 for shopping_list (#29751) 2019-12-09 13:14:49 +01:00
Bas Nijholt
d1b38c0c79 Sort imports according to PEP8 for plaato (#29747) 2019-12-09 13:14:08 +01:00
Bas Nijholt
f281069c8c Sort imports according to PEP8 for vicare (#29754) 2019-12-09 13:13:33 +01:00
Bas Nijholt
76debf4c88 Sort imports according to PEP8 for scene (#29750) 2019-12-09 13:12:43 +01:00
Bas Nijholt
127d84edd1 Sort imports according to PEP8 for solarlog (#29752) 2019-12-09 13:11:37 +01:00
Bas Nijholt
3f469eac28 Sort imports according to PEP8 for yeelight (#29755) 2019-12-09 13:10:24 +01:00
Bas Nijholt
f81e608cc1 Sort imports according to PEP8 for remote (#29749) 2019-12-09 13:09:16 +01:00
Bas Nijholt
c4a6f265e8 Sort imports according to PEP8 for versasense (#29753) 2019-12-09 13:08:05 +01:00
Bas Nijholt
e9b428781b Sort imports according to PEP8 for pushbullet (#29748) 2019-12-09 13:06:25 +01:00
Bas Nijholt
3df40c7a16 Sort imports according to PEP8 for websocket_api (#29657) 2019-12-09 12:30:23 +01:00
Bas Nijholt
16a7408f23 Sort imports according to PEP8 for zwave (#29658) 2019-12-09 12:29:12 +01:00
Bas Nijholt
41cd678f00 Sort imports according to PEP8 for deconz (#29659) 2019-12-09 12:25:35 +01:00
Bas Nijholt
2da3848f89 Sort imports according to PEP8 for unifi (#29656) 2019-12-09 12:19:33 +01:00
Bas Nijholt
3b0f29fe95 sort imports according to PEP8 for lock (#29663) 2019-12-09 12:19:11 +01:00
Bas Nijholt
eb47c2b148 Sort imports according to PEP8 for media_player (#29665) 2019-12-09 12:17:41 +01:00
Bas Nijholt
01d651c67d Sort imports according to PEP8 for device_tracker (#29666) 2019-12-09 12:14:38 +01:00
Bas Nijholt
27bd6ca1db Sort imports according to PEP8 for emulated_hue (#29667) 2019-12-09 12:12:41 +01:00
Bas Nijholt
05daa817f5 Sort imports according to PEP8 for owntracks (#29672) 2019-12-09 12:11:27 +01:00
Bas Nijholt
d62993c5af Sort imports according to PEP8 for pilight (#29673) 2019-12-09 12:10:38 +01:00
Bas Nijholt
04225ba802 Sort imports according to PEP8 for rest (#29674) 2019-12-09 12:09:49 +01:00
Bas Nijholt
186799794d Sort imports according to PEP8 for nest (#29670) 2019-12-09 12:08:51 +01:00
Bas Nijholt
ad58e607df Sort imports according to PEP8 for somfy (#29675) 2019-12-09 12:07:10 +01:00
Bas Nijholt
69b113c539 Sort imports according to PEP8 for dyson (#29678) 2019-12-09 12:04:39 +01:00
Bas Nijholt
3d10bb3647 Sort imports according to PEP8 for http (#29679) 2019-12-09 11:59:38 +01:00
Bas Nijholt
c7d61279bd Sort imports according to PEP8 for ring (#29680) 2019-12-09 11:58:40 +01:00
Bas Nijholt
df85a50f3b Sort imports according to PEP8 for sensor (#29683) 2019-12-09 11:57:49 +01:00
Bas Nijholt
9cf3ff319e Sort imports according to PEP8 for iaqualink (#29681) 2019-12-09 11:56:51 +01:00
Bas Nijholt
b54c8641b4 Sort imports according to PEP8 for vesync (#29684) 2019-12-09 11:56:02 +01:00
Bas Nijholt
e4e4f78eb0 Sort imports according to PEP8 for utility_meter (#29710) 2019-12-09 11:54:56 +01:00
Bas Nijholt
b6cd6135c2 Sort imports according to PEP8 for wemo (#29685) 2019-12-09 11:53:51 +01:00
Bas Nijholt
776d8cfdc9 Sort imports according to PEP8 for specific_devices (#29687) 2019-12-09 11:51:36 +01:00
Bas Nijholt
c54135486e use isort to sort imports according to PEP8 for netatmo (#29682) 2019-12-09 11:50:59 +01:00
Bas Nijholt
4c5c34919d Sort imports according to PEP8 for camera (#29691) 2019-12-09 11:50:48 +01:00
Bas Nijholt
0b4ca9ecac Sort imports according to PEP8 for ambiclimate (#29689) 2019-12-09 11:49:35 +01:00
Bas Nijholt
bfa58f671a use isort to sort imports according to PEP8 for broadlink (#29690) 2019-12-09 11:48:52 +01:00
Bas Nijholt
9c1236b6de Sort imports according to PEP8 for ffmpeg (#29693) 2019-12-09 11:48:22 +01:00
Bas Nijholt
38657c0055 Sort imports according to PEP8 for counter (#29692) 2019-12-09 11:47:35 +01:00
Bas Nijholt
2261bb60e0 Sort imports according to PEP8 for geofency (#29695) 2019-12-09 11:46:49 +01:00
Bas Nijholt
2511f5edb4 Sort imports according to PEP8 for ifttt (#29696) 2019-12-09 11:46:08 +01:00
Bas Nijholt
fa6b75f2c1 Sort imports according to PEP8 for file (#29694) 2019-12-09 11:45:11 +01:00
Bas Nijholt
a78fe25871 Sort imports according to PEP8 for locative (#29698) 2019-12-09 11:43:46 +01:00
Bas Nijholt
642655b6d7 Sort imports according to PEP8 for met (#29699) 2019-12-09 11:43:00 +01:00
Bas Nijholt
c7b2c09a61 Sort imports according to PEP8 for xiaomi_miio (#29677) 2019-12-09 11:42:18 +01:00
Bas Nijholt
0e71c29e00 Sort imports according to PEP8 for opentherm_gw (#29671) 2019-12-09 11:34:06 +01:00
Bas Nijholt
0fbb450838 Sort imports according to PEP8 for jewish_calendar (#29697)
* use isort to sort imports according to PEP8 for jewish_calendar

* fix order
somehow isort did the wrong thing
2019-12-09 11:30:31 +01:00
springstan
202522fbca Move imports to top for nsw_fuel_station (#29538)
* Move imports to top for nsw_fuel_station

* Correct patch path in test_sensor.py

* Fix tests by removing the unused argument mock_nsw_fuel
2019-12-09 11:29:36 +01:00
Bas Nijholt
425a1814d9 Sort imports according to PEP8 for geonetnz_quakes (#29668) 2019-12-09 11:28:07 +01:00
Bas Nijholt
790881fa7b Sort imports according to PEP8 for almond (#29688) 2019-12-09 11:27:16 +01:00
Bas Nijholt
69f790f6cc Sort imports according to PEP8 for arduino (#29702) 2019-12-09 11:26:03 +01:00
Bas Nijholt
852996700f Sort imports according to PEP8 for arest (#29703) 2019-12-09 11:25:29 +01:00
Bas Nijholt
2cd55bbb87 Sort imports according to PEP8 for device_automation (#29707) 2019-12-09 11:24:49 +01:00
Bas Nijholt
ea39d5b428 Sort imports according to PEP8 for aws (#29704) 2019-12-09 11:23:21 +01:00
Bas Nijholt
f9e9a5e4cb Sort imports according to PEP8 for darksky (#29706) 2019-12-09 11:22:04 +01:00
Bas Nijholt
9228ed7c40 Sort imports according to PEP8 for verisure (#29711) 2019-12-09 11:21:16 +01:00
Bas Nijholt
6a11e6aa72 Sort imports according to PEP8 for soma (#29709) 2019-12-09 11:19:23 +01:00
Bas Nijholt
ebb2722d03 Sort imports according to PEP8 for gpslogger (#29717) 2019-12-09 11:15:02 +01:00
Bas Nijholt
c5316dbc39 Sort imports according to PEP8 for iqvia (#29720) 2019-12-09 11:14:08 +01:00
Bas Nijholt
c3d7ab6a7f Sort imports according to PEP8 for netgear_lte (#29725) 2019-12-09 11:13:37 +01:00
Bas Nijholt
7128396f1a Sort imports according to PEP8 for minio (#29723) 2019-12-09 11:08:29 +01:00
Bas Nijholt
6a67532a2d Sort imports according to PEP8 for linky (#29722) 2019-12-09 11:07:50 +01:00
Bas Nijholt
cbf59fb33d Sort imports according to PEP8 for input_text (#29719) 2019-12-09 11:06:05 +01:00
Bas Nijholt
9df71ecae2 Sort imports according to PEP8 for neato (#29724) 2019-12-09 11:05:22 +01:00
Nikolay Vasilchuk
791dc5809f Fix unit_of_measurement for Starline temperature sensors (#29740) 2019-12-09 10:56:57 +01:00
Santobert
c399fe2837 Change source of device_info (#29570) 2019-12-09 10:46:25 +01:00
Bas Nijholt
d0c7db548f use isort to sort imports according to PEP8 for group (#29713) 2019-12-09 09:39:26 +01:00
Bas Nijholt
1790036767 use isort to sort imports according to PEP8 for zone (#29712) 2019-12-09 09:38:38 +01:00
Bas Nijholt
2abc9005cc use isort to sort imports according to PEP8 for homeassistant (#29718) 2019-12-09 09:38:24 +01:00
Bas Nijholt
236a21c76e Sort imports according to PEP8 for pi_hole (#29726) 2019-12-09 09:38:14 +01:00
Bruno Filipe
942f654d92 Proactively report Alexa Endpoint Health properties (#29736) 2019-12-09 09:37:15 +01:00
Bas Nijholt
8c1a8b502d Sort imports according to PEP8 for velbus (#29676) 2019-12-09 09:36:42 +01:00
gjbadros
6996ad3541 Protect Doorbird platform from failing when individual doorbird fails (#29374)
* Wrap connection attempt by try/except block so an individual downed doorbird does not fail the whole platform

* Fixed lint warning

* Disable too-broad-exception pylint warning since the whole point of this is to catch all exceptions and log them while letting processing continue; I don't disable a lint warning lightly, but this is the entire intent of this PR.

* Fixed name of pylint warning to broad-except

* Use _LOGGER.exception to get the stack trace too, per PEP8 recommendation for a bare Exception being caught.

* per @balloob, switch to just catching OSError on a narrow block; I'm not sure this protects all problems with Doorbird device startup, but it protects against the primary one I experience.
2019-12-09 09:14:55 +01:00
HomeAssistant Azure
8dea7f0f98 [ci skip] Translation update 2019-12-09 00:32:08 +00:00
Bernhard B
d451e54e34 Add Signal Messenger integration (#28537)
* added signalmessenger integration

* allows to send a message (with an attachment) to one or more
  recipients

* added signalmessenger documentation to manifest file

* remove debug logging from signalmessenger integration

* add signalmessenger to .coveragerc

* fixed typo in signalmessenger manifes

* moved service specific code to own pypi library

* updated pysignalclirestapi dependeny in manifest.json

* added pysignalclirestapi requirement for signalmessenger component

* fixed typo in codeowners

* reworked signalmessenger integration based on code review input

* updated requirements for signalmessenger

* small code improvements in signalmessenger integration

* no need to use the get() method to access dict parameters that are
required

* small changes in signalmessenger integration

* re-ordered import statements
* removed empty "requirements" list (not needed)

* changed import order in signalmessenger integration according to PEP 8

* used isort to order includes in signalmessenger integration

* renamed signalmessenger to signal_messenger

* renamed signalmessenger to signal_messenger in CODEOWNERS file

* changed documentation url in signal_messenger integration to new name

* changed signal messenger naming in .coveragerc
2019-12-09 00:27:06 +01:00
Robert Van Gorkom
e577f047f7 Add tests for vera component (#28340)
* Adding tests for vera component.
Fixing update bug in the vera climate platform.

* Updating requrements file.

* Moving vera stop to a job.
Sorting imports.

* Addressing simple PR feedback.

* Splitting tests into platforms.

* Mocking controller instead of using requests_mock.

* Updating pyvera to use version that stops threads quickly.

* Updating requirements files.

* Mocking the pyvera module, not the API.

* Addressing PR feedback.
Handling start/stop of patch in fixture.
Removing unecessary code.

* Using generator
2019-12-09 00:19:38 +01:00
Bas Nijholt
076e0273a2 Sort imports according to PEP8 for kodi (#29721) 2019-12-08 23:42:04 +01:00
Bas Nijholt
39887c46c0 Sort imports according to PEP8 for dialogflow (#29714) 2019-12-08 23:40:06 +01:00
Bas Nijholt
81a482332d Sort imports according to PEP8 for eufy (#29715) 2019-12-08 23:34:18 +01:00
Bas Nijholt
6a1753d6db Sort imports according to PEP8 for geonetnz_volcano (#29716) 2019-12-08 23:33:42 +01:00
Bas Nijholt
cce3077df3 Sort imports according to PEP8 for cert_expiry (#29705) 2019-12-08 23:32:50 +01:00
Bas Nijholt
e6eed4755f Sort imports according to PEP8 for plex (#29708) 2019-12-08 23:31:55 +01:00
Gerald Hansen
3d25ed7994 Change state values for Worx Landroid sensor (#27453)
The obj["state"] contains already several named return states as
following: "grass cutting", "trapped recovery", "searching wire",
           "following wire", "searching home", "home", "idle"
And with the batteryChargerState also the "charging"

Fixes #455
2019-12-08 22:27:18 +01:00
Bas Nijholt
55559f3e30 Sort imports according to PEP8 for starline (#29653) 2019-12-08 21:09:48 +01:00
Bas Nijholt
51ece97e0d Sort imports according to PEP8 for hive (#29669) 2019-12-08 21:06:05 +01:00
Bas Nijholt
415176e350 Sort imports according to PEP8 for template (#29655) 2019-12-08 21:05:08 +01:00
Bas Nijholt
e0b82440ad Sort imports according to PEP8 for switch (#29654) 2019-12-08 18:50:17 +01:00
Bas Nijholt
3d64405896 Sort imports according to PEP8 for recorder (#29652) 2019-12-08 18:48:18 +01:00
Fabian Affolter
b832749e3c Fix file permission (#29660) 2019-12-08 18:41:48 +01:00
Bas Nijholt
0a4979549d use isort to sort imports according to PEP8 for vacuum (#29650) 2019-12-08 22:47:01 +05:30
Bas Nijholt
b731ddabde Sort imports according to PEP8 for homekit (#29645) 2019-12-08 18:16:49 +01:00
Bas Nijholt
aeff27680b use isort to sort imports according to PEP8 for light (#29648) 2019-12-08 22:46:23 +05:30
Bas Nijholt
ce5072fc91 use isort to sort imports according to PEP8 for mqtt (#29649) 2019-12-08 22:45:26 +05:30
Bas Nijholt
d2c1e5d45c Sort imports according to PEP8 for homekit_controller (#29646) 2019-12-08 18:14:26 +01:00
Bas Nijholt
0d5de6a464 use isort to sort imports according to PEP8 for ecobee (#29631) 2019-12-08 22:31:50 +05:30
Bas Nijholt
fbd4cf1089 use isort to sort imports according to PEP8 for cloud (#29626) 2019-12-08 22:31:12 +05:30
Bas Nijholt
e4e9cdce73 use isort to sort imports according to PEP8 for demo (#29630) 2019-12-08 22:29:27 +05:30
Bas Nijholt
a3b605bb7d use isort to sort imports according to PEP8 for cover (#29629) 2019-12-08 22:28:00 +05:30
Bas Nijholt
f355570f17 use isort to sort imports according to PEP8 for config (#29628) 2019-12-08 22:27:28 +05:30
Bas Nijholt
73c373a0f2 use isort to sort imports according to PEP8 for command_line (#29627) 2019-12-08 22:25:57 +05:30
Bas Nijholt
954813b478 use isort to sort imports according to PEP8 for climate (#29625) 2019-12-08 22:25:01 +05:30
springstan
3b5da9c44a Move imports to top for homekit_controller (#29564)
* Move imports to top for homekit_controller

* Fix IpPairing mock in two test files
2019-12-08 16:50:57 +00:00
Bas Nijholt
8f5e8c72c6 use isort to sort imports according to PEP8 for binary_sensor (#29622) 2019-12-08 22:02:08 +05:30
Bas Nijholt
f5288db93c use isort to sort imports according to PEP8 for cast (#29624) 2019-12-08 22:00:57 +05:30
Bas Nijholt
d3f67c3841 use isort to sort imports according to PEP8 for automation (#29620) 2019-12-08 21:59:39 +05:30
Bas Nijholt
a38f3ac9c6 use isort to sort imports according to PEP8 for fan (#29632) 2019-12-08 21:28:47 +05:30
Robert Svensson
57a3f7d5c8 Pass in parameters explicitly to DeconzSession (#29617)
Dont pass in loop to DeconzSession
Services will use new refresh state method
2019-12-08 16:53:34 +01:00
Bas Nijholt
00dc721609 sort imports according to PEP8 for hassio (#29634) 2019-12-08 16:33:22 +01:00
Bas Nijholt
b0d0060643 sort imports according to PEP8 for axis (#29621) 2019-12-08 15:44:03 +01:00
Fabian Affolter
c4794572d4 Fix file permission (#29635) 2019-12-08 15:43:09 +01:00
Sören Beye
94dec483e9 Don't escape command parameters (#29504)
* Don't escape command parameters

Escaping should only be done when using the tcp socket cli interface which we aren't.

* Updated comment to reflect the changes
2019-12-08 15:18:46 +01:00
James Nimmo
c78773970b Add IntesisHome Climate Platform (#25364)
* Add IntesisHome Climate Platform

* Add support for IntesisHome and Airconwithme devices

* Implement requested changes from PR review

* Improve error handling for IntesisHome component

* Fix snake-case naming style

* Update exception logging
2019-12-08 15:09:16 +01:00
Bas Nijholt
663e2eaaff sort imports according to PEP8 for buienradar (#29623) 2019-12-08 14:59:21 +01:00
Bas Nijholt
ba34922b03 sort imports according to PEP8 for alexa (#29618) 2019-12-08 14:56:42 +01:00
Bas Nijholt
6ad3b6426a sort imports according to PEP8 for auth (#29619) 2019-12-08 14:55:23 +01:00
Fabian Affolter
fa00808f6c Upgrade keyring to 19.3.0 and keyrings.alt to 3.2.0 (#29607) 2019-12-08 13:51:54 +01:00
Bas Nijholt
09ff0a5ac6 sort imports according to PEP8 for yweather (#29608) 2019-12-08 13:50:02 +01:00
Bas Nijholt
74c0219d0c sort imports according to PEP8 for components (#29609) 2019-12-08 13:46:04 +01:00
Bas Nijholt
b4bcd477f8 sort imports according to PEP8 for acer_projector (#29611) 2019-12-08 13:45:33 +01:00
Bas Nijholt
cfe68d7e00 sort imports according to PEP8 for actiontec (#29612) 2019-12-08 13:44:44 +01:00
Bas Nijholt
a885670a9a sort imports according to PEP8 for abode (#29610) 2019-12-08 13:44:12 +01:00
Bas Nijholt
f5a1b32be0 sort imports according to PEP8 for ads (#29613) 2019-12-08 13:43:32 +01:00
Bas Nijholt
e510c4ea1d sort imports according to PEP8 for air_quality (#29614) 2019-12-08 13:42:55 +01:00
Bas Nijholt
d020486929 sort imports according to PEP8 for alarm_control_panel (#29616) 2019-12-08 13:42:31 +01:00
Bas Nijholt
700cecc8ef sort imports according to PEP8 for airly (#29615) 2019-12-08 13:41:51 +01:00
Ville Skyttä
ef4515ed70 Add Huawei LTE reboot and clear traffic statistics services (#29594)
* Add clear traffic statistics service

* Add reboot service

* Register services as admin ones

* Make URL optional when there's only one router configured

* Eliminate one if/else indent level

* Remove unnecessary .keys() with sorted()
2019-12-08 12:21:48 +01:00
springstan
d752fe3033 Move imports to top for fido (#29557)
* Move imports to top for fido

* Fix tests for fido by using patch
2019-12-08 12:20:53 +01:00
springstan
6de8072e8a Move imports to top for websocket_api (#29556)
* Move imports to top for websocket_api

* Move back an import because of circular dependency, add annotations
2019-12-08 12:19:15 +01:00
SNoof85
21cf6777bb bump freebox api version (#29527) 2019-12-08 09:49:43 +01:00
Andrew McRae
de0db1601b Add quarterly cycle for utility_meter component (#29534)
* Add quarterly tariff period to utility_meter

Many tariff cycles in Australia are 3 monthly (quarterly).
Add quarterly tariff cycle handling to the utility_meter component.

* Add quarterly tariff period to utility_meter

Many tariff cycles in Australia are 3 monthly (quarterly).
Add quarterly tariff cycle handling to the utility_meter component.

* Change date for test for utility_meter

* Add quarterly tariff period to utility_meter

Many tariff cycles in Australia are 3 monthly (quarterly).
Add quarterly tariff cycle handling to the utility_meter component.
2019-12-08 09:49:18 +01:00
springstan
94b6cbc571 Move imports to top for stream (#29548) 2019-12-08 09:48:28 +01:00
springstan
957a2e99fd Move imports to top for tellduslive (#29550) 2019-12-08 09:48:08 +01:00
springstan
b759d50900 Move imports to top for google_assistant (#29561)
* Move imports to top for google_assistant

* Fix pylint error caused by isorting the imports with noqa: F401

* Move back an import because of circular dependency, add annotations
2019-12-08 09:45:13 +01:00
Franck Nijhof
cc9589cff2 Add Elgato Key Light integration (#29592)
* Add Elgato Key Light integration

* Remove passing in of hass loop

* Tweaks a comment

* Tweaks a function name

* Ensure domain namespace in data exists in entry setup
2019-12-08 09:26:31 +01:00
SukramJ
7f4baab3f6 Add additional Magic Cube Model (#29598) 2019-12-08 09:20:13 +01:00
Marius
0cdc315038 change icon for partly-cloudy-night (#29601)
to the available mdi:weather-night-partly-cloudy
2019-12-08 10:55:39 +05:30
Alexei Chetroi
e360b1265f Add input_number.reload admin service. (#29584)
* Add input_number reload service.

* Add test.

* Allow platform setup without entities.

We can reload and add entities later.
2019-12-07 21:26:06 +01:00
Alexei Chetroi
256056430e Add input_datetime reload service. (#29581)
* Add input_datetime reload service.

* Add reload service test.
2019-12-07 21:24:56 +01:00
Alexei Chetroi
ccb0fd5e32 Register automation.reload service as an admin service. (#29582)
* homeassistant/components/automation/__init__.py

* Register automation.reload as an admin service.
2019-12-07 21:17:30 +01:00
butako
d838a56c1d Improve Tahoma Velux support (#27920)
* Improved Velux support. Added Velux Solar Roller Blind. Fixed Velux Integra Window.

* fix indentation

* black formatting

* added new devices in correct sorted order
2019-12-07 16:14:09 +01:00
SNoof85
ee657f3c2f Add service to reboot the Freebox (#29525) 2019-12-07 12:09:43 +01:00
Fabian Affolter
9d7799c0af Upgrade pyyaml to 5.2.0 (#29586) 2019-12-07 09:06:55 +01:00
Ville Skyttä
977f51a9e4 Update Travis dist to bionic (#29575) 2019-12-07 08:34:46 +02:00
springstan
e2adfc3979 Move imports to top for onboarding (#29542) 2019-12-07 11:55:15 +05:30
HomeAssistant Azure
b4c95421d3 [ci skip] Translation update 2019-12-07 00:32:13 +00:00
springstan
23fb364076 Move imports to top for openuv (#29541)
* Move imports to top for openuv

* Renamed mock_pyopenuv_ to MockClient in test_config_flow
2019-12-06 14:13:43 -07:00
springstan
1ee8057662 Move imports to top for zha (#29555)
* Move imports to top for zha
* Move back some imports, add annotation for disabling import-outside-toplevel
* Move import config_flow before import api
2019-12-06 16:12:46 -05:00
Ville Skyttä
fb66a6cf81 Treat BaseException as over-general (#29573)
To follow pylint's defaults.
2019-12-06 21:58:32 +01:00
Ville Skyttä
31c71989e9 Huawei LTE device tracker fixes (#29551)
* Include MAC address in device state attributes for absent devices too

* Use MAC address as default name whether device is connected or not

* Fix initialization of known entities

Closes https://github.com/home-assistant/home-assistant/issues/29354
2019-12-06 21:53:26 +01:00
springstan
74d86dfff9 Move imports to top for soundtouch (#29546)
* Move imports to top for soundtouch

* Format with black

* Fix pyling error by renaming variable

* Rename entity instances to include entity instead of device
2019-12-06 21:11:02 +01:00
springstan
6af30bc232 Move imports to top for notion (#29539)
* Move imports to top for notion

* Fix mocking library in test_config_flow.py
2019-12-06 12:40:00 -07:00
Fabian Affolter
8afe13e818 Upgrade certifi to >=2019.11.28 (#29571) 2019-12-06 20:09:18 +01:00
Ville Skyttä
d257fff9ce Use "kB" and "s" as UPnP/IGD units (#29552)
For consistency with various existing components, and they're more
commonly used and compact than "kbyte" and "sec".
2019-12-06 23:24:11 +05:30
springstan
c9415ab75d Move imports to top for homematic (#29558) 2019-12-06 17:46:24 +01:00
1v0dev
b8434fdcfd Add service to set netatmo home heating schedule (#29244)
* Add service to set netatmo home heating schedule.

* handle NoDevice exeption; add service argument constant
2019-12-06 17:45:27 +01:00
Martin Rowan
48aba426a9 Bump lightwave to 0.17 (#29566) 2019-12-06 17:40:59 +01:00
springstan
606d310ea3 Move imports to top for spc (#29547)
* Move imports to top for spc

* Fix pylint error by removing duplicate import
2019-12-06 15:40:04 +01:00
springstan
d9b52ef98c Move imports to top for plant (#29543) 2019-12-06 15:00:54 +01:00
springstan
f3717421c0 Move imports to top for heatmiser (#29562) 2019-12-06 14:59:32 +01:00
David K
c5f4872aea Limit available heat/cool modes for HomeKit thermostats (#28586)
* Limit available heat/cool modes for HomeKit thermostats.
The Home app only shows appropriate modes (heat/cool/auto) for the device. Depending on the climate integration, disabling the auto start might be needed.

* Include improved mapping for HVAC modes in tests
2019-12-06 14:07:45 +01:00
springstan
27530be46f Move imports to top for influxdb (#29513) 2019-12-06 17:35:35 +05:30
springstan
ec3ffe309a Move imports to top for toon (#29553) 2019-12-06 10:40:38 +01:00
springstan
d5419b77f9 Move imports to top for sleepiq (#29544) 2019-12-06 09:13:44 +01:00
springstan
1bb499aec2 Move imports to top for smhi (#29545) 2019-12-06 09:11:07 +01:00
springstan
a857148560 Move imports to top for pjlink (#29540) 2019-12-06 09:09:45 +01:00
springstan
0aace1da55 Move imports to top for nx584 (#29537) 2019-12-06 09:08:54 +01:00
Franck Nijhof
e2a9c652ab Bump pytest to 5.3.1 (#29535) 2019-12-06 09:08:06 +01:00
Malte Franken
33542f0e5e Bump georss_generic_client to 0.3 (#29532)
* bump version of georss_generic_client library

* updated requirements
2019-12-06 06:55:42 +01:00
springstan
fcf18aca34 Move imports to top for modbus (#29515)
* Move imports to top for modbus

* Include imports for TCP and UDP ModbusClients
2019-12-06 06:10:29 +01:00
springstan
8def0326dd Move imports to top for izone (#29508)
* Move imports to top for izone

* Isorted all imports, fixed tests for config_flow
2019-12-06 06:08:08 +01:00
Alexei Chetroi
dc911ecc5b Add input_boolean reload service (#29379)
* Add input_boolean reload service.

* Add reload test.

* Address comments.

Register reload service as an admin service
Setup platform even if there're no entities
2019-12-05 20:31:18 -08:00
springstan
3b6bc9067f Move imports to top for mochad (#29514)
* Move imports to top for mochad

* Fix test test_light.py for mochad

* Fix test test_switch.py for mochad

* Make intra package imports relative in switch and light
2019-12-06 02:02:34 +01:00
orrpan
9ba9b3339b Add full state view for emulated_hue (apps using emulated_hue, 'sleep cycle' and 'sleep as android') (#26650)
* Add full state view for emulated_hue

* clean and support updated sleep cycle

* emulated hue add reuasable logic and cleanup code

* emulated hue correct typos

* Update hue_api.py

* correct error message and update test_hue_api.py

* cleanup test_hue_api.py
2019-12-05 15:23:54 -08:00
springstan
173966f459 Move imports to top for switcher_kis (#29530)
* Move imports to top for switcher_kis
* Disabled ungrouped imports if TYPE_CHECKING is true
2019-12-05 18:20:07 -05:00
springstan
20fdcbadff Move imports to top for nextbus (#29520)
* Move imports to top for nextbus

* Fix test_sensor.py failed tests
2019-12-05 21:56:42 +01:00
springstan
42688a6e4a Move imports to top for ign_sismologia (#29523) 2019-12-05 21:55:48 +01:00
tetienne
97cb8a3745 Increase somfy SCAN_INTERVAL (#29524)
- There was too many errors 504
2019-12-05 21:33:56 +01:00
springstan
b4fda5faab Move imports to top for mysensors (#29517) 2019-12-05 19:54:43 +01:00
Paulus Schoutsen
ec8ea02273 Fix recursion 2019-12-05 10:40:05 -08:00
springstan
4e7b9eaed0 Move imports to top for monoprice (#29516)
* Move imports to top for monoprice

* Format test with black
2019-12-05 19:16:15 +01:00
springstan
98d2eadb76 Move imports to top for statistics (#29223)
* Move imports to top for statistics

* Added recorder to manifest.json

* Deleted recorder from manifest.json, moved import back into method, added pylint disable comment

* Moved recorder util imports away from the top

* Move recorder imports to top, add recorder as after_dependency to manifest.json
2019-12-05 18:49:28 +01:00
springstan
5bdb20098e Move imports to top for meteoalarm (#29510) 2019-12-05 16:59:56 +01:00
springstan
1846b45cb5 Move imports to top for mobile_app (#29511) 2019-12-05 16:59:31 +01:00
springstan
19893b8f3c Move imports to top for islamic_prayer_times (#29506)
* Move imports to top for islamic_prayer_times

* Fix test_sensor.py for islamic_prayer_times

* Format test_sensor.py with black

* Fix tests for islamic prayer times sensor
2019-12-05 16:58:14 +01:00
springstan
76f455cea9 Move imports to top for mediaroom (#29509) 2019-12-05 16:56:53 +01:00
springstan
2a92eb1962 Move imports to top for ipma (#29507) 2019-12-05 16:56:01 +01:00
springstan
204ca3f3a6 Move imports to top for frontend (#29487) 2019-12-05 13:44:59 +01:00
springstan
ed5cdb528c Move imports to top for group (#29485)
* Move imports to top for group

* Fix failing test for group
2019-12-05 13:44:11 +01:00
springstan
ed464a75b2 Move imports to top for system_log (#29465) 2019-12-05 13:42:56 +01:00
springstan
04722fdd63 Move imports to top for http (#29500) 2019-12-05 13:42:09 +01:00
springstan
e9917c6a81 Move imports to top for google_translate (#29499) 2019-12-05 13:22:01 +01:00
springstan
009e4df6ef Move imports to top for hue (#29501) 2019-12-05 13:19:50 +01:00
springstan
086d1f432d Move imports to top for google_pubsub (#29498) 2019-12-05 12:59:59 +01:00
springstan
564fed7879 Move imports to top for ambient_station (#29497) 2019-12-05 12:50:53 +01:00
Paulus Schoutsen
a050d54847 Make hassfest stricter (#29494)
* Make hassfest stricter

* Update manifest.json
2019-12-05 10:15:28 +01:00
springstan
f6d1eb97a3 Move imports to top for decora_wifi (#29439) 2019-12-05 09:56:17 +01:00
Paulus Schoutsen
e99184bf68 Install requirements of after_dependencies when loading integrations (#29491)
* Install requirements of after_dependencies when loading integrations

* Fix smartthings test
2019-12-05 09:28:56 +01:00
Paulus Schoutsen
957e5018f4 Version bump to 0.104.0dev0 2019-12-04 22:52:58 -08:00
4911 changed files with 135759 additions and 55893 deletions

View File

@@ -5,9 +5,7 @@ omit =
homeassistant/__main__.py
homeassistant/helpers/signal.py
homeassistant/helpers/typing.py
homeassistant/monkey_patch.py
homeassistant/scripts/*.py
homeassistant/util/async.py
# omit pieces of code that rely on external devices being present
homeassistant/components/abode/__init__.py
@@ -31,9 +29,9 @@ omit =
homeassistant/components/airly/air_quality.py
homeassistant/components/airly/sensor.py
homeassistant/components/airly/const.py
homeassistant/components/airvisual/__init__.py
homeassistant/components/airvisual/sensor.py
homeassistant/components/aladdin_connect/cover.py
homeassistant/components/alarm_control_panel/manual_mqtt.py
homeassistant/components/alarmdecoder/*
homeassistant/components/alarmdotcom/alarm_control_panel.py
homeassistant/components/alpha_vantage/sensor.py
@@ -61,14 +59,13 @@ omit =
homeassistant/components/arwn/sensor.py
homeassistant/components/asterisk_cdr/mailbox.py
homeassistant/components/asterisk_mbox/*
homeassistant/components/asuswrt/device_tracker.py
homeassistant/components/aten_pe/*
homeassistant/components/atome/*
homeassistant/components/august/*
homeassistant/components/aurora_abb_powerone/sensor.py
homeassistant/components/automatic/device_tracker.py
homeassistant/components/avea/light.py
homeassistant/components/avion/light.py
homeassistant/components/avri/sensor.py
homeassistant/components/azure_event_hub/*
homeassistant/components/azure_service_bus/*
homeassistant/components/baidu/tts.py
@@ -85,7 +82,6 @@ omit =
homeassistant/components/blockchain/sensor.py
homeassistant/components/bloomsky/*
homeassistant/components/bluesound/*
homeassistant/components/bluetooth_le_tracker/device_tracker.py
homeassistant/components/bluetooth_tracker/*
homeassistant/components/bme280/sensor.py
homeassistant/components/bme680/sensor.py
@@ -97,6 +93,9 @@ omit =
homeassistant/components/broadlink/remote.py
homeassistant/components/broadlink/sensor.py
homeassistant/components/broadlink/switch.py
homeassistant/components/brother/__init__.py
homeassistant/components/brother/sensor.py
homeassistant/components/brother/const.py
homeassistant/components/brottsplatskartan/sensor.py
homeassistant/components/browser/*
homeassistant/components/brunt/cover.py
@@ -109,13 +108,11 @@ omit =
homeassistant/components/canary/alarm_control_panel.py
homeassistant/components/canary/camera.py
homeassistant/components/cast/*
homeassistant/components/cert_expiry/sensor.py
homeassistant/components/cert_expiry/helper.py
homeassistant/components/channels/*
homeassistant/components/cisco_ios/device_tracker.py
homeassistant/components/cisco_mobility_express/device_tracker.py
homeassistant/components/cisco_webex_teams/notify.py
homeassistant/components/ciscospark/notify.py
homeassistant/components/citybikes/sensor.py
homeassistant/components/clementine/media_player.py
homeassistant/components/clickatell/notify.py
@@ -152,7 +149,6 @@ omit =
homeassistant/components/dht/sensor.py
homeassistant/components/digital_ocean/*
homeassistant/components/digitalloggers/switch.py
homeassistant/components/directv/media_player.py
homeassistant/components/discogs/sensor.py
homeassistant/components/discord/notify.py
homeassistant/components/dlib_face_detect/image_processing.py
@@ -168,7 +164,6 @@ omit =
homeassistant/components/dsmr_reader/*
homeassistant/components/dte_energy_bridge/sensor.py
homeassistant/components/dublin_bus_transport/sensor.py
homeassistant/components/duke_energy/sensor.py
homeassistant/components/dunehd/media_player.py
homeassistant/components/dwd_weather_warnings/sensor.py
homeassistant/components/dweet/*
@@ -183,6 +178,7 @@ omit =
homeassistant/components/ecobee/weather.py
homeassistant/components/econet/*
homeassistant/components/ecovacs/*
homeassistant/components/edl21/*
homeassistant/components/eddystone_temperature/sensor.py
homeassistant/components/edimax/switch.py
homeassistant/components/egardia/*
@@ -221,6 +217,7 @@ omit =
homeassistant/components/eufy/*
homeassistant/components/everlights/light.py
homeassistant/components/evohome/*
homeassistant/components/ezviz/*
homeassistant/components/familyhub/camera.py
homeassistant/components/fastdotcom/*
homeassistant/components/ffmpeg/camera.py
@@ -250,15 +247,19 @@ omit =
homeassistant/components/fritzbox/*
homeassistant/components/fritzbox_callmonitor/sensor.py
homeassistant/components/fritzbox_netmonitor/sensor.py
homeassistant/components/fritzdect/switch.py
homeassistant/components/fronius/sensor.py
homeassistant/components/frontier_silicon/media_player.py
homeassistant/components/futurenow/light.py
homeassistant/components/garadget/cover.py
homeassistant/components/garmin_connect/__init__.py
homeassistant/components/garmin_connect/const.py
homeassistant/components/garmin_connect/sensor.py
homeassistant/components/gc100/*
homeassistant/components/geniushub/*
homeassistant/components/gearbest/sensor.py
homeassistant/components/geizhals/sensor.py
homeassistant/components/gios/__init__.py
homeassistant/components/gios/air_quality.py
homeassistant/components/github/sensor.py
homeassistant/components/gitlab_ci/sensor.py
homeassistant/components/gitter/sensor.py
@@ -303,7 +304,6 @@ omit =
homeassistant/components/homematic/notify.py
homeassistant/components/homeworks/*
homeassistant/components/honeywell/climate.py
homeassistant/components/hook/switch.py
homeassistant/components/horizon/media_player.py
homeassistant/components/hp_ilo/sensor.py
homeassistant/components/htu21d/sensor.py
@@ -314,12 +314,16 @@ omit =
homeassistant/components/hydrawise/*
homeassistant/components/hyperion/light.py
homeassistant/components/ialarm/alarm_control_panel.py
homeassistant/components/iammeter/sensor.py
homeassistant/components/iaqualink/binary_sensor.py
homeassistant/components/iaqualink/climate.py
homeassistant/components/iaqualink/light.py
homeassistant/components/iaqualink/sensor.py
homeassistant/components/iaqualink/switch.py
homeassistant/components/icloud/*
homeassistant/components/icloud/__init__.py
homeassistant/components/icloud/account.py
homeassistant/components/icloud/device_tracker.py
homeassistant/components/icloud/sensor.py
homeassistant/components/izone/climate.py
homeassistant/components/izone/discovery.py
homeassistant/components/izone/__init__.py
@@ -332,6 +336,7 @@ omit =
homeassistant/components/influxdb/sensor.py
homeassistant/components/insteon/*
homeassistant/components/incomfort/*
homeassistant/components/intesishome/*
homeassistant/components/ios/*
homeassistant/components/iota/*
homeassistant/components/iperf3/*
@@ -347,6 +352,7 @@ omit =
homeassistant/components/kankun/switch.py
homeassistant/components/keba/*
homeassistant/components/keenetic_ndms2/device_tracker.py
homeassistant/components/kef/*
homeassistant/components/keyboard/*
homeassistant/components/keyboard_remote/*
homeassistant/components/kira/*
@@ -380,7 +386,6 @@ omit =
homeassistant/components/linode/*
homeassistant/components/linux_battery/sensor.py
homeassistant/components/lirc/*
homeassistant/components/liveboxplaytv/media_player.py
homeassistant/components/llamalab_automate/notify.py
homeassistant/components/lockitron/lock.py
homeassistant/components/logi_circle/__init__.py
@@ -405,17 +410,30 @@ omit =
homeassistant/components/mcp23017/*
homeassistant/components/media_extractor/*
homeassistant/components/mediaroom/media_player.py
homeassistant/components/melcloud/__init__.py
homeassistant/components/melcloud/climate.py
homeassistant/components/melcloud/const.py
homeassistant/components/melcloud/sensor.py
homeassistant/components/melcloud/water_heater.py
homeassistant/components/message_bird/notify.py
homeassistant/components/met/weather.py
homeassistant/components/meteo_france/*
homeassistant/components/meteo_france/__init__.py
homeassistant/components/meteo_france/const.py
homeassistant/components/meteo_france/sensor.py
homeassistant/components/meteo_france/weather.py
homeassistant/components/meteoalarm/*
homeassistant/components/metoffice/sensor.py
homeassistant/components/metoffice/weather.py
homeassistant/components/microsoft/tts.py
homeassistant/components/miflora/sensor.py
homeassistant/components/mikrotik/*
homeassistant/components/mikrotik/hub.py
homeassistant/components/mikrotik/device_tracker.py
homeassistant/components/mill/climate.py
homeassistant/components/mill/const.py
homeassistant/components/minecraft_server/__init__.py
homeassistant/components/minecraft_server/binary_sensor.py
homeassistant/components/minecraft_server/const.py
homeassistant/components/minecraft_server/sensor.py
homeassistant/components/minio/*
homeassistant/components/mitemp_bt/sensor.py
homeassistant/components/mjpeg/camera.py
@@ -447,8 +465,12 @@ omit =
homeassistant/components/nederlandse_spoorwegen/sensor.py
homeassistant/components/nello/lock.py
homeassistant/components/nest/*
homeassistant/components/netatmo/*
homeassistant/components/netatmo_public/sensor.py
homeassistant/components/netatmo/__init__.py
homeassistant/components/netatmo/api.py
homeassistant/components/netatmo/camera.py
homeassistant/components/netatmo/climate.py
homeassistant/components/netatmo/const.py
homeassistant/components/netatmo/sensor.py
homeassistant/components/netdata/sensor.py
homeassistant/components/netgear/device_tracker.py
homeassistant/components/netgear_lte/*
@@ -460,6 +482,7 @@ omit =
homeassistant/components/nissan_leaf/*
homeassistant/components/nmap_tracker/device_tracker.py
homeassistant/components/nmbs/sensor.py
homeassistant/components/notion/__init__.py
homeassistant/components/notion/binary_sensor.py
homeassistant/components/notion/sensor.py
homeassistant/components/noaa_tides/sensor.py
@@ -496,13 +519,13 @@ omit =
homeassistant/components/openuv/sensor.py
homeassistant/components/openweathermap/sensor.py
homeassistant/components/openweathermap/weather.py
homeassistant/components/opnsense/*
homeassistant/components/opple/light.py
homeassistant/components/orangepi_gpio/*
homeassistant/components/oru/*
homeassistant/components/orvibo/switch.py
homeassistant/components/osramlightify/light.py
homeassistant/components/otp/sensor.py
homeassistant/components/owlet/*
homeassistant/components/panasonic_bluray/media_player.py
homeassistant/components/panasonic_viera/media_player.py
homeassistant/components/pandora/media_player.py
@@ -518,16 +541,12 @@ omit =
homeassistant/components/pioneer/media_player.py
homeassistant/components/pjlink/media_player.py
homeassistant/components/plaato/*
homeassistant/components/plex/__init__.py
homeassistant/components/plex/media_player.py
homeassistant/components/plex/sensor.py
homeassistant/components/plex/server.py
homeassistant/components/plex/websockets.py
homeassistant/components/plugwise/*
homeassistant/components/plum_lightpad/*
homeassistant/components/pocketcasts/sensor.py
homeassistant/components/point/*
homeassistant/components/postnl/sensor.py
homeassistant/components/prezzibenzina/sensor.py
homeassistant/components/proliphix/climate.py
homeassistant/components/prometheus/*
@@ -547,6 +566,7 @@ omit =
homeassistant/components/qnap/sensor.py
homeassistant/components/qrcode/image_processing.py
homeassistant/components/quantum_gateway/device_tracker.py
homeassistant/components/qvr_pro/*
homeassistant/components/qwikswitch/*
homeassistant/components/rachio/*
homeassistant/components/radarr/sensor.py
@@ -592,6 +612,7 @@ omit =
homeassistant/components/russound_rnet/media_player.py
homeassistant/components/sabnzbd/*
homeassistant/components/saj/sensor.py
homeassistant/components/salt/device_tracker.py
homeassistant/components/satel_integra/*
homeassistant/components/scrape/sensor.py
homeassistant/components/scsgate/*
@@ -601,6 +622,7 @@ omit =
homeassistant/components/sensehat/light.py
homeassistant/components/sensehat/sensor.py
homeassistant/components/sensibo/climate.py
homeassistant/components/sentry/__init__.py
homeassistant/components/serial/sensor.py
homeassistant/components/serial_pm/sensor.py
homeassistant/components/sesame/lock.py
@@ -626,6 +648,7 @@ omit =
homeassistant/components/smappee/*
homeassistant/components/smarty/*
homeassistant/components/smarthab/*
homeassistant/components/sms/*
homeassistant/components/smtp/notify.py
homeassistant/components/snapcast/media_player.py
homeassistant/components/snmp/*
@@ -648,15 +671,18 @@ omit =
homeassistant/components/speedtestdotnet/*
homeassistant/components/spider/*
homeassistant/components/spotcrime/sensor.py
homeassistant/components/spotify/__init__.py
homeassistant/components/spotify/media_player.py
homeassistant/components/squeezebox/*
homeassistant/components/starline/*
homeassistant/components/starlingbank/sensor.py
homeassistant/components/steam_online/sensor.py
homeassistant/components/stiebel_eltron/*
homeassistant/components/stookalert/*
homeassistant/components/streamlabswater/*
homeassistant/components/suez_water/*
homeassistant/components/supervisord/sensor.py
homeassistant/components/surepetcare/*.py
homeassistant/components/swiss_hydrological_data/sensor.py
homeassistant/components/swiss_public_transport/sensor.py
homeassistant/components/swisscom/device_tracker.py
@@ -674,6 +700,7 @@ omit =
homeassistant/components/tado/device_tracker.py
homeassistant/components/tahoma/*
homeassistant/components/tank_utility/sensor.py
homeassistant/components/tankerkoenig/*
homeassistant/components/tapsaff/binary_sensor.py
homeassistant/components/tautulli/sensor.py
homeassistant/components/ted5000/sensor.py
@@ -684,7 +711,14 @@ omit =
homeassistant/components/telnet/switch.py
homeassistant/components/temper/sensor.py
homeassistant/components/tensorflow/image_processing.py
homeassistant/components/tesla/*
homeassistant/components/tesla/__init__.py
homeassistant/components/tesla/binary_sensor.py
homeassistant/components/tesla/climate.py
homeassistant/components/tesla/const.py
homeassistant/components/tesla/device_tracker.py
homeassistant/components/tesla/lock.py
homeassistant/components/tesla/sensor.py
homeassistant/components/tesla/switch.py
homeassistant/components/tfiac/climate.py
homeassistant/components/thermoworks_smoke/sensor.py
homeassistant/components/thethingsnetwork/*
@@ -695,6 +729,7 @@ omit =
homeassistant/components/tikteck/light.py
homeassistant/components/tile/device_tracker.py
homeassistant/components/time_date/sensor.py
homeassistant/components/tmb/sensor.py
homeassistant/components/todoist/calendar.py
homeassistant/components/todoist/const.py
homeassistant/components/tof/sensor.py
@@ -703,8 +738,6 @@ omit =
homeassistant/components/torque/sensor.py
homeassistant/components/totalconnect/*
homeassistant/components/touchline/climate.py
homeassistant/components/tplink/device_tracker.py
homeassistant/components/tplink/light.py
homeassistant/components/tplink/switch.py
homeassistant/components/tplink_lte/*
homeassistant/components/traccar/device_tracker.py
@@ -726,10 +759,8 @@ omit =
homeassistant/components/twentemilieu/sensor.py
homeassistant/components/twilio_call/notify.py
homeassistant/components/twilio_sms/notify.py
homeassistant/components/twitch/sensor.py
homeassistant/components/twitter/notify.py
homeassistant/components/ubee/device_tracker.py
homeassistant/components/uber/sensor.py
homeassistant/components/ubus/device_tracker.py
homeassistant/components/ue_smart_radio/media_player.py
homeassistant/components/unifiled/*
@@ -745,11 +776,11 @@ omit =
homeassistant/components/velbus/climate.py
homeassistant/components/velbus/const.py
homeassistant/components/velbus/cover.py
homeassistant/components/velbus/light.py
homeassistant/components/velbus/sensor.py
homeassistant/components/velbus/switch.py
homeassistant/components/velux/*
homeassistant/components/venstar/climate.py
homeassistant/components/vera/*
homeassistant/components/verisure/*
homeassistant/components/versasense/*
homeassistant/components/vesync/__init__.py
@@ -758,8 +789,10 @@ omit =
homeassistant/components/vesync/switch.py
homeassistant/components/viaggiatreno/sensor.py
homeassistant/components/vicare/*
homeassistant/components/vilfo/__init__.py
homeassistant/components/vilfo/sensor.py
homeassistant/components/vilfo/const.py
homeassistant/components/vivotek/camera.py
homeassistant/components/vizio/media_player.py
homeassistant/components/vlc/media_player.py
homeassistant/components/vlc_telnet/media_player.py
homeassistant/components/volkszaehler/sensor.py
@@ -805,7 +838,6 @@ omit =
homeassistant/components/zestimate/sensor.py
homeassistant/components/zha/__init__.py
homeassistant/components/zha/api.py
homeassistant/components/zha/const.py
homeassistant/components/zha/core/channels/*
homeassistant/components/zha/core/const.py
homeassistant/components/zha/core/device.py
@@ -813,7 +845,7 @@ omit =
homeassistant/components/zha/core/helpers.py
homeassistant/components/zha/core/patches.py
homeassistant/components/zha/core/registries.py
homeassistant/components/zha/device_entity.py
homeassistant/components/zha/core/typing.py
homeassistant/components/zha/entity.py
homeassistant/components/zha/light.py
homeassistant/components/zha/sensor.py

View File

@@ -1,4 +1,3 @@
// See https://aka.ms/vscode-remote/devcontainer.json for format details.
{
"name": "Home Assistant Dev",
"context": "..",

View File

@@ -1,47 +0,0 @@
<!-- READ THIS FIRST:
- If you need additional help with this template please refer to https://www.home-assistant.io/help/reporting_issues/
- Make sure you are running the latest version of Home Assistant before reporting an issue: https://github.com/home-assistant/home-assistant/releases
- Frontend issues should be submitted to the home-assistant-polymer repository: https://github.com/home-assistant/home-assistant-polymer/issues
- iOS issues should be submitted to the home-assistant-iOS repository: https://github.com/home-assistant/home-assistant-iOS/issues
- Do not report issues for integrations if you are using custom integration: files in <config-dir>/custom_components
- This is for bugs only. Feature and enhancement requests should go in our community forum: https://community.home-assistant.io/c/feature-requests
- Provide as many details as possible. Paste logs, configuration sample and code into the backticks. Do not delete any text from this template!
-->
**Home Assistant release with the issue:**
<!--
- Frontend -> Developer tools -> Info
- Or use this command: hass --version
-->
**Last working Home Assistant release (if known):**
**Operating environment (Hass.io/Docker/Windows/etc.):**
<!--
Please provide details about your environment.
-->
**Integration:**
<!--
Please add the link to the documentation at https://www.home-assistant.io/integrations/ of the integration in question.
-->
**Description of problem:**
**Problem-relevant `configuration.yaml` entries and (fill out even if it seems unimportant):**
```yaml
```
**Traceback (if applicable):**
```
```
**Additional information:**

53
.github/ISSUE_TEMPLATE/BUG_REPORT.md vendored Normal file
View File

@@ -0,0 +1,53 @@
---
name: Report a bug with Home Assistant
about: Report an issue with Home Assistant
---
<!-- READ THIS FIRST:
- If you need additional help with this template, please refer to https://www.home-assistant.io/help/reporting_issues/
- Make sure you are running the latest version of Home Assistant before reporting an issue: https://github.com/home-assistant/home-assistant/releases
- Do not report issues for integrations if you are using custom components or integrations.
- Provide as many details as possible. Paste logs, configuration samples and code into the backticks.
DO NOT DELETE ANY TEXT from this template! Otherwise, your issue may be closed without comment.
-->
## The problem
<!--
Describe the issue you are experiencing here to communicate to the
maintainers. Tell us what you were trying to do and what happened instead.
-->
## Environment
<!--
Provide details about the versions you are using, which helps us to reproduce
and find the issue quicker. Version information is found in the
Home Assistant frontend: Developer tools -> Info.
-->
- Home Assistant release with the issue:
- Last working Home Assistant release (if known):
- Operating environment (Hass.io/Docker/Windows/etc.):
- Integration causing this issue:
- Link to integration documentation on our website:
## Problem-relevant `configuration.yaml`
<!--
An example configuration that caused the problem for you. Fill this out even
if it seems unimportant to you. Please be sure to remove personal information
like passwords, private URLs and other credentials.
-->
```yaml
```
## Traceback/Error logs
<!--
If you come across any trace or error logs, please provide them.
-->
```txt
```
## Additional information

View File

@@ -1,52 +0,0 @@
---
name: Bug report
about: Create a report to help us improve
---
<!-- READ THIS FIRST:
- If you need additional help with this template please refer to https://www.home-assistant.io/help/reporting_issues/
- Make sure you are running the latest version of Home Assistant before reporting an issue: https://github.com/home-assistant/home-assistant/releases
- Frontend issues should be submitted to the home-assistant-polymer repository: https://github.com/home-assistant/home-assistant-polymer/issues
- iOS issues should be submitted to the home-assistant-iOS repository: https://github.com/home-assistant/home-assistant-iOS/issues
- Do not report issues for integrations if you are using a custom integration: files in <config-dir>/custom_components
- This is for bugs only. Feature and enhancement requests should go in our community forum: https://community.home-assistant.io/c/feature-requests
- Provide as many details as possible. Paste logs, configuration sample and code into the backticks. Do not delete any text from this template!
-->
**Home Assistant release with the issue:**
<!--
- Frontend -> Developer tools -> Info
- Or use this command: hass --version
-->
**Last working Home Assistant release (if known):**
**Operating environment (Hass.io/Docker/Windows/etc.):**
<!--
Please provide details about your environment.
-->
**Integration:**
<!--
Please add the link to the documentation at https://www.home-assistant.io/integrations/ of the integration in question.
-->
**Description of problem:**
**Problem-relevant `configuration.yaml` entries and (fill out even if it seems unimportant):**
```yaml
```
**Traceback (if applicable):**
```
```
**Additional information:**

17
.github/ISSUE_TEMPLATE/config.yml vendored Normal file
View File

@@ -0,0 +1,17 @@
blank_issues_enabled: false
contact_links:
- name: Report a bug with the UI, Frontend or Lovelace
url: https://github.com/home-assistant/frontend/issues
about: This is the issue tracker for our backend. Please report issues with the UI in the frontend repository.
- name: Report incorrect or missing information on our website
url: https://github.com/home-assistant/home-assistant.io/issues
about: Our documentation has its own issue tracker. Please report issues with the website there.
- name: I have a question or need support
url: https://www.home-assistant.io/help
about: We use GitHub for tracking bugs, check our website for resources on getting help.
- name: Feature Request
url: https://community.home-assistant.io/c/feature-requests
about: Please use our Community Forum for making feature requests.
- name: I'm unsure where to go
url: https://www.home-assistant.io/join-chat
about: If you are unsure where to go, then joining our chat is recommended; Just ask!

View File

@@ -1,35 +1,109 @@
## Breaking Change:
<!-- What is breaking and why we have to break it. Remove this section only if it was NOT a breaking change. -->
## Description:
<!--
You are amazing! Thanks for contributing to our project!
Please, DO NOT DELETE ANY TEXT from this template! (unless instructed).
-->
## Breaking change
<!--
If your PR contains a breaking change for existing users, it is important
to tell them what breaks, how to make it work again and why we did this.
This piece of text is published with the release notes, so it helps if you
write it towards our users, not us.
Note: Remove this section if this PR is NOT a breaking change.
-->
**Related issue (if applicable):** fixes #<home-assistant issue number goes here>
## Proposed change
<!--
Describe the big picture of your changes here to communicate to the
maintainers why we should accept this pull request. If it fixes a bug
or resolves a feature request, be sure to link to that issue in the
additional information section.
-->
**Pull request with documentation for [home-assistant.io](https://github.com/home-assistant/home-assistant.io) (if applicable):** home-assistant/home-assistant.io#<home-assistant.io PR number goes here>
## Example entry for `configuration.yaml` (if applicable):
## Type of change
<!--
What type of change does your PR introduce to Home Assistant?
NOTE: Please, check only 1! box!
If your PR requires multiple boxes to be checked, you'll most likely need to
split it into multiple PRs. This makes things easier and faster to code review.
-->
- [ ] Dependency upgrade
- [ ] Bugfix (non-breaking change which fixes an issue)
- [ ] New integration (thank you!)
- [ ] New feature (which adds functionality to an existing integration)
- [ ] Breaking change (fix/feature causing existing functionality to break)
- [ ] Code quality improvements to existing code or addition of tests
## Example entry for `configuration.yaml`:
<!--
Supplying a configuration snippet, makes it easier for a maintainer to test
your PR. Furthermore, for new integrations, it gives an impression of how
the configuration would look like.
Note: Remove this section if this PR does not have an example entry.
-->
```yaml
# Example configuration.yaml
```
## Checklist:
- [ ] The code change is tested and works locally.
- [ ] Local tests pass with `tox`. **Your PR cannot be merged unless tests pass**
- [ ] There is no commented out code in this PR.
- [ ] I have followed the [development checklist][dev-checklist]
## Additional information
<!--
Details are important, and help maintainers processing your PR.
Please be sure to fill out additional details, if applicable.
-->
- This PR fixes or closes issue: fixes #
- This PR is related to issue:
- Link to documentation pull request:
## Checklist
<!--
Put an `x` in the boxes that apply. You can also fill these out after
creating the PR. If you're unsure about any of them, don't hesitate to ask.
We're here to help! This is simply a reminder of what we are going to look
for before merging your code.
-->
- [ ] The code change is tested and works locally.
- [ ] Local tests pass. **Your PR cannot be merged unless tests pass**
- [ ] There is no commented out code in this PR.
- [ ] I have followed the [development checklist][dev-checklist]
- [ ] The code has been formatted using Black (`black --fast homeassistant tests`)
- [ ] Tests have been added to verify that the new code works.
If user exposed functionality or configuration variables are added/changed:
- [ ] Documentation added/updated in [home-assistant.io](https://github.com/home-assistant/home-assistant.io)
- [ ] Documentation added/updated for [www.home-assistant.io][docs-repository]
If the code communicates with devices, web services, or third-party tools:
- [ ] [_The manifest file_][manifest-docs] has all fields filled out correctly. Update and include derived files by running `python3 -m script.hassfest`.
- [ ] New or updated dependencies have been added to `requirements_all.txt` by running `python3 -m script.gen_requirements_all`.
- [ ] Untested files have been added to `.coveragerc`.
If the code does not interact with devices:
- [ ] Tests have been added to verify that the new code works.
- [ ] The [manifest file][manifest-docs] has all fields filled out correctly.
Updated and included derived files by running: `python3 -m script.hassfest`.
- [ ] New or updated dependencies have been added to `requirements_all.txt`.
Updated by running `python3 -m script.gen_requirements_all`.
- [ ] Untested files have been added to `.coveragerc`.
The integration reached or maintains the following [Integration Quality Scale][quality-scale]:
<!--
The Integration Quality Scale scores an integration on the code quality
and user experience. Each level of the quality scale consists of a list
of requirements. We highly recommend getting your integration scored!
-->
- [ ] No score or internal
- [ ] 🥈 Silver
- [ ] 🥇 Gold
- [ ] 🏆 Platinum
<!--
Thank you for contributing <3
Below, some useful links you could explore:
-->
[dev-checklist]: https://developers.home-assistant.io/docs/en/development_checklist.html
[manifest-docs]: https://developers.home-assistant.io/docs/en/creating_integration_manifest.html
[quality-scale]: https://developers.home-assistant.io/docs/en/next/integration_quality_scale_index.html
[docs-repository]: https://github.com/home-assistant/home-assistant.io

12
.github/stale.yml vendored
View File

@@ -52,4 +52,14 @@ markComment: >
limitPerRun: 30
# Limit to only `issues` or `pulls`
only: issues
# only: issues
# Handle pull requests a little bit faster and with an adjusted comment.
pulls:
daysUntilStale: 30
markComment: >
There hasn't been any activity on this pull request recently. This pull
request has been automatically marked as stale because of that and will
be closed if no further activity occurs within 7 days.
Thank you for your contributions.

View File

@@ -1,2 +0,0 @@
python:
enabled: true

View File

@@ -1,51 +0,0 @@
# This configuration includes the full set of hooks we use. In
# addition to the defaults (see .pre-commit-config.yaml), this
# includes hooks that require our development and test dependencies
# installed and the virtualenv containing them active by the time
# pre-commit runs to produce correct results.
#
# If this is not a problem for your workflow, using this config is
# recommended, install it with
# pre-commit install --config .pre-commit-config-all.yaml
# Otherwise, see the default .pre-commit-config.yaml for a lighter one.
repos:
- repo: https://github.com/psf/black
rev: 19.10b0
hooks:
- id: black
args:
- --safe
- --quiet
files: ^((homeassistant|script|tests)/.+)?[^/]+\.py$
- repo: https://github.com/PyCQA/flake8
rev: 3.7.9
hooks:
- id: flake8
additional_dependencies:
- flake8-docstrings==1.5.0
- pydocstyle==4.0.1
files: ^(homeassistant|script|tests)/.+\.py$
- repo: https://github.com/PyCQA/bandit
rev: 1.6.2
hooks:
- id: bandit
args:
- --quiet
- --format=custom
- --configfile=tests/bandit.yaml
files: ^(homeassistant|script|tests)/.+\.py$
# Using a local "system" mypy instead of the mypy hook, because its
# results depend on what is installed. And the mypy hook runs in a
# virtualenv of its own, meaning we'd need to install and maintain
# another set of our dependencies there... no. Use the "system" one
# and reuse the environment that is set up anyway already instead.
- repo: local
hooks:
- id: mypy
name: mypy
entry: mypy
language: system
types: [python]
require_serial: true
files: ^homeassistant/.+\.py$

View File

@@ -1,28 +1,30 @@
# This configuration includes the default, minimal set of hooks to be
# run on all commits. It requires no specific setup and one can just
# start using pre-commit with it.
#
# See .pre-commit-config-all.yaml for a more complete one that comes
# with a better coverage at the cost of some specific setup needed.
repos:
- repo: https://github.com/psf/black
- repo: https://github.com/psf/black
rev: 19.10b0
hooks:
- id: black
- id: black
args:
- --safe
- --quiet
files: ^((homeassistant|script|tests)/.+)?[^/]+\.py$
- repo: https://gitlab.com/pycqa/flake8
- repo: https://github.com/codespell-project/codespell
rev: v1.16.0
hooks:
- id: codespell
args:
- --ignore-words-list=hass,alot,datas,dof,dur,farenheit,hist,iff,ines,ist,lightsensor,mut,nd,pres,referer,ser,serie,te,technik,ue,uint,visability,wan,wanna,withing
- --skip="./.*,*.json"
- --quiet-level=2
exclude_types: [json]
- repo: https://gitlab.com/pycqa/flake8
rev: 3.7.9
hooks:
- id: flake8
- id: flake8
additional_dependencies:
- flake8-docstrings==1.5.0
- pydocstyle==4.0.1
- pydocstyle==5.0.2
files: ^(homeassistant|script|tests)/.+\.py$
- repo: https://github.com/PyCQA/bandit
- repo: https://github.com/PyCQA/bandit
rev: 1.6.2
hooks:
- id: bandit
@@ -31,3 +33,29 @@ repos:
- --format=custom
- --configfile=tests/bandit.yaml
files: ^(homeassistant|script|tests)/.+\.py$
- repo: https://github.com/pre-commit/mirrors-isort
rev: v4.3.21
hooks:
- id: isort
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.4.0
hooks:
- id: check-json
- id: no-commit-to-branch
args:
- --branch=dev
- --branch=master
- --branch=rc
- repo: local
hooks:
# Run mypy through our wrapper script in order to get the possible
# pyenv and/or virtualenv activated; it may not have been e.g. if
# committing from a GUI tool that was not launched from an activated
# shell.
- id: mypy
name: mypy
entry: script/run-in-env.sh mypy
language: script
types: [python]
require_serial: true
files: ^homeassistant/.+\.py$

View File

@@ -4,7 +4,7 @@ build:
image: latest
python:
version: 3.6
version: 3.7
setup_py_install: true
requirements_file: requirements_docs.txt

View File

@@ -1,9 +1,7 @@
sudo: false
dist: xenial
dist: bionic
addons:
apt:
sources:
- sourceline: "ppa:jonathonf/ffmpeg-4"
packages:
- libudev-dev
- libavformat-dev
@@ -16,15 +14,13 @@ addons:
matrix:
fast_finish: true
include:
- python: "3.6.1"
- python: "3.7.0"
env: TOXENV=lint
- python: "3.6.1"
- python: "3.7.0"
env: TOXENV=pylint PYLINT_ARGS=--jobs=0 TRAVIS_WAIT=30
- python: "3.6.1"
- python: "3.7.0"
env: TOXENV=typing
- python: "3.6.1"
env: TOXENV=py36
- python: "3.7"
- python: "3.7.0"
env: TOXENV=py37
cache:

View File

@@ -23,6 +23,7 @@ homeassistant/components/alpha_vantage/* @fabaff
homeassistant/components/amazon_polly/* @robbiet480
homeassistant/components/ambiclimate/* @danielhiversen
homeassistant/components/ambient_station/* @bachya
homeassistant/components/amcrest/* @pnbruckner
homeassistant/components/androidtv/* @JeffLIrion
homeassistant/components/apache_kafka/* @bachya
homeassistant/components/api/* @home-assistant/core
@@ -34,11 +35,13 @@ homeassistant/components/arest/* @fabaff
homeassistant/components/asuswrt/* @kennedyshead
homeassistant/components/aten_pe/* @mtdcr
homeassistant/components/atome/* @baqs
homeassistant/components/august/* @bdraco
homeassistant/components/aurora_abb_powerone/* @davet2001
homeassistant/components/auth/* @home-assistant/core
homeassistant/components/automatic/* @armills
homeassistant/components/automation/* @home-assistant/core
homeassistant/components/avea/* @pattyland
homeassistant/components/avri/* @timvancann
homeassistant/components/awair/* @danielsjf
homeassistant/components/aws/* @awarecan @robbiet480
homeassistant/components/axis/* @kane610
@@ -49,8 +52,10 @@ homeassistant/components/bitcoin/* @fabaff
homeassistant/components/bizkaibus/* @UgaitzEtxebarria
homeassistant/components/blink/* @fronzbot
homeassistant/components/bmw_connected_drive/* @gerard33
homeassistant/components/bom/* @maddenp
homeassistant/components/braviatv/* @robbiet480
homeassistant/components/broadlink/* @danielhiversen @felipediel
homeassistant/components/brother/* @bieniu
homeassistant/components/brunt/* @eavanvalkenburg
homeassistant/components/bt_smarthub/* @jxwolstenholme
homeassistant/components/buienradar/* @mjj4791 @ties
@@ -58,7 +63,6 @@ homeassistant/components/cert_expiry/* @Cereal2nd @jjlawren
homeassistant/components/cisco_ios/* @fbradyirl
homeassistant/components/cisco_mobility_express/* @fbradyirl
homeassistant/components/cisco_webex_teams/* @fbradyirl
homeassistant/components/ciscospark/* @fbradyirl
homeassistant/components/cloud/* @home-assistant/cloud
homeassistant/components/cloudflare/* @ludeeus
homeassistant/components/comfoconnect/* @michaelarnauts
@@ -66,6 +70,7 @@ homeassistant/components/config/* @home-assistant/core
homeassistant/components/configurator/* @home-assistant/core
homeassistant/components/conversation/* @home-assistant/core
homeassistant/components/coolmaster/* @OnFreund
homeassistant/components/coronavirus/* @home_assistant/core
homeassistant/components/counter/* @fabaff
homeassistant/components/cover/* @home-assistant/core
homeassistant/components/cpuspeed/* @fabaff
@@ -75,19 +80,25 @@ homeassistant/components/darksky/* @fabaff
homeassistant/components/deconz/* @kane610
homeassistant/components/delijn/* @bollewolle
homeassistant/components/demo/* @home-assistant/core
homeassistant/components/derivative/* @afaucogney
homeassistant/components/device_automation/* @home-assistant/core
homeassistant/components/digital_ocean/* @fabaff
homeassistant/components/directv/* @ctalkington
homeassistant/components/discogs/* @thibmaek
homeassistant/components/doorbird/* @oblogic7
homeassistant/components/dsmr_reader/* @depl0y
homeassistant/components/dweet/* @fabaff
homeassistant/components/dynalite/* @ziv1234
homeassistant/components/dyson/* @etheralm
homeassistant/components/ecobee/* @marthoc
homeassistant/components/ecovacs/* @OverloadUT
homeassistant/components/edl21/* @mtdcr
homeassistant/components/egardia/* @jeroenterheerdt
homeassistant/components/eight_sleep/* @mezz64
homeassistant/components/elgato/* @frenck
homeassistant/components/elv/* @majuss
homeassistant/components/emby/* @mezz64
homeassistant/components/emulated_hue/* @NobleKangaroo
homeassistant/components/emoncms/* @borpin
homeassistant/components/enigma2/* @fbradyirl
homeassistant/components/enocean/* @bdurrer
homeassistant/components/entur_public_transport/* @hfurubotten
@@ -98,6 +109,7 @@ homeassistant/components/eq3btsmart/* @rytilahti
homeassistant/components/esphome/* @OttoWinter
homeassistant/components/essent/* @TheLastProject
homeassistant/components/evohome/* @zxdavb
homeassistant/components/ezviz/* @baqs
homeassistant/components/fastdotcom/* @rohankapoorcom
homeassistant/components/file/* @fabaff
homeassistant/components/filter/* @dgomes
@@ -113,11 +125,14 @@ homeassistant/components/foursquare/* @robbiet480
homeassistant/components/freebox/* @snoof85
homeassistant/components/fronius/* @nielstron
homeassistant/components/frontend/* @home-assistant/frontend
homeassistant/components/garmin_connect/* @cyberjunky
homeassistant/components/gdacs/* @exxamalte
homeassistant/components/gearbest/* @HerrHofrat
homeassistant/components/geniushub/* @zxdavb
homeassistant/components/geo_rss_events/* @exxamalte
homeassistant/components/geonetnz_quakes/* @exxamalte
homeassistant/components/geonetnz_volcano/* @exxamalte
homeassistant/components/gios/* @bieniu
homeassistant/components/gitter/* @fabaff
homeassistant/components/glances/* @fabaff @engrbm87
homeassistant/components/gntp/* @robbiet480
@@ -126,6 +141,8 @@ homeassistant/components/google_cloud/* @lufton
homeassistant/components/google_translate/* @awarecan
homeassistant/components/google_travel_time/* @robbiet480
homeassistant/components/gpsd/* @fabaff
homeassistant/components/greeneye_monitor/* @jkeljo
homeassistant/components/griddy/* @bdraco
homeassistant/components/group/* @home-assistant/core
homeassistant/components/growatt_server/* @indykoning
homeassistant/components/gtfs/* @robbiet480
@@ -138,7 +155,6 @@ homeassistant/components/hikvision/* @mezz64
homeassistant/components/hikvisioncam/* @fbradyirl
homeassistant/components/hisense_aehw4a1/* @bannhead
homeassistant/components/history/* @home-assistant/core
homeassistant/components/history_graph/* @andrey-git
homeassistant/components/hive/* @Rendili @KJonline
homeassistant/components/homeassistant/* @home-assistant/core
homeassistant/components/homekit_controller/* @Jc2k
@@ -150,7 +166,9 @@ homeassistant/components/http/* @home-assistant/core
homeassistant/components/huawei_lte/* @scop
homeassistant/components/huawei_router/* @abmantis
homeassistant/components/hue/* @balloob
homeassistant/components/iammeter/* @lewei50
homeassistant/components/iaqualink/* @flz
homeassistant/components/icloud/* @Quentame
homeassistant/components/ign_sismologia/* @exxamalte
homeassistant/components/incomfort/* @zxdavb
homeassistant/components/influxdb/* @fabaff
@@ -161,9 +179,10 @@ homeassistant/components/input_select/* @home-assistant/core
homeassistant/components/input_text/* @home-assistant/core
homeassistant/components/integration/* @dgomes
homeassistant/components/intent/* @home-assistant/core
homeassistant/components/intesishome/* @jnimmo
homeassistant/components/ios/* @robbiet480
homeassistant/components/iperf3/* @rohankapoorcom
homeassistant/components/ipma/* @dgomes
homeassistant/components/ipma/* @dgomes @abmantis
homeassistant/components/iqvia/* @bachya
homeassistant/components/irish_rail_transport/* @ttroy50
homeassistant/components/izone/* @Swamp-Ig
@@ -172,17 +191,18 @@ homeassistant/components/juicenet/* @jesserockz
homeassistant/components/kaiterra/* @Michsior14
homeassistant/components/keba/* @dannerph
homeassistant/components/keenetic_ndms2/* @foxel
homeassistant/components/kef/* @basnijholt
homeassistant/components/keyboard_remote/* @bendavid
homeassistant/components/knx/* @Julius2342
homeassistant/components/kodi/* @armills
homeassistant/components/konnected/* @heythisisnate
homeassistant/components/konnected/* @heythisisnate @kit-klein
homeassistant/components/lametric/* @robbiet480
homeassistant/components/launch_library/* @ludeeus
homeassistant/components/lcn/* @alengwenus
homeassistant/components/life360/* @pnbruckner
homeassistant/components/linky/* @Quentame
homeassistant/components/linux_battery/* @fabaff
homeassistant/components/liveboxplaytv/* @pschmitt
homeassistant/components/local_ip/* @issacg
homeassistant/components/logger/* @home-assistant/core
homeassistant/components/logi_circle/* @evanjd
homeassistant/components/lovelace/* @home-assistant/frontend
@@ -194,13 +214,16 @@ homeassistant/components/mastodon/* @fabaff
homeassistant/components/matrix/* @tinloaf
homeassistant/components/mcp23017/* @jardiamj
homeassistant/components/mediaroom/* @dgomes
homeassistant/components/melcloud/* @vilppuvuorinen
homeassistant/components/melissa/* @kennedyshead
homeassistant/components/met/* @danielhiversen
homeassistant/components/meteo_france/* @victorcerutti @oncleben31
homeassistant/components/meteo_france/* @victorcerutti @oncleben31 @Quentame
homeassistant/components/meteoalarm/* @rolfberkenbosch
homeassistant/components/miflora/* @danielhiversen @ChristianKuehnel
homeassistant/components/mikrotik/* @engrbm87
homeassistant/components/mill/* @danielhiversen
homeassistant/components/min_max/* @fabaff
homeassistant/components/minecraft_server/* @elmurato
homeassistant/components/minio/* @tkislan
homeassistant/components/mobile_app/* @robbiet480
homeassistant/components/modbus/* @adamchengtkc
@@ -212,9 +235,11 @@ homeassistant/components/msteams/* @peroyvind
homeassistant/components/mysensors/* @MartinHjelmare
homeassistant/components/mystrom/* @fabaff
homeassistant/components/neato/* @dshokouhi @Santobert
homeassistant/components/nederlandse_spoorwegen/* @YarmoM
homeassistant/components/nello/* @pschmitt
homeassistant/components/ness_alarm/* @nickw444
homeassistant/components/nest/* @awarecan
homeassistant/components/netatmo/* @cgtobi
homeassistant/components/netdata/* @fabaff
homeassistant/components/nextbus/* @vividboarder
homeassistant/components/nilu/* @hfurubotten
@@ -232,18 +257,20 @@ homeassistant/components/obihai/* @dshokouhi
homeassistant/components/ohmconnect/* @robbiet480
homeassistant/components/ombi/* @larssont
homeassistant/components/onboarding/* @home-assistant/core
homeassistant/components/onewire/* @garbled1
homeassistant/components/opentherm_gw/* @mvn23
homeassistant/components/openuv/* @bachya
homeassistant/components/openweathermap/* @fabaff
homeassistant/components/opnsense/* @mtreinish
homeassistant/components/orangepi_gpio/* @pascallj
homeassistant/components/oru/* @bvlaicu
homeassistant/components/owlet/* @oblogic7
homeassistant/components/panel_custom/* @home-assistant/frontend
homeassistant/components/panel_iframe/* @home-assistant/frontend
homeassistant/components/pcal9535a/* @Shulyaka
homeassistant/components/persistent_notification/* @home-assistant/core
homeassistant/components/philips_js/* @elupus
homeassistant/components/pi_hole/* @fabaff @johnluetke
homeassistant/components/pilight/* @trekky12
homeassistant/components/plaato/* @JohNan
homeassistant/components/plant/* @ChristianKuehnel
homeassistant/components/plex/* @jjlawren
@@ -257,35 +284,46 @@ homeassistant/components/pvoutput/* @fabaff
homeassistant/components/qld_bushfire/* @exxamalte
homeassistant/components/qnap/* @colinodell
homeassistant/components/quantum_gateway/* @cisasteelersfan
homeassistant/components/qvr_pro/* @oblogic7
homeassistant/components/qwikswitch/* @kellerza
homeassistant/components/rainbird/* @konikvranik
homeassistant/components/raincloud/* @vanstinator
homeassistant/components/rainforest_eagle/* @gtdiehl
homeassistant/components/rainforest_eagle/* @gtdiehl @jcalbert
homeassistant/components/rainmachine/* @bachya
homeassistant/components/random/* @fabaff
homeassistant/components/repetier/* @MTrab
homeassistant/components/rfxtrx/* @danielhiversen
homeassistant/components/ring/* @balloob
homeassistant/components/rmvtransport/* @cgtobi
homeassistant/components/roku/* @ctalkington
homeassistant/components/roomba/* @pschmitt
homeassistant/components/safe_mode/* @home-assistant/core
homeassistant/components/saj/* @fredericvl
homeassistant/components/salt/* @bjornorri
homeassistant/components/samsungtv/* @escoand
homeassistant/components/scene/* @home-assistant/core
homeassistant/components/scrape/* @fabaff
homeassistant/components/script/* @home-assistant/core
homeassistant/components/search/* @home-assistant/core
homeassistant/components/sense/* @kbickar
homeassistant/components/sensibo/* @andrey-git
homeassistant/components/sentry/* @dcramer
homeassistant/components/serial/* @fabaff
homeassistant/components/seventeentrack/* @bachya
homeassistant/components/shell_command/* @home-assistant/core
homeassistant/components/shiftr/* @fabaff
homeassistant/components/shodan/* @fabaff
homeassistant/components/sighthound/* @robmarkcole
homeassistant/components/signal_messenger/* @bbernhard
homeassistant/components/simplisafe/* @bachya
homeassistant/components/sinch/* @bendikrb
homeassistant/components/sisyphus/* @jkeljo
homeassistant/components/slide/* @ualex73
homeassistant/components/sma/* @kellerza
homeassistant/components/smarthab/* @outadoc
homeassistant/components/smartthings/* @andrewsayre
homeassistant/components/smarty/* @z0mbieprocess
homeassistant/components/sms/* @ocalvo
homeassistant/components/smtp/* @fabaff
homeassistant/components/solaredge_local/* @drobtravels @scheric
homeassistant/components/solarlog/* @Ernst79
@@ -296,15 +334,18 @@ homeassistant/components/songpal/* @rytilahti
homeassistant/components/spaceapi/* @fabaff
homeassistant/components/speedtestdotnet/* @rohankapoorcom
homeassistant/components/spider/* @peternijssen
homeassistant/components/spotify/* @frenck
homeassistant/components/sql/* @dgomes
homeassistant/components/starline/* @anonym-tsk
homeassistant/components/statistics/* @fabaff
homeassistant/components/stiebel_eltron/* @fucm
homeassistant/components/stookalert/* @fwestenberg
homeassistant/components/stream/* @hunterjm
homeassistant/components/stt/* @pvizeli
homeassistant/components/suez_water/* @ooii
homeassistant/components/sun/* @Swamp-Ig
homeassistant/components/supla/* @mwegrzynek
homeassistant/components/surepetcare/* @benleb
homeassistant/components/swiss_hydrological_data/* @fabaff
homeassistant/components/swiss_public_transport/* @fabaff
homeassistant/components/switchbot/* @danielhiversen
@@ -315,53 +356,59 @@ homeassistant/components/synology_srm/* @aerialls
homeassistant/components/syslog/* @fabaff
homeassistant/components/tado/* @michaelarnauts
homeassistant/components/tahoma/* @philklei
homeassistant/components/tankerkoenig/* @guillempages
homeassistant/components/tautulli/* @ludeeus
homeassistant/components/tellduslive/* @fredrike
homeassistant/components/template/* @PhracturedBlue
homeassistant/components/tesla/* @zabuldon
homeassistant/components/template/* @PhracturedBlue @tetienne
homeassistant/components/tesla/* @zabuldon @alandtse
homeassistant/components/tfiac/* @fredrike @mellado
homeassistant/components/thethingsnetwork/* @fabaff
homeassistant/components/threshold/* @fabaff
homeassistant/components/tibber/* @danielhiversen
homeassistant/components/tile/* @bachya
homeassistant/components/time_date/* @fabaff
homeassistant/components/tmb/* @alemuro
homeassistant/components/todoist/* @boralyl
homeassistant/components/toon/* @frenck
homeassistant/components/totalconnect/* @austinmroczek
homeassistant/components/tplink/* @rytilahti
homeassistant/components/traccar/* @ludeeus
homeassistant/components/tradfri/* @ggravlingen
homeassistant/components/trafikverket_train/* @endor-force
homeassistant/components/transmission/* @engrbm87 @JPHutchins
homeassistant/components/tts/* @robbiet480
homeassistant/components/tts/* @pvizeli
homeassistant/components/twentemilieu/* @frenck
homeassistant/components/twilio_call/* @robbiet480
homeassistant/components/twilio_sms/* @robbiet480
homeassistant/components/ubee/* @mzdrale
homeassistant/components/unifi/* @kane610
homeassistant/components/unifiled/* @florisvdk
homeassistant/components/upc_connect/* @pvizeli
homeassistant/components/upcloud/* @scop
homeassistant/components/updater/* @home-assistant/core
homeassistant/components/upnp/* @robbiet480
homeassistant/components/upnp/* @StevenLooman
homeassistant/components/uptimerobot/* @ludeeus
homeassistant/components/usgs_earthquakes_feed/* @exxamalte
homeassistant/components/utility_meter/* @dgomes
homeassistant/components/velbus/* @cereal2nd
homeassistant/components/velbus/* @Cereal2nd @brefra
homeassistant/components/velux/* @Julius2342
homeassistant/components/versasense/* @flamm3blemuff1n
homeassistant/components/version/* @fabaff
homeassistant/components/vesync/* @markperdue @webdjoe
homeassistant/components/vicare/* @oischinger
homeassistant/components/vilfo/* @ManneW
homeassistant/components/vivotek/* @HarlemSquirrel
homeassistant/components/vizio/* @raman325
homeassistant/components/vlc_telnet/* @rodripf
homeassistant/components/waqi/* @andrey-git
homeassistant/components/watson_tts/* @rutkai
homeassistant/components/weather/* @fabaff
homeassistant/components/weblink/* @home-assistant/core
homeassistant/components/webostv/* @bendavid
homeassistant/components/websocket_api/* @home-assistant/core
homeassistant/components/wemo/* @sqldiablo
homeassistant/components/withings/* @vangorra
homeassistant/components/wled/* @frenck
homeassistant/components/workday/* @fabaff
homeassistant/components/worldclock/* @fabaff
homeassistant/components/wwlln/* @bachya
homeassistant/components/xbox_live/* @MartinHjelmare

View File

@@ -4,7 +4,7 @@ Everybody is invited and welcome to contribute to Home Assistant. There is a lot
The process is straight-forward.
- Read [How to get faster PR reviews](https://github.com/kubernetes/community/blob/master/contributors/guide/pull-requests.md#best-practices-for-faster-reviews) by Kubernetes (but skip step 0)
- Read [How to get faster PR reviews](https://github.com/kubernetes/community/blob/master/contributors/guide/pull-requests.md#best-practices-for-faster-reviews) by Kubernetes (but skip step 0 and 1)
- Fork the Home Assistant [git repository](https://github.com/home-assistant/home-assistant).
- Write the code for your device, notification service, sensor, or IoT thing.
- Ensure tests work.
@@ -12,3 +12,7 @@ The process is straight-forward.
Still interested? Then you should take a peek at the [developer documentation](https://developers.home-assistant.io/) to get more details.
## Feature suggestions
If you want to suggest a new feature for Home Assistant (e.g., new integrations), please open a thread in our [Community Forum: Feature Requests](https://community.home-assistant.io/c/feature-requests).
We use [GitHub for tracking issues](https://github.com/home-assistant/home-assistant/issues), not for tracking feature requests.

View File

@@ -1,14 +1,7 @@
Home Assistant |Chat Status|
=================================================================================
Home Assistant is a home automation platform running on Python 3. It is able to track and control all devices at home and offer a platform for automating control.
To get started:
.. code:: bash
python3 -m pip install homeassistant
hass --open-ui
Open source home automation that puts local control and privacy first. Powered by a worldwide community of tinkerers and DIY enthusiasts. Perfect to run on a Raspberry Pi or a local server.
Check out `home-assistant.io <https://home-assistant.io>`__ for `a
demo <https://home-assistant.io/demo/>`__, `installation instructions <https://home-assistant.io/getting-started/>`__,

View File

@@ -14,8 +14,6 @@ pr:
resources:
containers:
- container: 36
image: homeassistant/ci-azure:3.6
- container: 37
image: homeassistant/ci-azure:3.7
repositories:
@@ -25,7 +23,7 @@ resources:
endpoint: 'home-assistant'
variables:
- name: PythonMain
value: '36'
value: '37'
- group: codecov
stages:
@@ -45,7 +43,11 @@ stages:
. venv/bin/activate
pip install -r requirements_test.txt -c homeassistant/package_constraints.txt
pre-commit install-hooks --config .pre-commit-config-all.yaml
pre-commit install-hooks
- script: |
. venv/bin/activate
pre-commit run codespell --all-files
displayName: 'Run codespell'
- script: |
. venv/bin/activate
pre-commit run flake8 --all-files
@@ -54,6 +56,14 @@ stages:
. venv/bin/activate
pre-commit run bandit --all-files
displayName: 'Run bandit'
- script: |
. venv/bin/activate
pre-commit run isort --all-files --show-diff-on-failure
displayName: 'Run isort'
- script: |
. venv/bin/activate
pre-commit run check-json --all-files
displayName: 'Run check-json'
- job: 'Validate'
pool:
vmImage: 'ubuntu-latest'
@@ -88,10 +98,10 @@ stages:
. venv/bin/activate
pip install -r requirements_test.txt -c homeassistant/package_constraints.txt
pre-commit install-hooks --config .pre-commit-config-all.yaml
pre-commit install-hooks
- script: |
. venv/bin/activate
pre-commit run black --all-files
pre-commit run black --all-files --show-diff-on-failure
displayName: 'Check Black formatting'
- stage: 'Tests'
@@ -104,8 +114,6 @@ stages:
strategy:
maxParallel: 3
matrix:
Python36:
python.container: '36'
Python37:
python.container: '37'
container: $[ variables['python.container'] ]
@@ -140,7 +148,7 @@ stages:
. venv/bin/activate
pytest --timeout=9 --durations=10 -n auto --dist=loadfile --cov homeassistant --cov-report html -qq -o console_output_style=count -p no:sugar tests
codecov --token $(codecovToken)
#codecov --token $(codecovToken)
script/check_dirty
displayName: 'Run pytest for python $(python.container) / coverage'
condition: and(succeeded(), eq(variables['python.container'], variables['PythonMain']))
@@ -186,8 +194,8 @@ stages:
. venv/bin/activate
pip install -e . -r requirements_test.txt -c homeassistant/package_constraints.txt
pre-commit install-hooks --config .pre-commit-config-all.yaml
pre-commit install-hooks
- script: |
. venv/bin/activate
pre-commit run --config .pre-commit-config-all.yaml mypy --all-files
pre-commit run mypy --all-files
displayName: 'Run mypy'

View File

@@ -14,7 +14,7 @@ schedules:
always: true
variables:
- name: versionBuilder
value: '6.3'
value: '6.9'
- group: docker
- group: github
- group: twine
@@ -41,9 +41,9 @@ stages:
jq curl
release="$(Build.SourceBranchName)"
created_by="$(curl -s https://api.github.com/repos/home-assistant/home-assistant/releases/tags/${release} | jq --raw-output '.author.login')"
created_by="$(curl -s https://api.github.com/repos/home-assistant/core/releases/tags/${release} | jq --raw-output '.author.login')"
if [[ "${created_by}" =~ ^(balloob|pvizeli|fabaff|robbiet480|bramkragten)$ ]]; then
if [[ "${created_by}" =~ ^(balloob|pvizeli|fabaff|robbiet480|bramkragten|frenck)$ ]]; then
exit 0
fi
@@ -94,7 +94,7 @@ stages:
buildMachine: 'raspberrypi2,raspberrypi3,raspberrypi4,odroid-xu,tinker'
aarch64:
buildArch: 'aarch64'
buildMachine: 'qemuarm-64,raspberrypi3-64,raspberrypi4-64,odroid-c2,orangepi-prime'
buildMachine: 'qemuarm-64,raspberrypi3-64,raspberrypi4-64,odroid-c2,odroid-n2'
steps:
- template: templates/azp-step-ha-version.yaml@azure
- script: |
@@ -163,7 +163,7 @@ stages:
git commit -am "Bump Home Assistant $version"
git push
displayName: 'Update version files'
displayName: "Update version files"
- job: 'ReleaseDocker'
pool:
vmImage: 'ubuntu-latest'

View File

@@ -30,7 +30,7 @@ jobs:
- template: templates/azp-job-wheels.yaml@azure
parameters:
builderVersion: '$(versionWheels)'
builderApk: 'build-base;cmake;git;linux-headers;bluez-dev;libffi-dev;openssl-dev;glib-dev;eudev-dev;libxml2-dev;libxslt-dev;libpng-dev;libjpeg-turbo-dev;tiff-dev;autoconf;automake;cups-dev;gmp-dev;mpfr-dev;mpc1-dev;ffmpeg-dev'
builderApk: 'build-base;cmake;git;linux-headers;bluez-dev;libffi-dev;openssl-dev;glib-dev;eudev-dev;libxml2-dev;libxslt-dev;libpng-dev;libjpeg-turbo-dev;tiff-dev;autoconf;automake;cups-dev;gmp-dev;mpfr-dev;mpc1-dev;ffmpeg-dev;gammu-dev'
builderPip: 'Cython;numpy'
wheelsRequirement: 'requirements_wheels.txt'
wheelsRequirementDiff: 'requirements_diff.txt'
@@ -40,7 +40,7 @@ jobs:
if [[ "$(Build.Reason)" =~ (Schedule|Manual) ]]; then
touch requirements_diff.txt
else
curl -s -o requirements_diff.txt https://raw.githubusercontent.com/home-assistant/home-assistant/master/requirements_all.txt
curl -s -o requirements_diff.txt https://raw.githubusercontent.com/home-assistant/core/master/requirements_all.txt
fi
requirement_files="requirements_wheels.txt requirements_diff.txt"
@@ -68,6 +68,7 @@ jobs:
sed -i "s|# face_recognition|face_recognition|g" ${requirement_file}
sed -i "s|# py_noaa|py_noaa|g" ${requirement_file}
sed -i "s|# bme680|bme680|g" ${requirement_file}
sed -i "s|# python-gammu|python-gammu|g" ${requirement_file}
if [[ "$(buildArch)" =~ arm ]]; then
sed -i "s|# VL53L1X|VL53L1X|g" ${requirement_file}

View File

@@ -13,4 +13,7 @@ coverage:
url: "secret:TgWDUM4Jw0w7wMJxuxNF/yhSOHglIo1fGwInJnRLEVPy2P2aLimkoK1mtKCowH5TFw+baUXVXT3eAqefbdvIuM8BjRR4aRji95C6CYyD0QHy4N8i7nn1SQkWDPpS8IthYTg07rUDF7s5guurkKv2RrgoCdnnqjAMSzHoExMOF7xUmblMdhBTWJgBpWEhASJy85w/xxjlsE1xoTkzeJu9Q67pTXtRcn+5kb5/vIzPSYg="
comment:
require_changes: yes
branches: master
layout: reach
branches:
- master
- !dev

Binary file not shown.

Before

Width:  |  Height:  |  Size: 139 KiB

After

Width:  |  Height:  |  Size: 108 KiB

View File

@@ -8,7 +8,6 @@ Loosely based on https://github.com/astropy/astropy/pull/347
import os
import warnings
__licence__ = 'BSD (3 clause)'

View File

@@ -17,11 +17,11 @@
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
#
import sys
import os
import inspect
import os
import sys
from homeassistant.const import __version__, __short_version__
from homeassistant.const import __short_version__, __version__
PROJECT_NAME = 'Home Assistant'
PROJECT_PACKAGE_NAME = 'homeassistant'

View File

@@ -1,22 +1,18 @@
"""Start Home Assistant."""
import argparse
import asyncio
import os
import platform
import subprocess
import sys
import threading
from typing import List, Dict, Any, TYPE_CHECKING
from typing import List
from homeassistant import monkey_patch
from homeassistant.const import __version__, REQUIRED_PYTHON_VER, RESTART_EXIT_CODE
if TYPE_CHECKING:
from homeassistant import core
from homeassistant.const import REQUIRED_PYTHON_VER, RESTART_EXIT_CODE, __version__
def set_loop() -> None:
"""Attempt to use different loop."""
import asyncio
from asyncio.events import BaseDefaultEventLoopPolicy
if sys.platform == "win32":
@@ -56,10 +52,8 @@ def ensure_config_path(config_dir: str) -> None:
if not os.path.isdir(config_dir):
if config_dir != config_util.get_default_config_dir():
print(
(
"Fatal Error: Specified configuration directory does "
"not exist {} "
).format(config_dir)
f"Fatal Error: Specified configuration directory {config_dir} "
"does not exist"
)
sys.exit(1)
@@ -67,10 +61,8 @@ def ensure_config_path(config_dir: str) -> None:
os.mkdir(config_dir)
except OSError:
print(
(
"Fatal Error: Unable to create default configuration "
"directory {} "
).format(config_dir)
"Fatal Error: Unable to create default configuration "
f"directory {config_dir}"
)
sys.exit(1)
@@ -79,27 +71,10 @@ def ensure_config_path(config_dir: str) -> None:
try:
os.mkdir(lib_dir)
except OSError:
print(
("Fatal Error: Unable to create library " "directory {} ").format(
lib_dir
)
)
print(f"Fatal Error: Unable to create library directory {lib_dir}")
sys.exit(1)
async def ensure_config_file(hass: "core.HomeAssistant", config_dir: str) -> str:
"""Ensure configuration file exists."""
import homeassistant.config as config_util
config_path = await config_util.async_ensure_config_exists(hass, config_dir)
if config_path is None:
print("Error getting configuration path")
sys.exit(1)
return config_path
def get_arguments() -> argparse.Namespace:
"""Get parsed passed in arguments."""
import homeassistant.config as config_util
@@ -116,7 +91,7 @@ def get_arguments() -> argparse.Namespace:
help="Directory that contains the Home Assistant configuration",
)
parser.add_argument(
"--demo-mode", action="store_true", help="Start Home Assistant in demo mode"
"--safe-mode", action="store_true", help="Start Home Assistant in safe mode"
)
parser.add_argument(
"--debug", action="store_true", help="Start Home Assistant in debug mode"
@@ -148,7 +123,7 @@ def get_arguments() -> argparse.Namespace:
"--log-file",
type=str,
default=None,
help="Log file to write to. If not set, CONFIG/home-assistant.log " "is used",
help="Log file to write to. If not set, CONFIG/home-assistant.log is used",
)
parser.add_argument(
"--log-no-color", action="store_true", help="Disable color logs"
@@ -217,7 +192,7 @@ def check_pid(pid_file: str) -> None:
except OSError:
# PID does not exist
return
print("Fatal Error: HomeAssistant is already running.")
print("Fatal Error: Home Assistant is already running.")
sys.exit(1)
@@ -261,35 +236,21 @@ def cmdline() -> List[str]:
async def setup_and_run_hass(config_dir: str, args: argparse.Namespace) -> int:
"""Set up HASS and run."""
from homeassistant import bootstrap, core
"""Set up Home Assistant and run."""
from homeassistant import bootstrap
hass = core.HomeAssistant()
hass = await bootstrap.async_setup_hass(
config_dir=config_dir,
verbose=args.verbose,
log_rotate_days=args.log_rotate_days,
log_file=args.log_file,
log_no_color=args.log_no_color,
skip_pip=args.skip_pip,
safe_mode=args.safe_mode,
)
if args.demo_mode:
config: Dict[str, Any] = {"frontend": {}, "demo": {}}
bootstrap.async_from_config_dict(
config,
hass,
config_dir=config_dir,
verbose=args.verbose,
skip_pip=args.skip_pip,
log_rotate_days=args.log_rotate_days,
log_file=args.log_file,
log_no_color=args.log_no_color,
)
else:
config_file = await ensure_config_file(hass, config_dir)
print("Config directory:", config_dir)
await bootstrap.async_from_config_file(
config_file,
hass,
verbose=args.verbose,
skip_pip=args.skip_pip,
log_rotate_days=args.log_rotate_days,
log_file=args.log_file,
log_no_color=args.log_no_color,
)
if hass is None:
return 1
if args.open_ui and hass.config.api is not None:
import webbrowser
@@ -345,11 +306,6 @@ def main() -> int:
"""Start Home Assistant."""
validate_python()
monkey_patch_needed = sys.version_info[:3] < (3, 6, 3)
if monkey_patch_needed and os.environ.get("HASS_NO_MONKEY") != "1":
monkey_patch.disable_c_asyncio()
monkey_patch.patch_weakref_tasks()
set_loop()
# Run a simple daemon runner process on Windows to handle restarts
@@ -372,7 +328,7 @@ def main() -> int:
return scripts.run(args.script)
config_dir = os.path.join(os.getcwd(), args.config)
config_dir = os.path.abspath(os.path.join(os.getcwd(), args.config))
ensure_config_path(config_dir)
# Daemon functions
@@ -383,13 +339,11 @@ def main() -> int:
if args.pid_file:
write_pid(args.pid_file)
from homeassistant.util.async_ import asyncio_run
exit_code = asyncio_run(setup_and_run_hass(config_dir, args))
exit_code = asyncio.run(setup_and_run_hass(config_dir, args))
if exit_code == RESTART_EXIT_CODE and not args.runner:
try_to_restart()
return exit_code # type: ignore
return exit_code
if __name__ == "__main__":

View File

@@ -1,21 +1,21 @@
"""Provide an authentication layer for Home Assistant."""
import asyncio
import logging
from collections import OrderedDict
from datetime import timedelta
import logging
from typing import Any, Dict, List, Optional, Tuple, cast
import jwt
from homeassistant import data_entry_flow
from homeassistant.auth.const import ACCESS_TOKEN_EXPIRATION
from homeassistant.core import callback, HomeAssistant
from homeassistant.core import HomeAssistant, callback
from homeassistant.util import dt as dt_util
from . import auth_store, models
from .const import GROUP_ID_ADMIN
from .mfa_modules import auth_mfa_module_from_config, MultiFactorAuthModule
from .providers import auth_provider_from_config, AuthProvider, LoginFlow
from .mfa_modules import MultiFactorAuthModule, auth_mfa_module_from_config
from .providers import AuthProvider, LoginFlow, auth_provider_from_config
EVENT_USER_ADDED = "user_added"
EVENT_USER_REMOVED = "user_removed"
@@ -67,6 +67,69 @@ async def auth_manager_from_config(
return manager
class AuthManagerFlowManager(data_entry_flow.FlowManager):
"""Manage authentication flows."""
def __init__(self, hass: HomeAssistant, auth_manager: "AuthManager"):
"""Init auth manager flows."""
super().__init__(hass)
self.auth_manager = auth_manager
async def async_create_flow(
self,
handler_key: Any,
*,
context: Optional[Dict[str, Any]] = None,
data: Optional[Dict[str, Any]] = None,
) -> data_entry_flow.FlowHandler:
"""Create a login flow."""
auth_provider = self.auth_manager.get_auth_provider(*handler_key)
if not auth_provider:
raise KeyError(f"Unknown auth provider {handler_key}")
return await auth_provider.async_login_flow(context)
async def async_finish_flow(
self, flow: data_entry_flow.FlowHandler, result: Dict[str, Any]
) -> Dict[str, Any]:
"""Return a user as result of login flow."""
flow = cast(LoginFlow, flow)
if result["type"] != data_entry_flow.RESULT_TYPE_CREATE_ENTRY:
return result
# we got final result
if isinstance(result["data"], models.User):
result["result"] = result["data"]
return result
auth_provider = self.auth_manager.get_auth_provider(*result["handler"])
if not auth_provider:
raise KeyError(f"Unknown auth provider {result['handler']}")
credentials = await auth_provider.async_get_or_create_credentials(
result["data"]
)
if flow.context.get("credential_only"):
result["result"] = credentials
return result
# multi-factor module cannot enabled for new credential
# which has not linked to a user yet
if auth_provider.support_mfa and not credentials.is_new:
user = await self.auth_manager.async_get_user_by_credentials(credentials)
if user is not None:
modules = await self.auth_manager.async_get_enabled_mfa(user)
if modules:
flow.user = user
flow.available_mfa_modules = modules
return await flow.async_step_select_mfa_module()
result["result"] = await self.auth_manager.async_get_or_create_user(credentials)
return result
class AuthManager:
"""Manage the authentication for Home Assistant."""
@@ -82,9 +145,7 @@ class AuthManager:
self._store = store
self._providers = providers
self._mfa_modules = mfa_modules
self.login_flow = data_entry_flow.FlowManager(
hass, self._async_create_login_flow, self._async_finish_login_flow
)
self.login_flow = AuthManagerFlowManager(hass, self)
@property
def auth_providers(self) -> List[AuthProvider]:
@@ -240,7 +301,7 @@ class AuthManager:
async def async_deactivate_user(self, user: models.User) -> None:
"""Deactivate a user."""
if user.is_owner:
raise ValueError("Unable to deactive the owner")
raise ValueError("Unable to deactivate the owner")
await self._store.async_deactivate_user(user)
async def async_remove_credentials(self, credentials: models.Credentials) -> None:
@@ -417,50 +478,6 @@ class AuthManager:
return refresh_token
async def _async_create_login_flow(
self, handler: _ProviderKey, *, context: Optional[Dict], data: Optional[Any]
) -> data_entry_flow.FlowHandler:
"""Create a login flow."""
auth_provider = self._providers[handler]
return await auth_provider.async_login_flow(context)
async def _async_finish_login_flow(
self, flow: LoginFlow, result: Dict[str, Any]
) -> Dict[str, Any]:
"""Return a user as result of login flow."""
if result["type"] != data_entry_flow.RESULT_TYPE_CREATE_ENTRY:
return result
# we got final result
if isinstance(result["data"], models.User):
result["result"] = result["data"]
return result
auth_provider = self._providers[result["handler"]]
credentials = await auth_provider.async_get_or_create_credentials(
result["data"]
)
if flow.context.get("credential_only"):
result["result"] = credentials
return result
# multi-factor module cannot enabled for new credential
# which has not linked to a user yet
if auth_provider.support_mfa and not credentials.is_new:
user = await self.async_get_user_by_credentials(credentials)
if user is not None:
modules = await self.async_get_enabled_mfa(user)
if modules:
flow.user = user
flow.available_mfa_modules = modules
return await flow.async_step_select_mfa_module()
result["result"] = await self.async_get_or_create_user(credentials)
return result
@callback
def _async_get_auth_provider(
self, credentials: models.Credentials

View File

@@ -11,7 +11,7 @@ from homeassistant.core import HomeAssistant, callback
from homeassistant.util import dt as dt_util
from . import models
from .const import GROUP_ID_ADMIN, GROUP_ID_USER, GROUP_ID_READ_ONLY
from .const import GROUP_ID_ADMIN, GROUP_ID_READ_ONLY, GROUP_ID_USER
from .permissions import PermissionLookup, system_policies
from .permissions.types import PolicyType

View File

@@ -1,4 +1,4 @@
"""Plugable auth modules for Home Assistant."""
"""Pluggable auth modules for Home Assistant."""
import importlib
import logging
import types
@@ -7,7 +7,7 @@ from typing import Any, Dict, Optional
import voluptuous as vol
from voluptuous.humanize import humanize_error
from homeassistant import requirements, data_entry_flow
from homeassistant import data_entry_flow, requirements
from homeassistant.const import CONF_ID, CONF_NAME, CONF_TYPE
from homeassistant.core import HomeAssistant
from homeassistant.exceptions import HomeAssistantError

View File

@@ -7,9 +7,9 @@ import voluptuous as vol
from homeassistant.core import HomeAssistant
from . import (
MultiFactorAuthModule,
MULTI_FACTOR_AUTH_MODULES,
MULTI_FACTOR_AUTH_MODULE_SCHEMA,
MULTI_FACTOR_AUTH_MODULES,
MultiFactorAuthModule,
SetupFlow,
)

View File

@@ -3,9 +3,9 @@
Sending HOTP through notify service
"""
import asyncio
import logging
from collections import OrderedDict
from typing import Any, Dict, Optional, List
import logging
from typing import Any, Dict, List, Optional
import attr
import voluptuous as vol
@@ -16,9 +16,9 @@ from homeassistant.exceptions import ServiceNotFound
from homeassistant.helpers import config_validation as cv
from . import (
MultiFactorAuthModule,
MULTI_FACTOR_AUTH_MODULES,
MULTI_FACTOR_AUTH_MODULE_SCHEMA,
MULTI_FACTOR_AUTH_MODULES,
MultiFactorAuthModule,
SetupFlow,
)
@@ -317,7 +317,7 @@ class NotifySetupFlow(SetupFlow):
async def async_step_setup(
self, user_input: Optional[Dict[str, str]] = None
) -> Dict[str, Any]:
"""Verify user can recevie one-time password."""
"""Verify user can receive one-time password."""
errors: Dict[str, str] = {}
hass = self._auth_module.hass

View File

@@ -1,7 +1,7 @@
"""Time-based One Time Password auth module."""
import asyncio
import logging
from io import BytesIO
import logging
from typing import Any, Dict, Optional, Tuple
import voluptuous as vol
@@ -10,9 +10,9 @@ from homeassistant.auth.models import User
from homeassistant.core import HomeAssistant
from . import (
MultiFactorAuthModule,
MULTI_FACTOR_AUTH_MODULES,
MULTI_FACTOR_AUTH_MODULE_SCHEMA,
MULTI_FACTOR_AUTH_MODULES,
MultiFactorAuthModule,
SetupFlow,
)

View File

@@ -1,5 +1,6 @@
"""Auth models."""
from datetime import datetime, timedelta
import secrets
from typing import Dict, List, NamedTuple, Optional
import uuid
@@ -9,7 +10,6 @@ from homeassistant.util import dt as dt_util
from . import permissions as perm_mdl
from .const import GROUP_ID_ADMIN
from .util import generate_secret
TOKEN_TYPE_NORMAL = "normal"
TOKEN_TYPE_SYSTEM = "system"
@@ -31,22 +31,28 @@ class User:
"""A user."""
name = attr.ib(type=Optional[str])
perm_lookup = attr.ib(type=perm_mdl.PermissionLookup, cmp=False)
perm_lookup = attr.ib(type=perm_mdl.PermissionLookup, eq=False, order=False)
id = attr.ib(type=str, factory=lambda: uuid.uuid4().hex)
is_owner = attr.ib(type=bool, default=False)
is_active = attr.ib(type=bool, default=False)
system_generated = attr.ib(type=bool, default=False)
groups = attr.ib(type=List[Group], factory=list, cmp=False)
groups = attr.ib(type=List[Group], factory=list, eq=False, order=False)
# List of credentials of a user.
credentials = attr.ib(type=List["Credentials"], factory=list, cmp=False)
credentials = attr.ib(type=List["Credentials"], factory=list, eq=False, order=False)
# Tokens associated with a user.
refresh_tokens = attr.ib(type=Dict[str, "RefreshToken"], factory=dict, cmp=False)
refresh_tokens = attr.ib(
type=Dict[str, "RefreshToken"], factory=dict, eq=False, order=False
)
_permissions = attr.ib(
type=Optional[perm_mdl.PolicyPermissions], init=False, cmp=False, default=None
type=Optional[perm_mdl.PolicyPermissions],
init=False,
eq=False,
order=False,
default=None,
)
@property
@@ -96,8 +102,8 @@ class RefreshToken:
)
id = attr.ib(type=str, factory=lambda: uuid.uuid4().hex)
created_at = attr.ib(type=datetime, factory=dt_util.utcnow)
token = attr.ib(type=str, factory=lambda: generate_secret(64))
jwt_key = attr.ib(type=str, factory=lambda: generate_secret(64))
token = attr.ib(type=str, factory=lambda: secrets.token_hex(64))
jwt_key = attr.ib(type=str, factory=lambda: secrets.token_hex(64))
last_used_at = attr.ib(type=Optional[datetime], default=None)
last_used_ip = attr.ib(type=Optional[str], default=None)

View File

@@ -5,13 +5,12 @@ from typing import Any, Callable, Optional
import voluptuous as vol
from .const import CAT_ENTITIES
from .models import PermissionLookup
from .types import PolicyType
from .entities import ENTITY_POLICY_SCHEMA, compile_entities
from .merge import merge_policies # noqa: F401
from .models import PermissionLookup
from .types import PolicyType
from .util import test_all
POLICY_SCHEMA = vol.Schema({vol.Optional(CAT_ENTITIES): ENTITY_POLICY_SCHEMA})
_LOGGER = logging.getLogger(__name__)

View File

@@ -4,11 +4,10 @@ from typing import Callable, Optional
import voluptuous as vol
from .const import SUBCAT_ALL, POLICY_READ, POLICY_CONTROL, POLICY_EDIT
from .const import POLICY_CONTROL, POLICY_EDIT, POLICY_READ, SUBCAT_ALL
from .models import PermissionLookup
from .types import CategoryType, SubCategoryDict, ValueType
from .util import SubCatLookupType, lookup_all, compile_policy
from .util import SubCatLookupType, compile_policy, lookup_all
SINGLE_ENTITY_SCHEMA = vol.Any(
True,

View File

@@ -1,7 +1,7 @@
"""Merging of policies."""
from typing import cast, Dict, List, Set
from typing import Dict, List, Set, cast
from .types import PolicyType, CategoryType
from .types import CategoryType, PolicyType
def merge_policies(policies: List[PolicyType]) -> PolicyType:

View File

@@ -1,5 +1,5 @@
"""System policies."""
from .const import CAT_ENTITIES, SUBCAT_ALL, POLICY_READ
from .const import CAT_ENTITIES, POLICY_READ, SUBCAT_ALL
ADMIN_POLICY = {CAT_ENTITIES: True}

View File

@@ -1,6 +1,5 @@
"""Helpers to deal with permissions."""
from functools import wraps
from typing import Callable, Dict, List, Optional, cast
from .const import SUBCAT_ALL

View File

@@ -8,8 +8,8 @@ import voluptuous as vol
from voluptuous.humanize import humanize_error
from homeassistant import data_entry_flow, requirements
from homeassistant.core import callback, HomeAssistant
from homeassistant.const import CONF_ID, CONF_NAME, CONF_TYPE
from homeassistant.core import HomeAssistant, callback
from homeassistant.exceptions import HomeAssistantError
from homeassistant.util import dt as dt_util
from homeassistant.util.decorator import Registry

View File

@@ -1,20 +1,18 @@
"""Auth provider that validates credentials via an external command."""
from typing import Any, Dict, Optional, cast
import asyncio.subprocess
import collections
import logging
import os
from typing import Any, Dict, Optional, cast
import voluptuous as vol
from homeassistant.exceptions import HomeAssistantError
from . import AuthProvider, AUTH_PROVIDER_SCHEMA, AUTH_PROVIDERS, LoginFlow
from . import AUTH_PROVIDER_SCHEMA, AUTH_PROVIDERS, AuthProvider, LoginFlow
from ..models import Credentials, UserMeta
CONF_COMMAND = "command"
CONF_ARGS = "args"
CONF_META = "meta"
@@ -78,7 +76,7 @@ class CommandLineAuthProvider(AuthProvider):
if process.returncode != 0:
_LOGGER.error(
"User %r failed to authenticate, command exited " "with code %d.",
"User %r failed to authenticate, command exited with code %d.",
username,
process.returncode,
)

View File

@@ -3,21 +3,18 @@ import asyncio
import base64
from collections import OrderedDict
import logging
from typing import Any, Dict, List, Optional, Set, cast
import bcrypt
import voluptuous as vol
from homeassistant.const import CONF_ID
from homeassistant.core import callback, HomeAssistant
from homeassistant.core import HomeAssistant, callback
from homeassistant.exceptions import HomeAssistantError
from . import AuthProvider, AUTH_PROVIDER_SCHEMA, AUTH_PROVIDERS, LoginFlow
from . import AUTH_PROVIDER_SCHEMA, AUTH_PROVIDERS, AuthProvider, LoginFlow
from ..models import Credentials, UserMeta
STORAGE_VERSION = 1
STORAGE_KEY = "auth_provider.homeassistant"
@@ -203,7 +200,7 @@ class Data:
@AUTH_PROVIDERS.register("homeassistant")
class HassAuthProvider(AuthProvider):
"""Auth provider based on a local storage of users in HASS config dir."""
"""Auth provider based on a local storage of users in Home Assistant config dir."""
DEFAULT_TITLE = "Home Assistant Local"

View File

@@ -5,13 +5,12 @@ from typing import Any, Dict, Optional, cast
import voluptuous as vol
from homeassistant.exceptions import HomeAssistantError
from homeassistant.core import callback
from homeassistant.exceptions import HomeAssistantError
from . import AuthProvider, AUTH_PROVIDER_SCHEMA, AUTH_PROVIDERS, LoginFlow
from . import AUTH_PROVIDER_SCHEMA, AUTH_PROVIDERS, AuthProvider, LoginFlow
from ..models import Credentials, UserMeta
USER_SCHEMA = vol.Schema(
{
vol.Required("username"): str,

View File

@@ -12,9 +12,9 @@ from homeassistant.core import HomeAssistant, callback
from homeassistant.exceptions import HomeAssistantError
import homeassistant.helpers.config_validation as cv
from . import AuthProvider, AUTH_PROVIDER_SCHEMA, AUTH_PROVIDERS, LoginFlow
from . import AUTH_PROVIDER_SCHEMA, AUTH_PROVIDERS, AuthProvider, LoginFlow
from .. import AuthManager
from ..models import Credentials, UserMeta, User
from ..models import Credentials, User, UserMeta
AUTH_PROVIDER_TYPE = "legacy_api_password"
CONF_API_PASSWORD = "api_password"

View File

@@ -3,15 +3,16 @@
It shows list of users if access from trusted network.
Abort login flow if not access from trusted network.
"""
from ipaddress import ip_network, IPv4Address, IPv6Address, IPv4Network, IPv6Network
from ipaddress import IPv4Address, IPv4Network, IPv6Address, IPv6Network, ip_network
from typing import Any, Dict, List, Optional, Union, cast
import voluptuous as vol
import homeassistant.helpers.config_validation as cv
from homeassistant.core import callback
from homeassistant.exceptions import HomeAssistantError
from . import AuthProvider, AUTH_PROVIDER_SCHEMA, AUTH_PROVIDERS, LoginFlow
import homeassistant.helpers.config_validation as cv
from . import AUTH_PROVIDER_SCHEMA, AUTH_PROVIDERS, AuthProvider, LoginFlow
from ..models import Credentials, UserMeta
IPAddress = Union[IPv4Address, IPv6Address]

View File

@@ -1,13 +0,0 @@
"""Auth utils."""
import binascii
import os
def generate_secret(entropy: int = 32) -> str:
"""Generate a secret.
Backport of secrets.token_hex from Python 3.6
Event loop friendly.
"""
return binascii.hexlify(os.urandom(entropy)).decode("ascii")

View File

@@ -1,22 +1,29 @@
"""Provide methods to bootstrap a Home Assistant instance."""
import asyncio
import contextlib
import logging
import logging.handlers
import os
import sys
from time import time
from collections import OrderedDict
from typing import Any, Optional, Dict, Set
from time import monotonic
from typing import Any, Dict, Optional, Set
from async_timeout import timeout
import voluptuous as vol
from homeassistant import core, config as conf_util, config_entries, loader
from homeassistant.const import EVENT_HOMEASSISTANT_CLOSE
from homeassistant.setup import async_setup_component
from homeassistant import config as conf_util, config_entries, core, loader
from homeassistant.components import http
from homeassistant.const import (
EVENT_HOMEASSISTANT_CLOSE,
EVENT_HOMEASSISTANT_STOP,
REQUIRED_NEXT_PYTHON_DATE,
REQUIRED_NEXT_PYTHON_VER,
)
from homeassistant.exceptions import HomeAssistantError
from homeassistant.setup import DATA_SETUP, async_setup_component
from homeassistant.util.logging import AsyncHandler
from homeassistant.util.package import async_get_user_site, is_virtual_env
from homeassistant.util.yaml import clear_secret_cache
from homeassistant.exceptions import HomeAssistantError
_LOGGER = logging.getLogger(__name__)
@@ -27,7 +34,7 @@ DATA_LOGGING = "logging"
DEBUGGER_INTEGRATIONS = {"ptvsd"}
CORE_INTEGRATIONS = ("homeassistant", "persistent_notification")
LOGGING_INTEGRATIONS = {"logger", "system_log"}
LOGGING_INTEGRATIONS = {"logger", "system_log", "sentry"}
STAGE_1_INTEGRATIONS = {
# To record data
"recorder",
@@ -38,32 +45,121 @@ STAGE_1_INTEGRATIONS = {
}
async def async_setup_hass(
*,
config_dir: str,
verbose: bool,
log_rotate_days: int,
log_file: str,
log_no_color: bool,
skip_pip: bool,
safe_mode: bool,
) -> Optional[core.HomeAssistant]:
"""Set up Home Assistant."""
hass = core.HomeAssistant()
hass.config.config_dir = config_dir
async_enable_logging(hass, verbose, log_rotate_days, log_file, log_no_color)
hass.config.skip_pip = skip_pip
if skip_pip:
_LOGGER.warning(
"Skipping pip installation of required modules. This may cause issues"
)
if not await conf_util.async_ensure_config_exists(hass):
_LOGGER.error("Error getting configuration path")
return None
_LOGGER.info("Config directory: %s", config_dir)
config_dict = None
basic_setup_success = False
if not safe_mode:
await hass.async_add_executor_job(conf_util.process_ha_config_upgrade, hass)
try:
config_dict = await conf_util.async_hass_config_yaml(hass)
except HomeAssistantError as err:
_LOGGER.error(
"Failed to parse configuration.yaml: %s. Activating safe mode", err,
)
else:
if not is_virtual_env():
await async_mount_local_lib_path(config_dir)
basic_setup_success = (
await async_from_config_dict(config_dict, hass) is not None
)
finally:
clear_secret_cache()
if config_dict is None:
safe_mode = True
elif not basic_setup_success:
_LOGGER.warning("Unable to set up core integrations. Activating safe mode")
safe_mode = True
elif (
"frontend" in hass.data.get(DATA_SETUP, {})
and "frontend" not in hass.config.components
):
_LOGGER.warning("Detected that frontend did not load. Activating safe mode")
# Ask integrations to shut down. It's messy but we can't
# do a clean stop without knowing what is broken
hass.async_track_tasks()
hass.bus.async_fire(EVENT_HOMEASSISTANT_STOP, {})
with contextlib.suppress(asyncio.TimeoutError):
async with timeout(10):
await hass.async_block_till_done()
safe_mode = True
hass = core.HomeAssistant()
hass.config.config_dir = config_dir
if safe_mode:
_LOGGER.info("Starting in safe mode")
hass.config.safe_mode = True
http_conf = (await http.async_get_last_config(hass)) or {}
await async_from_config_dict(
{"safe_mode": {}, "http": http_conf}, hass,
)
return hass
async def async_from_config_dict(
config: Dict[str, Any],
hass: core.HomeAssistant,
config_dir: Optional[str] = None,
enable_log: bool = True,
verbose: bool = False,
skip_pip: bool = False,
log_rotate_days: Any = None,
log_file: Any = None,
log_no_color: bool = False,
config: Dict[str, Any], hass: core.HomeAssistant
) -> Optional[core.HomeAssistant]:
"""Try to configure Home Assistant from a configuration dictionary.
Dynamically loads required components and its dependencies.
This method is a coroutine.
"""
start = time()
start = monotonic()
if enable_log:
async_enable_logging(hass, verbose, log_rotate_days, log_file, log_no_color)
hass.config_entries = config_entries.ConfigEntries(hass, config)
await hass.config_entries.async_initialize()
hass.config.skip_pip = skip_pip
if skip_pip:
_LOGGER.warning(
"Skipping pip installation of required modules. " "This may cause issues"
# Set up core.
_LOGGER.debug("Setting up %s", CORE_INTEGRATIONS)
if not all(
await asyncio.gather(
*(
async_setup_component(hass, domain, config)
for domain in CORE_INTEGRATIONS
)
)
):
_LOGGER.error("Home Assistant core failed to initialize. ")
return None
_LOGGER.debug("Home Assistant core initialized")
core_config = config.get(core.DOMAIN, {})
@@ -79,27 +175,19 @@ async def async_from_config_dict(
)
return None
# Make a copy because we are mutating it.
config = OrderedDict(config)
# Merge packages
await conf_util.merge_packages_config(
hass, config, core_config.get(conf_util.CONF_PACKAGES, {})
)
hass.config_entries = config_entries.ConfigEntries(hass, config)
await hass.config_entries.async_initialize()
await _async_set_up_integrations(hass, config)
stop = time()
stop = monotonic()
_LOGGER.info("Home Assistant initialized in %.2fs", stop - start)
if sys.version_info[:3] < (3, 7, 0):
if REQUIRED_NEXT_PYTHON_DATE and sys.version_info[:3] < REQUIRED_NEXT_PYTHON_VER:
msg = (
"Python 3.6 support is deprecated and will "
"be removed in the first release after December 15, 2019. Please "
"upgrade Python to 3.7.0 or higher."
"Support for the running Python version "
f"{'.'.join(str(x) for x in sys.version_info[:3])} is deprecated and will "
f"be removed in the first release after {REQUIRED_NEXT_PYTHON_DATE}. "
"Please upgrade Python to "
f"{'.'.join(str(x) for x in REQUIRED_NEXT_PYTHON_VER)} or "
"higher."
)
_LOGGER.warning(msg)
hass.components.persistent_notification.async_create(
@@ -109,46 +197,6 @@ async def async_from_config_dict(
return hass
async def async_from_config_file(
config_path: str,
hass: core.HomeAssistant,
verbose: bool = False,
skip_pip: bool = True,
log_rotate_days: Any = None,
log_file: Any = None,
log_no_color: bool = False,
) -> Optional[core.HomeAssistant]:
"""Read the configuration file and try to start all the functionality.
Will add functionality to 'hass' parameter.
This method is a coroutine.
"""
# Set config dir to directory holding config file
config_dir = os.path.abspath(os.path.dirname(config_path))
hass.config.config_dir = config_dir
if not is_virtual_env():
await async_mount_local_lib_path(config_dir)
async_enable_logging(hass, verbose, log_rotate_days, log_file, log_no_color)
await hass.async_add_executor_job(conf_util.process_ha_config_upgrade, hass)
try:
config_dict = await hass.async_add_executor_job(
conf_util.load_yaml_config_file, config_path
)
except HomeAssistantError as err:
_LOGGER.error("Error loading %s: %s", config_path, err)
return None
finally:
clear_secret_cache()
return await async_from_config_dict(
config_dict, hass, enable_log=False, skip_pip=skip_pip
)
@core.callback
def async_enable_logging(
hass: core.HomeAssistant,
@@ -161,7 +209,7 @@ def async_enable_logging(
This method must be run in the event loop.
"""
fmt = "%(asctime)s %(levelname)s (%(threadName)s) " "[%(name)s] %(message)s"
fmt = "%(asctime)s %(levelname)s (%(threadName)s) [%(name)s] %(message)s"
datefmt = "%Y-%m-%d %H:%M:%S"
if not log_no_color:
@@ -191,7 +239,7 @@ def async_enable_logging(
pass
# If the above initialization failed for any reason, setup the default
# formatting. If the above succeeds, this wil result in a no-op.
# formatting. If the above succeeds, this will result in a no-op.
logging.basicConfig(format=fmt, datefmt=datefmt, level=logging.INFO)
# Suppress overly verbose logs from libraries that aren't helpful
@@ -262,7 +310,8 @@ def _get_domains(hass: core.HomeAssistant, config: Dict[str, Any]) -> Set[str]:
domains = set(key.split(" ")[0] for key in config.keys() if key != core.DOMAIN)
# Add config entry domains
domains.update(hass.config_entries.async_domains())
if not hass.config.safe_mode:
domains.update(hass.config_entries.async_domains())
# Make sure the Hass.io component is loaded
if "HASSIO" in os.environ:
@@ -293,25 +342,6 @@ async def _async_set_up_integrations(
return_exceptions=True,
)
# Set up core.
_LOGGER.debug("Setting up %s", CORE_INTEGRATIONS)
if not all(
await asyncio.gather(
*(
async_setup_component(hass, domain, config)
for domain in CORE_INTEGRATIONS
)
)
):
_LOGGER.error(
"Home Assistant core failed to initialize. "
"Further initialization aborted"
)
return
_LOGGER.debug("Home Assistant core initialized")
# Finish resolving domains
for dep_domains in await resolved_domains_task:
# Result is either a set or an exception. We ignore exceptions

View File

@@ -11,7 +11,6 @@ import logging
from homeassistant.core import split_entity_id
# mypy: allow-untyped-defs
_LOGGER = logging.getLogger(__name__)

View File

@@ -14,7 +14,7 @@
"password": "Contrasenya",
"username": "Correu electr\u00f2nic"
},
"title": "Introdueix la teva informaci\u00f3 d'inici de sessi\u00f3 a Abode."
"title": "Introducci\u00f3 de la informaci\u00f3 d'inici de sessi\u00f3 a Abode."
}
},
"title": "Abode"

View File

@@ -12,7 +12,7 @@
"user": {
"data": {
"password": "Adgangskode",
"username": "Email adresse"
"username": "Email-adresse"
},
"title": "Udfyld dine Abode-loginoplysninger"
}

View File

@@ -0,0 +1,22 @@
{
"config": {
"abort": {
"single_instance_allowed": "Solo se permite una \u00fanica configuraci\u00f3n de Abode."
},
"error": {
"connection_error": "No se puede conectar a Abode.",
"identifier_exists": "Cuenta ya registrada.",
"invalid_credentials": "Credenciales inv\u00e1lidas."
},
"step": {
"user": {
"data": {
"password": "Contrase\u00f1a",
"username": "Direcci\u00f3n de correo electr\u00f3nico"
},
"title": "Complete su informaci\u00f3n de inicio de sesi\u00f3n de Abode"
}
},
"title": "Abode"
}
}

View File

@@ -0,0 +1,22 @@
{
"config": {
"abort": {
"single_instance_allowed": "Csak egyetlen Abode konfigur\u00e1ci\u00f3 enged\u00e9lyezett."
},
"error": {
"connection_error": "Nem lehet csatlakozni az Abode-hez.",
"identifier_exists": "Fi\u00f3k m\u00e1r regisztr\u00e1lva van",
"invalid_credentials": "\u00c9rv\u00e9nytelen hiteles\u00edt\u0151 adatok"
},
"step": {
"user": {
"data": {
"password": "Jelsz\u00f3",
"username": "Email c\u00edm"
},
"title": "T\u00f6ltse ki az Abode bejelentkez\u00e9si adatait"
}
},
"title": "Abode"
}
}

View File

@@ -0,0 +1,12 @@
{
"config": {
"step": {
"user": {
"data": {
"password": "Parole",
"username": "E-pasta adrese"
}
}
}
}
}

View File

@@ -5,7 +5,7 @@
},
"error": {
"connection_error": "Nie mo\u017cna po\u0142\u0105czy\u0107 si\u0119 z Abode.",
"identifier_exists": "Konto zosta\u0142o ju\u017c zarejestrowane",
"identifier_exists": "Konto jest ju\u017c zarejestrowane.",
"invalid_credentials": "Nieprawid\u0142owe dane uwierzytelniaj\u0105ce"
},
"step": {

View File

@@ -0,0 +1,22 @@
{
"config": {
"abort": {
"single_instance_allowed": "Endast en enda konfiguration av Abode \u00e4r till\u00e5ten."
},
"error": {
"connection_error": "Det gick inte att ansluta till Abode.",
"identifier_exists": "Kontot \u00e4r redan registrerat.",
"invalid_credentials": "Ogiltiga autentiseringsuppgifter."
},
"step": {
"user": {
"data": {
"password": "L\u00f6senord",
"username": "E-postadress"
},
"title": "Fyll i din inloggningsinformation f\u00f6r Abode"
}
},
"title": "Abode"
}
}

View File

@@ -2,7 +2,6 @@
from asyncio import gather
from copy import deepcopy
from functools import partial
import logging
from abodepy import Abode
from abodepy.exceptions import AbodeException
@@ -20,25 +19,17 @@ from homeassistant.const import (
CONF_USERNAME,
EVENT_HOMEASSISTANT_STOP,
)
from homeassistant.helpers.dispatcher import dispatcher_send
from homeassistant.helpers import config_validation as cv
from homeassistant.helpers.dispatcher import dispatcher_send
from homeassistant.helpers.entity import Entity
from .const import (
ATTRIBUTION,
DOMAIN,
DEFAULT_CACHEDB,
SIGNAL_CAPTURE_IMAGE,
SIGNAL_TRIGGER_QUICK_ACTION,
)
_LOGGER = logging.getLogger(__name__)
from .const import ATTRIBUTION, DEFAULT_CACHEDB, DOMAIN, LOGGER
CONF_POLLING = "polling"
SERVICE_SETTINGS = "change_setting"
SERVICE_CAPTURE_IMAGE = "capture_image"
SERVICE_TRIGGER = "trigger_quick_action"
SERVICE_TRIGGER_AUTOMATION = "trigger_automation"
ATTR_DEVICE_ID = "device_id"
ATTR_DEVICE_NAME = "device_name"
@@ -53,8 +44,6 @@ ATTR_APP_TYPE = "app_type"
ATTR_EVENT_BY = "event_by"
ATTR_VALUE = "value"
ABODE_DEVICE_ID_LIST_SCHEMA = vol.Schema([str])
CONFIG_SCHEMA = vol.Schema(
{
DOMAIN: vol.Schema(
@@ -74,7 +63,7 @@ CHANGE_SETTING_SCHEMA = vol.Schema(
CAPTURE_IMAGE_SCHEMA = vol.Schema({ATTR_ENTITY_ID: cv.entity_ids})
TRIGGER_SCHEMA = vol.Schema({ATTR_ENTITY_ID: cv.entity_ids})
AUTOMATION_SCHEMA = vol.Schema({ATTR_ENTITY_ID: cv.entity_ids})
ABODE_PLATFORMS = [
"alarm_control_panel",
@@ -93,7 +82,6 @@ class AbodeSystem:
def __init__(self, abode, polling):
"""Initialize the system."""
self.abode = abode
self.polling = polling
self.entity_ids = set()
@@ -130,7 +118,7 @@ async def async_setup_entry(hass, config_entry):
hass.data[DOMAIN] = AbodeSystem(abode, polling)
except (AbodeException, ConnectTimeout, HTTPError) as ex:
_LOGGER.error("Unable to connect to Abode: %s", str(ex))
LOGGER.error("Unable to connect to Abode: %s", str(ex))
return False
for platform in ABODE_PLATFORMS:
@@ -149,7 +137,7 @@ async def async_unload_entry(hass, config_entry):
"""Unload a config entry."""
hass.services.async_remove(DOMAIN, SERVICE_SETTINGS)
hass.services.async_remove(DOMAIN, SERVICE_CAPTURE_IMAGE)
hass.services.async_remove(DOMAIN, SERVICE_TRIGGER)
hass.services.async_remove(DOMAIN, SERVICE_TRIGGER_AUTOMATION)
tasks = []
@@ -170,7 +158,7 @@ async def async_unload_entry(hass, config_entry):
def setup_hass_services(hass):
"""Home assistant services."""
"""Home Assistant services."""
def change_setting(call):
"""Change an Abode system setting."""
@@ -180,7 +168,7 @@ def setup_hass_services(hass):
try:
hass.data[DOMAIN].abode.set_setting(setting, value)
except AbodeException as ex:
_LOGGER.warning(ex)
LOGGER.warning(ex)
def capture_image(call):
"""Capture a new image."""
@@ -193,11 +181,11 @@ def setup_hass_services(hass):
]
for entity_id in target_entities:
signal = SIGNAL_CAPTURE_IMAGE.format(entity_id)
signal = f"abode_camera_capture_{entity_id}"
dispatcher_send(hass, signal)
def trigger_quick_action(call):
"""Trigger a quick action."""
def trigger_automation(call):
"""Trigger an Abode automation."""
entity_ids = call.data.get(ATTR_ENTITY_ID, None)
target_entities = [
@@ -207,7 +195,7 @@ def setup_hass_services(hass):
]
for entity_id in target_entities:
signal = SIGNAL_TRIGGER_QUICK_ACTION.format(entity_id)
signal = f"abode_trigger_automation_{entity_id}"
dispatcher_send(hass, signal)
hass.services.register(
@@ -219,7 +207,7 @@ def setup_hass_services(hass):
)
hass.services.register(
DOMAIN, SERVICE_TRIGGER, trigger_quick_action, schema=TRIGGER_SCHEMA
DOMAIN, SERVICE_TRIGGER_AUTOMATION, trigger_automation, schema=AUTOMATION_SCHEMA
)
@@ -232,7 +220,7 @@ async def setup_hass_events(hass):
hass.data[DOMAIN].abode.events.stop()
hass.data[DOMAIN].abode.logout()
_LOGGER.info("Logged out of Abode")
LOGGER.info("Logged out of Abode")
if not hass.data[DOMAIN].polling:
await hass.async_add_executor_job(hass.data[DOMAIN].abode.events.start)
@@ -390,11 +378,14 @@ class AbodeAutomation(Entity):
"""Return the state attributes."""
return {
ATTR_ATTRIBUTION: ATTRIBUTION,
"automation_id": self._automation.automation_id,
"type": self._automation.type,
"sub_type": self._automation.sub_type,
"type": "CUE automation",
}
@property
def unique_id(self):
"""Return a unique ID to use for this automation."""
return self._automation.automation_id
def _update_callback(self, device):
"""Update the automation state."""
self._automation.refresh()

View File

@@ -1,6 +1,4 @@
"""Support for Abode Security System alarm control panels."""
import logging
import homeassistant.components.alarm_control_panel as alarm
from homeassistant.components.alarm_control_panel.const import (
SUPPORT_ALARM_ARM_AWAY,
@@ -16,16 +14,9 @@ from homeassistant.const import (
from . import AbodeDevice
from .const import ATTRIBUTION, DOMAIN
_LOGGER = logging.getLogger(__name__)
ICON = "mdi:security"
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
"""Platform uses config entry setup."""
pass
async def async_setup_entry(hass, config_entry, async_add_entities):
"""Set up Abode alarm control panel device."""
data = hass.data[DOMAIN]
@@ -55,6 +46,11 @@ class AbodeAlarm(AbodeDevice, alarm.AlarmControlPanel):
state = None
return state
@property
def code_arm_required(self):
"""Whether the code is required for arm actions."""
return False
@property
def supported_features(self) -> int:
"""Return the list of supported features."""

View File

@@ -1,21 +1,10 @@
"""Support for Abode Security System binary sensors."""
import logging
import abodepy.helpers.constants as CONST
import abodepy.helpers.timeline as TIMELINE
from homeassistant.components.binary_sensor import BinarySensorDevice
from homeassistant.helpers.dispatcher import async_dispatcher_connect
from . import AbodeAutomation, AbodeDevice
from .const import DOMAIN, SIGNAL_TRIGGER_QUICK_ACTION
_LOGGER = logging.getLogger(__name__)
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
"""Platform uses config entry setup."""
pass
from . import AbodeDevice
from .const import DOMAIN
async def async_setup_entry(hass, config_entry, async_add_entities):
@@ -35,13 +24,6 @@ async def async_setup_entry(hass, config_entry, async_add_entities):
for device in data.abode.get_devices(generic_type=device_types):
entities.append(AbodeBinarySensor(data, device))
for automation in data.abode.get_automations(generic_type=CONST.TYPE_QUICK_ACTION):
entities.append(
AbodeQuickActionBinarySensor(
data, automation, TIMELINE.AUTOMATION_EDIT_GROUP
)
)
async_add_entities(entities)
@@ -57,22 +39,3 @@ class AbodeBinarySensor(AbodeDevice, BinarySensorDevice):
def device_class(self):
"""Return the class of the binary sensor."""
return self._device.generic_type
class AbodeQuickActionBinarySensor(AbodeAutomation, BinarySensorDevice):
"""A binary sensor implementation for Abode quick action automations."""
async def async_added_to_hass(self):
"""Subscribe Abode events."""
await super().async_added_to_hass()
signal = SIGNAL_TRIGGER_QUICK_ACTION.format(self.entity_id)
async_dispatcher_connect(self.hass, signal, self.trigger)
def trigger(self):
"""Trigger a quick automation."""
self._automation.trigger()
@property
def is_on(self):
"""Return True if the binary sensor is on."""
return self._automation.is_active

View File

@@ -1,6 +1,5 @@
"""Support for Abode Security System cameras."""
from datetime import timedelta
import logging
import abodepy.helpers.constants as CONST
import abodepy.helpers.timeline as TIMELINE
@@ -11,17 +10,10 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
from homeassistant.util import Throttle
from . import AbodeDevice
from .const import DOMAIN, SIGNAL_CAPTURE_IMAGE
from .const import DOMAIN, LOGGER
MIN_TIME_BETWEEN_UPDATES = timedelta(seconds=90)
_LOGGER = logging.getLogger(__name__)
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
"""Platform uses config entry setup."""
pass
async def async_setup_entry(hass, config_entry, async_add_entities):
"""Set up Abode camera devices."""
@@ -55,7 +47,7 @@ class AbodeCamera(AbodeDevice, Camera):
self._capture_callback,
)
signal = SIGNAL_CAPTURE_IMAGE.format(self.entity_id)
signal = f"abode_camera_capture_{self.entity_id}"
async_dispatcher_connect(self.hass, signal, self.capture)
def capture(self):
@@ -76,7 +68,7 @@ class AbodeCamera(AbodeDevice, Camera):
self._response.raise_for_status()
except requests.HTTPError as err:
_LOGGER.warning("Failed to get camera image: %s", err)
LOGGER.warning("Failed to get camera image: %s", err)
self._response = None
else:
self._response = None

View File

@@ -1,6 +1,4 @@
"""Config flow for the Abode Security System component."""
import logging
from abodepy import Abode
from abodepy.exceptions import AbodeException
from requests.exceptions import ConnectTimeout, HTTPError
@@ -10,12 +8,10 @@ from homeassistant import config_entries
from homeassistant.const import CONF_PASSWORD, CONF_USERNAME
from homeassistant.core import callback
from .const import DOMAIN, DEFAULT_CACHEDB # pylint: disable=unused-import
from .const import DEFAULT_CACHEDB, DOMAIN, LOGGER # pylint: disable=unused-import
CONF_POLLING = "polling"
_LOGGER = logging.getLogger(__name__)
class AbodeFlowHandler(config_entries.ConfigFlow, domain=DOMAIN):
"""Config flow for Abode."""
@@ -32,7 +28,6 @@ class AbodeFlowHandler(config_entries.ConfigFlow, domain=DOMAIN):
async def async_step_user(self, user_input=None):
"""Handle a flow initialized by the user."""
if self._async_current_entries():
return self.async_abort(reason="single_instance_allowed")
@@ -50,7 +45,7 @@ class AbodeFlowHandler(config_entries.ConfigFlow, domain=DOMAIN):
)
except (AbodeException, ConnectTimeout, HTTPError) as ex:
_LOGGER.error("Unable to connect to Abode: %s", str(ex))
LOGGER.error("Unable to connect to Abode: %s", str(ex))
if ex.errcode == 400:
return self._show_form({"base": "invalid_credentials"})
return self._show_form({"base": "connection_error"})
@@ -76,7 +71,7 @@ class AbodeFlowHandler(config_entries.ConfigFlow, domain=DOMAIN):
async def async_step_import(self, import_config):
"""Import a config entry from configuration.yaml."""
if self._async_current_entries():
_LOGGER.warning("Only one configuration of abode is allowed.")
LOGGER.warning("Only one configuration of abode is allowed.")
return self.async_abort(reason="single_instance_allowed")
return await self.async_step_user(import_config)

View File

@@ -1,8 +1,9 @@
"""Constants for the Abode Security System component."""
import logging
LOGGER = logging.getLogger(__package__)
DOMAIN = "abode"
ATTRIBUTION = "Data provided by goabode.com"
DEFAULT_CACHEDB = "abodepy_cache.pickle"
SIGNAL_CAPTURE_IMAGE = "abode_camera_capture_{}"
SIGNAL_TRIGGER_QUICK_ACTION = "abode_trigger_quick_action_{}"

View File

@@ -1,6 +1,4 @@
"""Support for Abode Security System covers."""
import logging
import abodepy.helpers.constants as CONST
from homeassistant.components.cover import CoverDevice
@@ -8,13 +6,6 @@ from homeassistant.components.cover import CoverDevice
from . import AbodeDevice
from .const import DOMAIN
_LOGGER = logging.getLogger(__name__)
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
"""Platform uses config entry setup."""
pass
async def async_setup_entry(hass, config_entry, async_add_entities):
"""Set up Abode cover devices."""

View File

@@ -1,5 +1,4 @@
"""Support for Abode Security System lights."""
import logging
from math import ceil
import abodepy.helpers.constants as CONST
@@ -21,13 +20,6 @@ from homeassistant.util.color import (
from . import AbodeDevice
from .const import DOMAIN
_LOGGER = logging.getLogger(__name__)
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
"""Platform uses config entry setup."""
pass
async def async_setup_entry(hass, config_entry, async_add_entities):
"""Set up Abode light devices."""
@@ -50,16 +42,19 @@ class AbodeLight(AbodeDevice, Light):
self._device.set_color_temp(
int(color_temperature_mired_to_kelvin(kwargs[ATTR_COLOR_TEMP]))
)
return
if ATTR_HS_COLOR in kwargs and self._device.is_color_capable:
self._device.set_color(kwargs[ATTR_HS_COLOR])
return
if ATTR_BRIGHTNESS in kwargs and self._device.is_dimmable:
# Convert HASS brightness (0-255) to Abode brightness (0-99)
# Convert Home Assistant brightness (0-255) to Abode brightness (0-99)
# If 100 is sent to Abode, response is 99 causing an error
self._device.set_level(ceil(kwargs[ATTR_BRIGHTNESS] * 99 / 255.0))
else:
self._device.switch_on()
return
self._device.switch_on()
def turn_off(self, **kwargs):
"""Turn off the light."""
@@ -78,7 +73,7 @@ class AbodeLight(AbodeDevice, Light):
# Abode returns 100 during device initialization and device refresh
if brightness == 100:
return 255
# Convert Abode brightness (0-99) to HASS brightness (0-255)
# Convert Abode brightness (0-99) to Home Assistant brightness (0-255)
return ceil(brightness * 255 / 99.0)
@property

View File

@@ -1,6 +1,4 @@
"""Support for the Abode Security System locks."""
import logging
import abodepy.helpers.constants as CONST
from homeassistant.components.lock import LockDevice
@@ -8,13 +6,6 @@ from homeassistant.components.lock import LockDevice
from . import AbodeDevice
from .const import DOMAIN
_LOGGER = logging.getLogger(__name__)
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
"""Platform uses config entry setup."""
pass
async def async_setup_entry(hass, config_entry, async_add_entities):
"""Set up Abode lock devices."""

View File

@@ -3,11 +3,7 @@
"name": "Abode",
"config_flow": true,
"documentation": "https://www.home-assistant.io/integrations/abode",
"requirements": [
"abodepy==0.16.7"
],
"requirements": ["abodepy==0.18.1"],
"dependencies": [],
"codeowners": [
"@shred86"
]
}
"codeowners": ["@shred86"]
}

View File

@@ -1,6 +1,4 @@
"""Support for Abode Security System sensors."""
import logging
import abodepy.helpers.constants as CONST
from homeassistant.const import (
@@ -12,8 +10,6 @@ from homeassistant.const import (
from . import AbodeDevice
from .const import DOMAIN
_LOGGER = logging.getLogger(__name__)
# Sensor types: Name, icon
SENSOR_TYPES = {
CONST.TEMP_STATUS_KEY: ["Temperature", DEVICE_CLASS_TEMPERATURE],
@@ -22,11 +18,6 @@ SENSOR_TYPES = {
}
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
"""Platform uses config entry setup."""
pass
async def async_setup_entry(hass, config_entry, async_add_entities):
"""Set up Abode sensor devices."""
data = hass.data[DOMAIN]
@@ -49,9 +40,7 @@ class AbodeSensor(AbodeDevice):
"""Initialize a sensor for an Abode device."""
super().__init__(data, device)
self._sensor_type = sensor_type
self._name = "{0} {1}".format(
self._device.name, SENSOR_TYPES[self._sensor_type][0]
)
self._name = f"{self._device.name} {SENSOR_TYPES[self._sensor_type][0]}"
self._device_class = SENSOR_TYPES[self._sensor_type][1]
@property

View File

@@ -7,7 +7,7 @@ change_setting:
fields:
setting: {description: Setting to change., example: beeper_mute}
value: {description: Value of the setting., example: '1'}
trigger_quick_action:
description: Trigger an Abode quick action.
trigger_automation:
description: Trigger an Abode automation.
fields:
entity_id: {description: Entity id of the quick action to trigger., example: binary_sensor.home_quick_action}
entity_id: {description: Entity id of the automation to trigger., example: switch.my_automation}

View File

@@ -1,20 +1,16 @@
"""Support for Abode Security System switches."""
import logging
import abodepy.helpers.constants as CONST
import abodepy.helpers.timeline as TIMELINE
from homeassistant.components.switch import SwitchDevice
from homeassistant.helpers.dispatcher import async_dispatcher_connect
from . import AbodeAutomation, AbodeDevice
from .const import DOMAIN
_LOGGER = logging.getLogger(__name__)
DEVICE_TYPES = [CONST.TYPE_SWITCH, CONST.TYPE_VALVE]
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
"""Platform uses config entry setup."""
pass
ICON = "mdi:robot"
async def async_setup_entry(hass, config_entry, async_add_entities):
@@ -23,10 +19,11 @@ async def async_setup_entry(hass, config_entry, async_add_entities):
entities = []
for device in data.abode.get_devices(generic_type=CONST.TYPE_SWITCH):
entities.append(AbodeSwitch(data, device))
for device_type in DEVICE_TYPES:
for device in data.abode.get_devices(generic_type=device_type):
entities.append(AbodeSwitch(data, device))
for automation in data.abode.get_automations(generic_type=CONST.TYPE_AUTOMATION):
for automation in data.abode.get_automations():
entities.append(
AbodeAutomationSwitch(data, automation, TIMELINE.AUTOMATION_EDIT_GROUP)
)
@@ -54,15 +51,33 @@ class AbodeSwitch(AbodeDevice, SwitchDevice):
class AbodeAutomationSwitch(AbodeAutomation, SwitchDevice):
"""A switch implementation for Abode automations."""
async def async_added_to_hass(self):
"""Subscribe Abode events."""
await super().async_added_to_hass()
signal = f"abode_trigger_automation_{self.entity_id}"
async_dispatcher_connect(self.hass, signal, self.trigger)
def turn_on(self, **kwargs):
"""Turn on the device."""
self._automation.set_active(True)
"""Enable the automation."""
if self._automation.enable(True):
self.schedule_update_ha_state()
def turn_off(self, **kwargs):
"""Turn off the device."""
self._automation.set_active(False)
"""Disable the automation."""
if self._automation.enable(False):
self.schedule_update_ha_state()
def trigger(self):
"""Trigger the automation."""
self._automation.trigger()
@property
def is_on(self):
"""Return True if the binary sensor is on."""
return self._automation.is_active
"""Return True if the automation is enabled."""
return self._automation.is_enabled
@property
def icon(self):
"""Return the robot icon to match Home Assistant automations."""
return ICON

View File

@@ -1,10 +1,8 @@
{
"domain": "acer_projector",
"name": "Acer projector",
"name": "Acer Projector",
"documentation": "https://www.home-assistant.io/integrations/acer_projector",
"requirements": [
"pyserial==3.1.1"
],
"requirements": ["pyserial==3.1.1"],
"dependencies": [],
"codeowners": []
}

View File

@@ -1,17 +1,17 @@
"""Use serial protocol of Acer projector to obtain state of the projector."""
import logging
import re
import serial
import serial
import voluptuous as vol
from homeassistant.components.switch import SwitchDevice, PLATFORM_SCHEMA
from homeassistant.components.switch import PLATFORM_SCHEMA, SwitchDevice
from homeassistant.const import (
STATE_ON,
STATE_OFF,
STATE_UNKNOWN,
CONF_NAME,
CONF_FILENAME,
CONF_NAME,
STATE_OFF,
STATE_ON,
STATE_UNKNOWN,
)
import homeassistant.helpers.config_validation as cv

View File

@@ -1,18 +1,19 @@
"""Support for Actiontec MI424WR (Verizon FIOS) routers."""
from collections import namedtuple
import logging
import re
import telnetlib
from collections import namedtuple
import voluptuous as vol
import homeassistant.helpers.config_validation as cv
import homeassistant.util.dt as dt_util
from homeassistant.components.device_tracker import (
DOMAIN,
PLATFORM_SCHEMA,
DeviceScanner,
)
from homeassistant.const import CONF_HOST, CONF_PASSWORD, CONF_USERNAME
import homeassistant.helpers.config_validation as cv
import homeassistant.util.dt as dt_util
_LOGGER = logging.getLogger(__name__)

View File

@@ -0,0 +1,10 @@
{
"config": {
"step": {
"hassio_confirm": {
"description": "Chcete nakonfigurovat slu\u017ebu Home Assistant pro p\u0159ipojen\u00ed k AddGuard pomoc\u00ed hass.io {addon}?",
"title": "AdGuard prost\u0159ednictv\u00edm dopl\u0148ku Hass.io"
}
}
}
}

View File

@@ -1,16 +1,18 @@
{
"config": {
"abort": {
"adguard_home_addon_outdated": "Denne integration kr\u00e6ver AdGuard Home {minimal_version} eller h\u00f8jere, du har {current_version}. Opdater venligst din Hass.io AdGuard Home-tilf\u00f8jelse.",
"adguard_home_outdated": "Denne integration kr\u00e6ver AdGuard Home {minimal_version} eller h\u00f8jere, du har {current_version}.",
"existing_instance_updated": "Opdaterede eksisterende konfiguration.",
"single_instance_allowed": "Det er kun n\u00f8dvendigt med en ops\u00e6tning af AdGuard Home."
"single_instance_allowed": "Kun en enkelt konfiguration af AdGuard Home er tilladt."
},
"error": {
"connection_error": "Forbindelse mislykkedes."
},
"step": {
"hassio_confirm": {
"description": "Vil du konfigurere Home Assistant til at oprette forbindelse til AdGuard Home, der leveres af Hass.io add-on: {addon}?",
"title": "AdGuard Home via Hass.io add-on"
"description": "Vil du konfigurere Home Assistant til at oprette forbindelse til AdGuard Home leveret af Hass.io-tilf\u00f8jelsen: {addon}?",
"title": "AdGuard Home via Hass.io-tilf\u00f8jelse"
},
"user": {
"data": {
@@ -21,8 +23,8 @@
"username": "Brugernavn",
"verify_ssl": "AdGuard Home bruger et korrekt certifikat"
},
"description": "Konfigurer din AdGuard Home instans for at tillade overv\u00e5gning og kontrol.",
"title": "Link AdGuard Home."
"description": "Konfigurer din AdGuard Home-instans for at tillade overv\u00e5gning og kontrol.",
"title": "Forbind din AdGuard Home."
}
},
"title": "AdGuard Home"

View File

@@ -1,6 +1,8 @@
{
"config": {
"abort": {
"adguard_home_addon_outdated": "Diese Integration erfordert AdGuard Home {minimal_version} oder h\u00f6her, du hast {current_version}. Bitte aktualisiere dein Hass.io AdGuard Home Add-on.",
"adguard_home_outdated": "Diese Integration erfordert AdGuard Home {minimal_version} oder h\u00f6her, du hast {current_version}.",
"existing_instance_updated": "Bestehende Konfiguration wurde aktualisiert.",
"single_instance_allowed": "Es ist nur eine einzige Konfiguration von AdGuard Home zul\u00e4ssig."
},

View File

@@ -1,6 +1,8 @@
{
"config": {
"abort": {
"adguard_home_addon_outdated": "Esta integraci\u00f3n requiere AdGuard Home {minimal_version} o superior, tiene {current_version}. Actualice su complemento Hass.io AdGuard Home.",
"adguard_home_outdated": "Esta integraci\u00f3n requiere AdGuard Home {minimal_version} o superior, tiene {current_version}.",
"existing_instance_updated": "Se actualiz\u00f3 la configuraci\u00f3n existente.",
"single_instance_allowed": "Solo se permite una \u00fanica configuraci\u00f3n de AdGuard Home."
},

View File

@@ -1,7 +1,7 @@
{
"config": {
"abort": {
"adguard_home_addon_outdated": "Questa integrazione richiede AdGuard Home {minimal_version} o versione successiva, si dispone di {current_version}. Aggiorna il componente aggiuntivo Hass.io AdGuard Home.",
"adguard_home_addon_outdated": "Questa integrazione richiede AdGuard Home {minimal_version} o versione successiva, si dispone di {current_version}. Aggiorna il componente aggiuntivo AdGuard Home di Hass.io.",
"adguard_home_outdated": "Questa integrazione richiede AdGuard Home {minimal_version} o versione successiva, si dispone di {current_version}.",
"existing_instance_updated": "Configurazione esistente aggiornata.",
"single_instance_allowed": "\u00c8 consentita solo una singola configurazione di AdGuard Home."
@@ -11,7 +11,7 @@
},
"step": {
"hassio_confirm": {
"description": "Vuoi configurare Home Assistant per connettersi alla AdGuard Home fornita dal componente aggiuntivo di Hass.io: {addon} ?",
"description": "Vuoi configurare Home Assistant per connettersi alla AdGuard Home fornita dal componente aggiuntivo di Hass.io: {addon}?",
"title": "AdGuard Home tramite il componente aggiuntivo di Hass.io"
},
"user": {

View File

@@ -11,7 +11,7 @@
},
"step": {
"hassio_confirm": {
"description": "Hass.io {addon} \uc560\ub4dc\uc628\uc73c\ub85c AdGuard Home \uc5d0 \uc5f0\uacb0\ud558\ub3c4\ub85d Home Assistant \ub97c \uad6c\uc131 \ud558\uc2dc\uaca0\uc2b5\ub2c8\uae4c?",
"description": "Hass.io {addon} \uc560\ub4dc\uc628\uc73c\ub85c AdGuard Home \uc5d0 \uc5f0\uacb0\ud558\ub3c4\ub85d Home Assistant \ub97c \uad6c\uc131\ud558\uc2dc\uaca0\uc2b5\ub2c8\uae4c?",
"title": "Hass.io \uc560\ub4dc\uc628\uc758 AdGuard Home"
},
"user": {

View File

@@ -1,6 +1,8 @@
{
"config": {
"abort": {
"adguard_home_addon_outdated": "Den h\u00e4r integrationen kr\u00e4ver AdGuard Home {minimal_version} eller senare, du har {current_version}. Uppdatera ditt Hass.io AdGuard Home-till\u00e4gg.",
"adguard_home_outdated": "Den h\u00e4r integrationen kr\u00e4ver AdGuard Home {minimal_version} eller senare, du har {current_version}.",
"existing_instance_updated": "Uppdaterade existerande konfiguration.",
"single_instance_allowed": "Endast en enda konfiguration av AdGuard Home \u00e4r till\u00e5ten."
},

View File

@@ -61,7 +61,6 @@ async def async_setup_entry(hass: HomeAssistantType, entry: ConfigEntry) -> bool
password=entry.data[CONF_PASSWORD],
tls=entry.data[CONF_SSL],
verify_ssl=entry.data[CONF_VERIFY_SSL],
loop=hass.loop,
session=session,
)
@@ -143,11 +142,14 @@ async def async_unload_entry(hass: HomeAssistantType, entry: ConfigType) -> bool
class AdGuardHomeEntity(Entity):
"""Defines a base AdGuard Home entity."""
def __init__(self, adguard, name: str, icon: str) -> None:
def __init__(
self, adguard, name: str, icon: str, enabled_default: bool = True
) -> None:
"""Initialize the AdGuard Home entity."""
self._name = name
self._icon = icon
self._available = True
self._enabled_default = enabled_default
self._icon = icon
self._name = name
self.adguard = adguard
@property
@@ -160,6 +162,11 @@ class AdGuardHomeEntity(Entity):
"""Return the mdi icon of the entity."""
return self._icon
@property
def entity_registry_enabled_default(self) -> bool:
"""Return if the entity should be enabled when first added to the entity registry."""
return self._enabled_default
@property
def available(self) -> bool:
"""Return True if entity is available."""
@@ -167,6 +174,9 @@ class AdGuardHomeEntity(Entity):
async def async_update(self) -> None:
"""Update AdGuard Home entity."""
if not self.enabled:
return
try:
await self._adguard_update()
self._available = True

View File

@@ -79,7 +79,6 @@ class AdGuardHomeFlowHandler(ConfigFlow):
password=user_input.get(CONF_PASSWORD),
tls=user_input[CONF_SSL],
verify_ssl=user_input[CONF_VERIFY_SSL],
loop=self.hass.loop,
session=session,
)
@@ -161,7 +160,6 @@ class AdGuardHomeFlowHandler(ConfigFlow):
self._hassio_discovery[CONF_HOST],
port=self._hassio_discovery[CONF_PORT],
tls=False,
loop=self.hass.loop,
session=session,
)

View File

@@ -1,13 +1,9 @@
{
"domain": "adguard",
"name": "AdGuard Home",
"config_flow": true,
"documentation": "https://www.home-assistant.io/integrations/adguard",
"requirements": [
"adguardhome==0.3.0"
],
"dependencies": [],
"codeowners": [
"@frenck"
]
}
"domain": "adguard",
"name": "AdGuard Home",
"config_flow": true,
"documentation": "https://www.home-assistant.io/integrations/adguard",
"requirements": ["adguardhome==0.4.1"],
"dependencies": [],
"codeowners": ["@frenck"]
}

View File

@@ -11,6 +11,7 @@ from homeassistant.components.adguard.const import (
DOMAIN,
)
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import TIME_MILLISECONDS, UNIT_PERCENTAGE
from homeassistant.exceptions import PlatformNotReady
from homeassistant.helpers.typing import HomeAssistantType
@@ -51,14 +52,20 @@ class AdGuardHomeSensor(AdGuardHomeDeviceEntity):
"""Defines a AdGuard Home sensor."""
def __init__(
self, adguard, name: str, icon: str, measurement: str, unit_of_measurement: str
self,
adguard,
name: str,
icon: str,
measurement: str,
unit_of_measurement: str,
enabled_default: bool = True,
) -> None:
"""Initialize AdGuard Home sensor."""
self._state = None
self._unit_of_measurement = unit_of_measurement
self.measurement = measurement
super().__init__(adguard, name, icon)
super().__init__(adguard, name, icon, enabled_default)
@property
def unique_id(self) -> str:
@@ -109,6 +116,7 @@ class AdGuardHomeBlockedFilteringSensor(AdGuardHomeSensor):
"mdi:magnify-close",
"blocked_filtering",
"queries",
enabled_default=False,
)
async def _adguard_update(self) -> None:
@@ -126,7 +134,7 @@ class AdGuardHomePercentageBlockedSensor(AdGuardHomeSensor):
"AdGuard DNS Queries Blocked Ratio",
"mdi:magnify-close",
"blocked_percentage",
"%",
UNIT_PERCENTAGE,
)
async def _adguard_update(self) -> None:
@@ -178,7 +186,7 @@ class AdGuardHomeReplacedSafeSearchSensor(AdGuardHomeSensor):
"""Initialize AdGuard Home sensor."""
super().__init__(
adguard,
"Searches Safe Search Enforced",
"AdGuard Safe Searches Enforced",
"mdi:shield-search",
"enforced_safesearch",
"requests",
@@ -199,7 +207,7 @@ class AdGuardHomeAverageProcessingTimeSensor(AdGuardHomeSensor):
"AdGuard Average Processing Speed",
"mdi:speedometer",
"average_speed",
"ms",
TIME_MILLISECONDS,
)
async def _adguard_update(self) -> None:
@@ -214,7 +222,12 @@ class AdGuardHomeRulesCountSensor(AdGuardHomeSensor):
def __init__(self, adguard):
"""Initialize AdGuard Home sensor."""
super().__init__(
adguard, "AdGuard Rules Count", "mdi:counter", "rules_count", "rules"
adguard,
"AdGuard Rules Count",
"mdi:counter",
"rules_count",
"rules",
enabled_default=False,
)
async def _adguard_update(self) -> None:

View File

@@ -10,9 +10,9 @@ from homeassistant.components.adguard.const import (
DATA_ADGUARD_VERION,
DOMAIN,
)
from homeassistant.components.switch import SwitchDevice
from homeassistant.config_entries import ConfigEntry
from homeassistant.exceptions import PlatformNotReady
from homeassistant.helpers.entity import ToggleEntity
from homeassistant.helpers.typing import HomeAssistantType
_LOGGER = logging.getLogger(__name__)
@@ -45,14 +45,16 @@ async def async_setup_entry(
async_add_entities(switches, True)
class AdGuardHomeSwitch(ToggleEntity, AdGuardHomeDeviceEntity):
class AdGuardHomeSwitch(AdGuardHomeDeviceEntity, SwitchDevice):
"""Defines a AdGuard Home switch."""
def __init__(self, adguard, name: str, icon: str, key: str):
def __init__(
self, adguard, name: str, icon: str, key: str, enabled_default: bool = True
):
"""Initialize AdGuard Home switch."""
self._state = False
self._key = key
super().__init__(adguard, name, icon)
super().__init__(adguard, name, icon, enabled_default)
@property
def unique_id(self) -> str:
@@ -204,7 +206,13 @@ class AdGuardHomeQueryLogSwitch(AdGuardHomeSwitch):
def __init__(self, adguard) -> None:
"""Initialize AdGuard Home switch."""
super().__init__(adguard, "AdGuard Query Log", "mdi:shield-check", "querylog")
super().__init__(
adguard,
"AdGuard Query Log",
"mdi:shield-check",
"querylog",
enabled_default=False,
)
async def _adguard_turn_off(self) -> None:
"""Turn off the switch."""

View File

@@ -1,14 +1,13 @@
"""Support for Automation Device Specification (ADS)."""
import threading
import struct
import logging
import ctypes
from collections import namedtuple
import asyncio
from collections import namedtuple
import ctypes
import logging
import struct
import threading
import async_timeout
import pyads
import voluptuous as vol
from homeassistant.const import (

View File

@@ -11,7 +11,7 @@ from homeassistant.components.binary_sensor import (
from homeassistant.const import CONF_DEVICE_CLASS, CONF_NAME
import homeassistant.helpers.config_validation as cv
from . import CONF_ADS_VAR, DATA_ADS, AdsEntity, STATE_KEY_STATE
from . import CONF_ADS_VAR, DATA_ADS, STATE_KEY_STATE, AdsEntity
_LOGGER = logging.getLogger(__name__)

View File

@@ -4,25 +4,25 @@ import logging
import voluptuous as vol
from homeassistant.components.cover import (
PLATFORM_SCHEMA,
SUPPORT_OPEN,
SUPPORT_CLOSE,
SUPPORT_STOP,
SUPPORT_SET_POSITION,
ATTR_POSITION,
DEVICE_CLASSES_SCHEMA,
PLATFORM_SCHEMA,
SUPPORT_CLOSE,
SUPPORT_OPEN,
SUPPORT_SET_POSITION,
SUPPORT_STOP,
CoverDevice,
)
from homeassistant.const import CONF_NAME, CONF_DEVICE_CLASS
from homeassistant.const import CONF_DEVICE_CLASS, CONF_NAME
import homeassistant.helpers.config_validation as cv
from . import (
CONF_ADS_VAR,
CONF_ADS_VAR_POSITION,
DATA_ADS,
AdsEntity,
STATE_KEY_STATE,
STATE_KEY_POSITION,
STATE_KEY_STATE,
AdsEntity,
)
_LOGGER = logging.getLogger(__name__)

View File

@@ -16,9 +16,9 @@ from . import (
CONF_ADS_VAR,
CONF_ADS_VAR_BRIGHTNESS,
DATA_ADS,
AdsEntity,
STATE_KEY_BRIGHTNESS,
STATE_KEY_STATE,
AdsEntity,
)
_LOGGER = logging.getLogger(__name__)

View File

@@ -1,10 +1,8 @@
{
"domain": "ads",
"name": "Ads",
"name": "ADS",
"documentation": "https://www.home-assistant.io/integrations/ads",
"requirements": [
"pyads==3.0.7"
],
"requirements": ["pyads==3.0.7"],
"dependencies": [],
"codeowners": []
}

View File

@@ -8,7 +8,7 @@ from homeassistant.components.sensor import PLATFORM_SCHEMA
from homeassistant.const import CONF_NAME, CONF_UNIT_OF_MEASUREMENT
import homeassistant.helpers.config_validation as cv
from . import CONF_ADS_FACTOR, CONF_ADS_TYPE, CONF_ADS_VAR, AdsEntity, STATE_KEY_STATE
from . import CONF_ADS_FACTOR, CONF_ADS_TYPE, CONF_ADS_VAR, STATE_KEY_STATE, AdsEntity
_LOGGER = logging.getLogger(__name__)

View File

@@ -3,11 +3,11 @@ import logging
import voluptuous as vol
from homeassistant.components.switch import SwitchDevice, PLATFORM_SCHEMA
from homeassistant.components.switch import PLATFORM_SCHEMA, SwitchDevice
from homeassistant.const import CONF_NAME
import homeassistant.helpers.config_validation as cv
from . import CONF_ADS_VAR, DATA_ADS, AdsEntity, STATE_KEY_STATE
from . import CONF_ADS_VAR, DATA_ADS, STATE_KEY_STATE, AdsEntity
_LOGGER = logging.getLogger(__name__)

View File

@@ -1,10 +1,8 @@
{
"domain": "aftership",
"name": "Aftership",
"name": "AfterShip",
"documentation": "https://www.home-assistant.io/integrations/aftership",
"requirements": [
"pyaftership==0.1.2"
],
"requirements": ["pyaftership==0.1.2"],
"dependencies": [],
"codeowners": []
}

View File

@@ -77,7 +77,7 @@ async def async_setup_platform(hass, config, async_add_entities, discovery_info=
async_add_entities([instance], True)
async def handle_add_tracking(call):
"""Call when a user adds a new Aftership tracking from HASS."""
"""Call when a user adds a new Aftership tracking from Home Assistant."""
title = call.data.get(CONF_TITLE)
slug = call.data.get(CONF_SLUG)
tracking_number = call.data[CONF_TRACKING_NUMBER]
@@ -93,7 +93,7 @@ async def async_setup_platform(hass, config, async_add_entities, discovery_info=
)
async def handle_remove_tracking(call):
"""Call when a user removes an Aftership tracking from HASS."""
"""Call when a user removes an Aftership tracking from Home Assistant."""
slug = call.data[CONF_SLUG]
tracking_number = call.data[CONF_TRACKING_NUMBER]

View File

@@ -2,12 +2,12 @@
from datetime import timedelta
import logging
from homeassistant.helpers.entity_component import EntityComponent
from homeassistant.helpers.config_validation import ( # noqa: F401
PLATFORM_SCHEMA,
PLATFORM_SCHEMA_BASE,
)
from homeassistant.helpers.entity import Entity
from homeassistant.helpers.entity_component import EntityComponent
_LOGGER = logging.getLogger(__name__)

View File

@@ -1,6 +1,6 @@
{
"domain": "air_quality",
"name": "Air quality",
"name": "Air Quality",
"documentation": "https://www.home-assistant.io/integrations/air_quality",
"requirements": [],
"dependencies": [],

View File

@@ -1,5 +1,8 @@
{
"config": {
"abort": {
"already_configured": "Ja est\u00e0 configurada un integraci\u00f3 Airly amb aquestes coordenades."
},
"error": {
"auth": "La clau API no \u00e9s correcta.",
"name_exists": "El nom ja existeix.",

View File

@@ -1,9 +1,12 @@
{
"config": {
"abort": {
"already_configured": "Airly-integration for disse koordinater er allerede konfigureret."
},
"error": {
"auth": "API-n\u00f8glen er ikke korrekt.",
"name_exists": "Navnet findes allerede.",
"wrong_location": "Ingen Airly m\u00e5lestationer i dette omr\u00e5de."
"wrong_location": "Ingen Airly-m\u00e5lestationer i dette omr\u00e5de."
},
"step": {
"user": {
@@ -13,7 +16,7 @@
"longitude": "L\u00e6ngdegrad",
"name": "Integrationens navn"
},
"description": "Konfigurer Airly luftkvalitet integration. For at generere API-n\u00f8gle, g\u00e5 til https://developer.airly.eu/register",
"description": "Konfigurer Airly luftkvalitetsintegration. For at generere API-n\u00f8gle, g\u00e5 til https://developer.airly.eu/register",
"title": "Airly"
}
},

View File

@@ -1,5 +1,8 @@
{
"config": {
"abort": {
"already_configured": "Die Airly-Integration ist f\u00fcr diese Koordinaten bereits konfiguriert."
},
"error": {
"auth": "Der API-Schl\u00fcssel ist nicht korrekt.",
"name_exists": "Name existiert bereits",

View File

@@ -1,5 +1,8 @@
{
"config": {
"abort": {
"already_configured": "Airly integration for these coordinates is already configured."
},
"error": {
"auth": "API key is not correct.",
"name_exists": "Name already exists.",

View File

@@ -0,0 +1,22 @@
{
"config": {
"error": {
"auth": "La clave API no es correcta.",
"name_exists": "El nombre ya existe.",
"wrong_location": "No hay estaciones de medici\u00f3n Airly en esta \u00e1rea."
},
"step": {
"user": {
"data": {
"api_key": "Clave API de Airly",
"latitude": "Latitud",
"longitude": "Longitud",
"name": "Nombre de la integraci\u00f3n"
},
"description": "Configure la integraci\u00f3n de la calidad del aire de Airly. Para generar la clave API, vaya a https://developer.airly.eu/register",
"title": "Airly"
}
},
"title": "Airly"
}
}

View File

@@ -1,5 +1,8 @@
{
"config": {
"abort": {
"already_configured": "La integraci\u00f3n a\u00e9rea para estas coordenadas ya est\u00e1 configurada."
},
"error": {
"auth": "La clave de la API no es correcta.",
"name_exists": "El nombre ya existe.",

View File

@@ -1,5 +1,8 @@
{
"config": {
"abort": {
"already_configured": "L'int\u00e9gration des coordonn\u00e9es d'Airly est d\u00e9j\u00e0 configur\u00e9."
},
"error": {
"auth": "La cl\u00e9 API n'est pas correcte.",
"name_exists": "Le nom existe d\u00e9j\u00e0.",

View File

@@ -0,0 +1,25 @@
{
"config": {
"abort": {
"already_configured": "Ezen koordin\u00e1t\u00e1k Airly integr\u00e1ci\u00f3ja m\u00e1r konfigur\u00e1lva van."
},
"error": {
"auth": "Az API kulcs nem megfelel\u0151.",
"name_exists": "A n\u00e9v m\u00e1r l\u00e9tezik",
"wrong_location": "Ezen a ter\u00fcleten nincs Airly m\u00e9r\u0151\u00e1llom\u00e1s."
},
"step": {
"user": {
"data": {
"api_key": "Airly API kulcs",
"latitude": "Sz\u00e9less\u00e9g",
"longitude": "Hossz\u00fas\u00e1g",
"name": "Az integr\u00e1ci\u00f3 neve"
},
"description": "Az Airly leveg\u0151min\u0151s\u00e9gi integr\u00e1ci\u00f3j\u00e1nak be\u00e1ll\u00edt\u00e1sa. Api-kulcs l\u00e9trehoz\u00e1s\u00e1hoz nyissa meg a k\u00f6vetkez\u0151 weboldalt: https://developer.airly.eu/register",
"title": "Airly"
}
},
"title": "Airly"
}
}

View File

@@ -1,5 +1,8 @@
{
"config": {
"abort": {
"already_configured": "L'integrazione Airly per queste coordinate \u00e8 gi\u00e0 configurata."
},
"error": {
"auth": "La chiave API non \u00e8 corretta.",
"name_exists": "Il nome \u00e8 gi\u00e0 esistente",

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