Commit Graph

18847 Commits (d659807b6fa26c6f9467fd1feb520b033dab842d)

Author SHA1 Message Date
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
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
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
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
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
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 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
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
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
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 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
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
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
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
Ville Skyttä 130571c478 Remove no longer needed auth.util, use secrets instead (#29861) 2019-12-12 16:46:33 +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
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
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
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 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 67c56c860d Sort imports according to PEP8 for 'homeassistant' folder (#29789)
Components are already done
2019-12-09 16:42:10 +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 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 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 16a7408f23 Sort imports according to PEP8 for zwave (#29658) 2019-12-09 12:29:12 +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 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 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 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 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