Commit Graph

1581 Commits (ed62fe03b0044129aa1a32dd75f2642e0cb63f34)

Author SHA1 Message Date
Paulus Schoutsen 9d38413e7c
Upgrade hass-cloud to 0.34 (#33789) 2020-04-07 09:59:04 -07:00
Chris Talkington 1f7803c541
Catch IPPParseError during config flow (#33769)
* Update config_flow.py

* Update strings.json

* Update config_flow.py

* squash.
2020-04-07 09:32:43 -07:00
J. Nick Koston 894aac1b45
Update nexia for thermostats without zoning (#33770)
* Bump nexia to 0.8.0
2020-04-07 10:33:43 -05:00
Aaron Bach 648b340e8c
Bump simplisafe-python to 9.0.6 (#33762) 2020-04-07 00:28:42 +02:00
Aaron Bach 98e7865457
Bump aioambient to 1.1.1 (#33761) 2020-04-06 15:14:27 -07:00
J. Nick Koston cf563df42a
Bump HAP-python to 2.8.1 (#33756) 2020-04-06 23:30:10 +02:00
Bram Kragten 2dbd8cf72c
Bump frontend (#33751) 2020-04-06 13:23:22 -07:00
Quentame d99e228983
Add config flow to Synology DSM (#32704)
* Add config flow to Synology DSM

* Use proper sensor unique ID from flow + sensor name

* Add description to api_version

* Add authentication flow check

* Add device_info

* Add test_login_failed test

* Bump python-synology to 0.5.0

* 0.5.0 test updates

* Use NAS S/N as config_flow unique_id

* Add missed conf disks + volumes

* Review: async_unload the async_track_time_interval

* Fix NoneType for disks or volumes

* Keep all disks and volumes forever

* Update homeassistant/components/synology_dsm/.translations/en.json

Co-Authored-By: J. Nick Koston <nick@koston.org>

* Update homeassistant/components/synology_dsm/strings.json

Co-Authored-By: J. Nick Koston <nick@koston.org>

* Fix "Keep all disks and volumes forever" for empty import

* Fix prettier

* Remove useless LOGGER in config flow

* Fix Synology DSM tests doing I/O

Co-authored-by: J. Nick Koston <nick@koston.org>
2020-04-05 17:50:52 -05:00
Malachi Soord 3f0936f068
Prevent last.fm errors with None (#33446) 2020-04-05 18:03:13 +02:00
Michal Ziemski 8d3a415d07
Add OpenERZ API integration (#30441)
* Adding OpenERZ integration

* Added unit tests

* Linter fixes, better friendly_name handling

* Increase coverage

* Review fixes

* fixup! Review fixes

* Refactor to use external openerz-api library

* fixup! Refactor to use external openerz-api library

* fixup! Refactor to use external openerz-api library

* fixup! Refactor to use external openerz-api library

* fixup! Refactor to use external openerz-api library
2020-04-05 05:04:41 +02:00
Alexei Chetroi 39a01fcdc6
Update zha dependencies (#33639) 2020-04-04 12:58:43 -04:00
Franck Nijhof 46fa20411e
Bump twentemilieu to 0.3.0 (#33622)
* Bump twentemilieu to 0.3.0

* Fix tests
2020-04-04 14:51:12 +02:00
Vilppu Vuorinen 4a9f4f585d
Update pymelcloud to fix broken area device search (#33620)
Devices assigned to areas in MELCloud were not available through the
integration due to client lib bug.
2020-04-04 13:56:48 +02:00
Maciej Bieniek b60527c986
Change the method of getting the mac address in the braviatv i… (#33567)
* Remove getmac library

* Fix error handling

* Change error handling method
2020-04-03 22:44:28 -07:00
Bram Kragten 6f7bd673fb
Updated frontend to 20200403.0 (#33586) 2020-04-03 10:32:00 -07:00
shred86 b8e9e3af2f
Add Abode entity available property (#32923)
* Add available property and raise exception

* Add entity available property

* Refactoring and fixes

* Refactoring and fix for multi sensor

* Bump abodepy version
2020-04-03 11:08:32 -05:00
Franck Nijhof dd37c3f447
Bump adguardhome to 0.4.2 (#33575) 2020-04-03 15:51:28 +02:00
Jc2k 730d90fb8c
Fix browsing regression (#33572) 2020-04-03 14:36:10 +02:00
Maciej Bieniek b5c89b4ef4
Bump gios library to version 0.1.1 (#33569) 2020-04-03 11:58:37 +02:00
Fabian Affolter 2d751c1edd
Upgrade luftdaten to 0.6.4 (#33564) 2020-04-03 11:13:48 +02:00
Raman Gupta 081b822d25
Add support for Vizio sound mode (#33200)
* add sound mode support for devices that support it

* make setting and unsetting flag better

* move eq and audio settings into constants

* fix missed statement to use constant instead of hardcoded string

* further fixes based on review

* bump pyvizio version to include newly identified app
2020-04-02 22:48:19 -04:00
Chris Talkington 2b0bdd580c
Update to pyipp==0.8.3 (#33554)
* Update manifest.json

* Update requirements_all.txt

* Update requirements_test_all.txt
2020-04-02 17:09:38 -07:00
Teemu R e64104300f
Use backend-provided fan speed presets for Xiaomi vacuums, bum… (#32850)
* Use backend-provided fan speed presets for Xiaomi vacuums

This needs input from Xiaomi vacuum owners to verify that it does not break anything.
I have personally tested this on rockrobo v1 (old mapping).

Related issues/PRs:
home-assistant/core#32821
home-assistant/core#31268
home-assistant/core#27268

This is a WIP as it requires a new upstream release.
The PR is https://github.com/rytilahti/python-miio/pull/643

* Bump version requirement for 0.5.0

* Bump requirements_test_all.txt, too

* Fix linting; missing setup.cfg on local checkout caused wrong settings for black..

* Add tests for both fan speed types

* Remove useless else..

* bump python-miio to 0.5.0.1 due to broken 0.5.0 packaging
2020-04-02 16:55:44 -07:00
Aaron Bach cb058ff6c0
Add config entry for Flu Near You (#32858)
* Add config flow for Flu Near You

* Cleanup

* Cleanup

* Add tests

* Add test requirements

* Code review

* Reduce unnecessary async-ness

* Handle API registration

* Cleanup

* Update homeassistant/components/flunearyou/.translations/en.json

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

* Code review

* Ensure config schema allows additional keys

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-04-02 16:54:11 -07:00
J. Nick Koston 36a606f81d
Bump HAP-python to 2.8.0 (#33539) 2020-04-02 23:09:35 +02:00
Chris Talkington b719a77503 Bump pyipp to 0.8.2 (#33544) 2020-04-02 22:46:31 +02:00
Ziv 39408ab240
Add cover platform to Dynalite (#32594)
* lib version

* unit-test refactoring

* added type hints

* added cover

* added test to see that consts have the same value as library consts

* Update tests/components/dynalite/test_init.py

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

* removed trigger template

* Update homeassistant/components/dynalite/__init__.py

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

* Update homeassistant/components/dynalite/const.py

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

* removed CONF_TRIGGER from const
corrected type hints - not clear why mypy didn't catch it

* conversion of the config to library CONFs

* moved to use the value since it should come from the library

* taking CONF_HOST from homeassistant.const instead of module const

* use dict.get
removed leftover log

* force device_class to be from homeassistant consts

* move dict.get to inline

* removed CONF from values
changed "channelcover" to "channel_cover"

* moved some CONF values out of const.py and taking them from homeassistant.const

* verifying that device class is a valid HA device class

* moved shutter to home assistant const

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-04-02 20:26:36 +02:00
mvn23 1d89d22a38
Update pyotgw to 0.6b1 (#33529) 2020-04-02 10:29:41 -07:00
Chris Talkington 30fd9950e2
Add remote platform to directv (#32790)
* add remote platform to directv.

* Update __init__.py

* Update .coveragerc

* Rename remote py to remote.py

* Update remote.py

* squash.

* Update remote.py

* squash.

* Update remote.py
2020-04-02 10:18:53 -07:00
Maciej Bieniek 5a55d50879
Bump brother to 0.1.11 (#33526) 2020-04-02 13:52:03 +02:00
Chris Talkington be3cf52613
Update to roku==4.1.0 (#33520)
* Update manifest.json

* Update requirements_test_all.txt

* Update requirements_all.txt
2020-04-02 10:09:59 +02:00
Paulus Schoutsen 7ae802bb0d
Cloud do checks during setup (#33507)
* Update cloud to do more tasks during async_setup

* Upgrade hass_nabucasa to 0.33
2020-04-01 15:25:04 -07:00
Bram Kragten 400602a8b3
Updated frontend to 20200401.0 (#33505) 2020-04-01 11:27:01 -07:00
Alexei Chetroi 0e6aacb440
Bump up zha dependencies. (#33488) 2020-03-31 23:33:05 -04:00
J. Nick Koston cc443ff37a
Add config flow for nut (#33457)
* Convert nut to config flow

* Add a test for importing

* lint

* Address review items (part 1)

* Address review items (part 1)

* Cleanup unique id handling

* Update tests for new naming scheme

* No unique id, no device_info

* Remove sensor types

* Update tests to use resources that still exist
2020-03-31 19:08:27 -07:00
Chris Talkington b892dbc6ea
Refactor DirecTV Integration to Async (#33114)
* switch to directv==0.1.1

* work on directv async.

* Update const.py

* Update __init__.py

* Update media_player.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update media_player.py

* Update test_config_flow.py

* Update media_player.py

* Update media_player.py

* work on tests and coverage.

* Update __init__.py

* Update __init__.py

* squash.
2020-03-31 15:35:32 -07:00
J. Nick Koston 3566803d2e
Fix setting zone overlays for tados that support swing (#33439)
* Fix setting zone overlays for tados that support swing

* Support for changing swing mode will come at a later
time as another upstream update is required.

* remove debug

* style
2020-03-31 17:29:45 -05:00
Chris Caron be99f3bf32
Bumped Apprise version to v0.8.5 (#33473) 2020-03-31 22:30:27 +02:00
J. Nick Koston e6ed2f0377
Add version and device type to powerwall device_info (#33453)
* Add version and device type to powerwall device_info

* Upstream powerwall now supports a http_session
2020-03-31 12:55:50 -07:00
Balazs Sandor 7330e30fd3
bump version zigpy-cc (#33448) 2020-03-30 20:33:07 -04:00
Chris Talkington 98f68f4798
Add Internet Printing Protocol (IPP) integration (#32859)
* Create __init__.py

* Create manifest.json

* Update zeroconf.py

* more work on integration

* more work on integration.

* add more sensor tests.

* Update const.py

* Update sensor.py

* more work on ipp.

* Update test_config_flow.py

* more work on ipp.

* Update config_flow.py

* Update config_flow.py
2020-03-30 16:13:47 -07:00
Bram Kragten 531207e005
Updated frontend to 20200330.0 (#33449) 2020-03-30 14:20:14 -07:00
J. Nick Koston f42804805c
Move Tado zone state handling into upstream python-tado library (#33195)
* Tado climate state moved to python-tado

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

* Write state instead of calling for an update

This is a redux of pr #32564 with all of the zone state now moved into
python-tado and tests added for the various states.

* stale string

* add missing undos to dispachers

* remove unneeded hass

* naming

* rearrange

* fix water heater, add test

* fix water heater, add test

* switch hvac mode when changing temp if in auto/off/smart
2020-03-30 09:06:26 -05:00
Aaron Bach fe0db80fb8
Bump aioambient to 1.1.0 (#33414) 2020-03-30 00:28:37 +02:00
Jc2k ad3c5240c2
Bump aiohomekit version to fix Ecobee Switch (#33396) 2020-03-29 22:38:52 +02:00
jjlawren 68e86c5e3a
Handle Ecobee service timeouts (#33381)
* Bump pyecobee to 0.2.4

* Bump pyecobee to 0.2.5
2020-03-29 22:15:12 +02:00
jan iversen dd3cd95954
Modbus patch, to allow communication with "slow" equipment using tcp (#32557)
* modbus: bumb pymodbus version to 2.3.0

pymodbus version 1.5.2 did not support asyncio, and in general
the async handling have been improved a lot in version 2.3.0.

updated core/requirement*txt

* updated core/CODEOWNERS

committing result of 'python3 -m script.hassfest'.

* modbus: change core connection to async

change setup() --> async_setup and update() --> async_update()

Use async_setup_platform() to complete the async connection to core.

listen for EVENT_HOMEASSISTANT_START happens in async_setup()
so it needs to be async_listen.

But listen for EVENT_HOMEASSISTANT_STOP happens in start_modbus()
which is a sync. function so it continues to be listen().

* modbus: move setup of pymodbus into modbushub

setup of pymodbus is logically connected to the class modbushub,
therefore move it into the class.

Delay construction of pymodbus client until event
EVENT_HOMEASSISTANT_START arrives.

* modbus: use pymodbus async library

convert pymodbus calls to refer to the async library.

Remark: connect() is no longer needed, it is done when constructing
the client. There are also automatic reconnect.

* modbus: use async update for read/write

Use async functions for read/write from pymodbus.

change thread.Lock() to asyncio.Lock()

* Modbus: patch for slow tcp equipment

When connecting, via Modbus-TCP, so some equipment (like the
huawei sun2000 inverter), they need time to prepare the protocol.

Solution is to add a asyncio.sleep(x) after the connect() and before
sending the first message.

Add optional parameter "delay" to Modbus configuration.
Default is 0, which means do not execute asyncio.sleep().

* Modbus: silence pylint false positive

pylint does not accept that a class construction __new__
can return a tuple.

* Modbus: move constants to const.py

Create const.py with constants only used in
the modbus integration.

Duplicate entries are removed, but NOT any entry that would
lead to a configuration change.

Some entries were the same but with different names, in this
case renaming is done.

Also correct the tests.

* Modbus: move connection error handling to ModbusHub

Connection error handling depends on the hub, not the
entity, therefore it is logical to have the handling in
ModbusHub.

All pymodbus call are added to 2 generic functions (read/write)
in order not to duplicate the error handling code.

Added property "available" to signal if the hub is connected.

* Modbus: CI cleanup

Solve CI problems.

* Modbus: remove close of client

close() no longer exist in the pymodbus library, use
del client instead.

* Modbus: correct review comments

Adjust code based on review comments.

* Modbus: remove twister dependency

Pymodbus in asyncio mode do not use twister but still throws a
warning if twister is not installed, this warning goes into
homeassistant.log and can thus cause confusion among users.

However installing twister just to avoid the warning is not
the best solution, therefore removing dependency on twister.

* Modbus: review, remove comments.

remove commented out code.
2020-03-29 12:39:30 -05:00
jjlawren ffafcf27a8
plexwebsocket bump 0.0.7 to fix ignored tests (#33398)
* Bump plexwebsocket to 0.0.7

* Remove unnecessary test ignores
2020-03-29 12:14:42 -04:00
tiagofreire-pt 21098bc3e5
Upgrade broadlink to 0.13.0 (#33240)
* Upgrading the broadlink library version to 0.13.0

As stated here: https://pypi.org/project/broadlink/

* Update requirements_test_all.txt

* Update requirements_all.txt

* Delete requirements_test_all.txt

* Revert "Delete requirements_test_all.txt"

This reverts commit 008f6f2030.

* Revert "Revert "Delete requirements_test_all.txt""

This reverts commit 73e22fd0ff.

* Revert "Revert "Revert "Delete requirements_test_all.txt"""

This reverts commit 7662119c89.
2020-03-29 13:03:46 +02:00
J. Nick Koston 00c38c5f70
Bump nexia to 0.7.3 (#33311)
* Resolves not being able to see the compressor speed.
2020-03-27 15:40:54 -05:00
J. Nick Koston 18a4829314
Config flow for elkm1 (#33297)
* Config flow for elkm1

* As entity ids can now be changed, the “alarm_control_panel”
attribute “changed_by_entity_id” is now “changed_by_keypad”
and will show the name of the Elk keypad instead of the entity id.

* An auto configure mode has been introduced which avoids the
need to setup the complex include and exclude filters.  This
functionality still exists when configuring from yaml for power
users who want more control over which entities elkm1 generates.

* restore _has_all_unique_prefixes

* preserve legacy behavior of creating alarm_control_panels that have no linked keypads when auto_configure is False

* unroll loop
2020-03-27 15:38:35 -05:00
J. Nick Koston b8afb9277a
Bump nexia to 0.7.2 (#33292)
* Bump nexia to 0.7.2

* Fixes zones on the same thermostat showing as active
when the damper was closed.

* Update test for nexia 0.7.2
2020-03-26 15:14:35 -07:00
Maciej Bieniek 815d153e55
Bump gios library to version 0.0.5 (#33266) 2020-03-25 16:24:28 -07:00
Pascal Vizeli 8f4d3146c1
Revert "Fix issue with smhi-pkg" (#33259)
* Revert "Fix issue with smhi-pkg (#33248)"

This reverts commit 6990c70123.

* Bump version to 1.0.13
2020-03-25 21:43:29 +01:00
Raman Gupta d5f4dfdd6b
Update vizio app_id state attribute to show app config dict in… (#32727)
* bump pyvizio and update app_id to show app config to aid in HA config generation. squashed from multiple commits to make a rebase on dev easier

* bump pyvizio for bug fixes

* fix pyvizio version number

* only return app_id if app is unknown and explicitly create the dict that's returned

* fix tests

* fix docstring for app_id
2020-03-25 09:35:36 -07:00
Fabian Affolter 4a0a56ebdc
Upgrade hole to 0.5.1 (#33249) 2020-03-25 17:22:34 +01:00
Eugenio Panadero bb68e7a532
Bump aiohue version to 2.1.0 (#33234) 2020-03-25 09:11:00 -07:00
Ron Klinkien 109f083c5d
Add Body Composition data to Garmin Connect (#32841)
* Added support for Garmin index smart scale

* Added body composition data

* Added keyerror exception

* Code optimization

* Update library, changed logger errors to exception

* Fixed manifest
2020-03-24 10:29:40 -07:00
Oliver 9226589bcd
Bump to version 0.8.1 of denonavr (#33169)
* Bump to version 0.8.1 of denonavr

* Update CODEWONERS file
2020-03-24 13:03:22 +01:00
Pascal Vizeli e616ab5fb2
Bump OZW fork to 0.1.10 (#33205) 2020-03-24 12:04:33 +01:00
elmurato 45241e57ca
Add support for Minecraft SRV records (#32372)
* Added support for Minecraft SRV records

* Switched from dnspython to aiodns, improved server ping and log messages, use address instead of host and port in config flow

* Updated component requirements
2020-03-23 16:51:13 -07:00
Olivier B 4332cbe112
Add Tesla sentry mode switch (#32938)
* Add Tesla sentry mode switch

* add available property, fix is_on

* bump teslajsonpy to 0.6.0
2020-03-23 10:52:59 +01:00
J. Nick Koston f9a7c64106
Config flow for doorbird (#33165)
* Config flow for doorbird

* Discoverable via zeroconf

* Fix zeroconf test

* add missing return

* Add a test for legacy over ride url (will go away when refactored to cloud hooks)

* Update homeassistant/components/doorbird/__init__.py

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

* without getting the hooks its not so useful

* Update homeassistant/components/doorbird/config_flow.py

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

* fix copy pasta

* remove identifiers since its in connections

* self review fixes

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-23 10:14:21 +01:00
Quentame 0249daef2e
Bump iCloud to 0.9.6.1 (#33161) 2020-03-22 21:05:27 +01:00
Eugenio Panadero 8d2e72cdf6
Add pvpc electricity prices integration (#32092)
* Add new integration: pvpc_hourly_pricing

to add a sensor with the current hourly price of electricity in Spain.
Configuration is done by selecting one of the 3 reference tariffs, with
1, 2, or 3 billing periods.

* Features config flow, entity registry, RestoreEntity, options flow
  to change tariff, manual yaml config as integration or sensor platform
* Cloud polling sensor with minimal API calls (3/hour at random times)
  and smart retry; fully async
* Only 1 state change / hour (only when the price changes)
* At evening, try to download published tomorrow prices, to always store
  prices info for a window of [3, 27] hours in the future.
* Include useful state attributes to program automations to be run
  at best electric prices.
* Add spanish and english translations.

* Requires `xmltodict` to parse official xml file with hourly prices
for each day.

* Update requirements and add to codeowners

* Avoid passing in hass as a parameter to the entity

Instead, create time change listeners in async_added_to_hass and
call async_generate_entity_id before async_add_entities

* Fix lint issues

* Add tests for config & options flow

* Add tests for manual yaml config

with entity definition as integration and also as a sensor platform

* Fix placement of PLATFORM_SCHEMA and update generated config_flows

* Store prices internally linked to UTC timestamps

- to deal with days with DST changes
- and work with different local timezones

* Add availability to sensor

to 'expire' the sensor if there is no connection available
 and current hour is not in the stored prices.

Also, turn off logging and retrying if prices can't be downloaded
repeatedly, by flagging `data_source_available` as False, so there is no
log-flood mess.

* Add more tests

- to cover behavior in DST changes and complete coverage of sensor logic
- to cover abort config flow

* fix linter

* Better handling of sensor availability and minor enhancements

- Emmit 1 error if data source is marked as unavailable
  (after some retries), and be silent until cloud access is recovered,
  then emmit 1 warning.
- Follow standard of camel_case keys in attributes

* Mock aiosession to not access real API, store fixture data

- Store a set of daily xml files to test sensor logic for all situations
- Mock time and session to run tests with stored API responses
- Add availability test to simulate a lost + recovery of cloud access,
  checking that logging is reasonable: 1 error to flag the continued
  disconnection + 1 warning in recovery.

* Change API endpoint to retrieve JSON data

and remove xmltodict from reqs.

It seems that this endpoint is more reliable than the XML.

* Adapt tests to new API endpoint

* Translate tariff labels to plain English

and sync the default timeout value for all ways of configuration.

* Relax logging levels to meet silver requirements

- 1 warning when becoming unavailable, another warning when recovered.
- Warnings for unexpected TimeoutError or ClientError
- Move the rest to debug level, leaving info for HA internals

Also reduce number of API calls from 3 to 2 calls/hour.

* Fix requirements

* Mod tests to work with timezone Atlantic/Canary

and fix state attributes for timezones != reference, by using 3 price
prefixes: 'price_last_day_XXh', 'price_next_day_XXh' and 'price_XXh',
all generated with local time (backend timezone)

* Try to fix CI tests

* Externalize pvpc data and simplify sensor.py

* add new `aiopvpc` to requirements
* Remove data parsing and price logic from here
* Replace some constant properties with class variables

* Simplify tests for pvpc_hourly_pricing

* Fix updater for options flow

* Updater always reloads
* `tariff` value comes 1st from entry.options, 2nd from entry.data

* Fix lint

* Bump aiopvpc

* Remove options flow and platform setup

- Remove PLATFORM_SCHEMA and async_setup_platform
- Generate config_entry.unique_id with tariff instead of entity_id, in flow step.
- Remove TariffSelectorConfigFlow
- Adapt tests to maintain full coverage

* Fix docstring on test

and rename SENSOR_SCHEMA to SINGLE_SENSOR_SCHEMA to avoid confusion

* Remove timeout manual config, fix entry.options usage, simplify unique_id

* Simplify tests

- No need for a test_setup now, as platform setup is removed and integration
  setup is already used in `test_availability`
- Simplified `_process_time_step`: only one async_fire(EVENT_TIME_CHANGED)/hour

* Fix possible duplicated update

when source is not available.

* Do not access State last_changed for log messages

* Do not update until entity is added to hass

and call to async_update after 1st download or when recovering access, so
async_write_ha_state is not called twice on those.

* minor changes

* Rename method to select current price and make it a callback
2020-03-22 14:25:31 -05:00
Maciej Bieniek 9d87c1ab1a
Bump gios to 0.0.4 (#33141) 2020-03-22 13:44:57 +01:00
jjlawren 99877c32b1
Bump pyecobee to 0.2.3 (#33130) 2020-03-22 13:19:26 +01:00
guillempages 99d732b974
Revert "Validate UUID for tankerkoenig (#32805)" (#33123)
This reverts commit 49c2a4a4e3.
The validation was causing more problems than it was fixing, so removed
it completely
2020-03-21 17:48:18 -07:00
Aaron Bach 403b4a2e0b
Bump simplisafe-python to 9.0.5 (#33116) 2020-03-21 16:01:39 -06:00
Anders Melchiorsen 699ca44260
Clean up Sonos attributes for radio streams (#33063) 2020-03-21 12:17:00 -07:00
Franck Nijhof a7b08c48f3
Upgrade spotipy to 2.10.0 (#33083) 2020-03-21 19:25:29 +01:00
Balazs Sandor e18bea0215
bump version zigpy-cc (#33097) 2020-03-21 10:43:55 -04:00
guillempages 49c2a4a4e3
Validate UUID for tankerkoenig (#32805)
* Validate UUIDs against custom validator

Instead of just validating against strings, use a custom validator,
so that the format can be checked.

* Add tests for custom UUID4 validator
2020-03-21 09:43:12 -05:00
J. Nick Koston 85328399e0
Add support for nexia automations (#33049)
* Add support for nexia automations

Bump nexia to 0.7.1

Start adding tests

Fix some of the climate attributes that were wrong (discovered while adding tests)

Pass the name of the instance so the nexia UI does not display "My Mobile"

* fix mocking

* faster asserts, scene

* scene makes so much more sense

* pylint

* Update homeassistant/components/nexia/scene.py

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

* docstring cleanup

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-03-20 18:49:42 -05:00
Aaron Bach 836413a4a8
Bump simplisafe-python to 9.0.4 (#33059) 2020-03-20 14:59:01 -06:00
Knapoc c2ac8e813a
Bump aioasuswrt to 1.2.3 and fix asuswrt sensor (#33064)
* Bump aioasuswrt to 1.2.3

* Fix asuswrt connection setup parameters

* fix typo
2020-03-20 21:34:17 +01:00
J. Nick Koston 37687561c0
Add config flow for myq (#32890)
* Add a config flow for myq

* Discovered by homekit

* Fix gates being treated as garage doors

* Offline devices now show as unavailable

* Homekit flow

* strip out icon

* return -> raise
2020-03-20 15:28:14 -05:00
Steven Rollason ecbcdee934
Bump pyhaversion to 3.3.0 (#33044) 2020-03-20 15:58:23 +01:00
J. Nick Koston f275b7e5ed
Add Nexia thermostat support (Trane / American Standard) (#32826)
* Merge nexia

* Restore original work

* Merge cleanups

* config flow

* Add config flow

* Add missing files

* Fix import of old yaml config

* More cleanups from self review

* Additional self review

* Update homeassistant/components/nexia/services.yaml

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

* fix io in event loop

* Update homeassistant/components/nexia/climate.py

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

* avoid using ternary statements if they span multiple

* Cleanup strings and remove unneeded attributes

* more cleanup

* more cleanup of yaml

* remove coordinator boiler plate

* nuke services for now for the inital pr, add back later

* remove copy pasta

* this can be reduced more

* Update homeassistant/components/nexia/config_flow.py

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

* Update homeassistant/components/nexia/config_flow.py

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

* Update homeassistant/components/nexia/__init__.py

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

* Update homeassistant/components/nexia/__init__.py

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

* Update homeassistant/components/nexia/__init__.py

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

* Update homeassistant/components/nexia/__init__.py

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

* review

* comments

* Update homeassistant/components/nexia/climate.py

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

* Update homeassistant/components/nexia/climate.py

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

* Update homeassistant/components/nexia/climate.py

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

* more review adjustments

* nuke unused constants

* Update homeassistant/components/nexia/config_flow.py

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

* map states

* add update

* zone id is unique

* Fix humidfy check

* target_humidity should be a property instead of in attributes

* remove aux heat as its already there

Co-authored-by: Ryan Nazaretian <ryannazaretian@gmail.com>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-03-19 21:03:51 -05:00
Jc2k 84712d2f40
Bump aiohomekit to fix Insignia NS-CH1XGO8 and Lennox S30 (#33014) 2020-03-19 16:25:18 -07:00
Aaron Bach 23045af4a7
Bump simplisafe-python to 9.0.3 (#33013) 2020-03-19 16:39:24 -06:00
Robin 9451920ab5
Fix sighthound dependency issue (#33010) 2020-03-19 20:34:15 +01:00
Balazs Sandor 62f2ee5f60
Bump version of zigpy-cc to 0.2.3 (#32951) 2020-03-19 11:42:49 -05:00
J. Nick Koston d33a3ca90f
Config flow for harmony (#32919)
* Config flow for harmony

* Fixes unique ids when using XMPP

Co-authored-by: Bram Kragten <mail@bramkragten.nl>

* Find the unique id for the config flow

* move shutdown to init

* Add test for ssdp (still failing)

* Fix ssdp test

* Add harmony to MIGRATED_SERVICE_HANDLERS (this is a breaking change)

* more cleanups

* use unique id for the config file

Co-authored-by: Bram Kragten <mail@bramkragten.nl>
2020-03-19 11:29:51 -05:00
J. Nick Koston 5b4d2aed64
Add Powerwalls integration (#32851)
* Create an integration for Powerwalls

* Self review :: remove unused code

* Remove debug

* Update homeassistant/components/powerwall/__init__.py

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

* _call_site_info to module level

* Update homeassistant/components/powerwall/binary_sensor.py

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

* Update homeassistant/components/powerwall/sensor.py

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

* Update homeassistant/components/powerwall/binary_sensor.py

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

* Update homeassistant/components/powerwall/binary_sensor.py

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

* Update tests/components/powerwall/test_binary_sensor.py

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

* Update homeassistant/components/powerwall/binary_sensor.py

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

* Update homeassistant/components/powerwall/binary_sensor.py

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

* remove sensors that I added tests for from the comment

* Update homeassistant/components/powerwall/config_flow.py

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

* Update homeassistant/components/powerwall/sensor.py

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

* Update homeassistant/components/powerwall/sensor.py

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

* Update homeassistant/components/powerwall/sensor.py

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

* Switch to UNIT_PERCENTAGE

* reduce code

* Add test for import

* Adjust tests

* Add missing file

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-03-19 10:50:17 -05:00
Maikel Punie 03c906a2f1
Fix velbus in the 107 release (#32936)
velbus 2.0.41 introduced some data files in the python module. They are not copied when installing the velbus module. 2.0.43 fixes this problem
2020-03-19 01:56:32 -05:00
Bram Kragten ede0cfaeb8
Updated frontend to 20200318.1 (#32957) 2020-03-18 17:13:19 -07:00
Jc2k 7c79adad8f
Refactor and simplify homekit_controller entity setup (#32927) 2020-03-18 10:12:55 -05:00
Bram Kragten 7d23a734fc
Updated frontend to 20200318.0 (#32931) 2020-03-18 13:02:27 +01:00
Franck Nijhof aece76f6cd
Bump wled 0.3.0, reduce calls stability improvements (#32903) 2020-03-17 20:17:59 +01:00
Paulus Schoutsen ff582721dd
Bump cast to 4.2.0 (#32906) 2020-03-17 10:30:56 -07:00
Quentame 4c32fd12fc
Bump iCloud to 0.9.5 (#32901) 2020-03-17 17:46:30 +01:00
Bram Kragten 682fcec99e
Updated frontend to 20200316.1 (#32878) 2020-03-16 14:27:20 -07:00
David F. Mulcahey 41cd3ba532
Bump ZHA quirks to 0.0.37 (#32867) 2020-03-16 15:29:14 -04:00
Bram Kragten f4b3760a1a
Updated frontend to 20200316.0 (#32866) 2020-03-16 13:30:59 +01:00
Maciej Bieniek b9ad40ed38
Bump brother to 0.1.9 (#32861) 2020-03-16 12:00:39 +01:00
Pascal Vizeli 451c6c25cd
Update pyozw 0.1.9 (#32864) 2020-03-16 11:40:21 +01:00
Chris Talkington cf8dfdae47
Add config flow to roku (#31988)
* create a dedicated const.py

* add DEFAULT_PORT to const.py

* work on config flow conversion.

* remove discovery.

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

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

* add quality scale to manifest.

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

* review tweaks.

* Update manifest.json

* catch more specific errors

* catch more errors.

* impprt specific exceptions

* import specific exceptions

* Update __init__.py

* Update config_flow.py

* Update media_player.py

* Update remote.py

* Update media_player.py

* Update remote.py

* Update media_player.py

* Update remote.py

* Update config_flow.py

* Update config_flow.py

* Update media_player.py

* Update __init__.py

* Update __init__.py

* Update config_flow.py

* Update test_config_flow.py

* Update config_flow.py

* Update __init__.py

* Update test_config_flow.py

* Update remote.py

* Update test_init.py

* Update test_init.py

* Update media_player.py

* Update media_player.py

* Update media_player.py
2020-03-15 21:13:04 -07:00
Alan Tse 6e95b90f42
Bump teslajsonpy to 0.5.1 (#32827) 2020-03-15 20:42:07 -07:00
Jc2k 6affb27711
Fix homekit_controller beta connectivity issues (#32810) 2020-03-14 23:34:29 +01:00
Ville Skyttä d04479044c
Upgrade huawei-lte-api to 1.4.11 (#32791)
https://github.com/Salamek/huawei-lte-api/releases/tag/1.4.11
2020-03-14 11:37:44 +01:00
J. Nick Koston 7737387efe
Add config flow for rachio (#32757)
* Do not fail when a user has a controller with shared access on their account

* Add config flow for rachio

Also discoverable via homekit

* Update homeassistant/components/rachio/switch.py

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

* Split setting the default run time to an options flow

Ensue the run time coming from yaml gets imported into the option flow

Only get the schedule once at setup instead of each zone (was hitting rate limits)

Add the config entry id to the end of the webhook so there is a unique hook per config entry

Breakout the slew of exceptions rachiopy can throw into RachioAPIExceptions

Remove the base url override as an option for the config flow

Switch identifer for device_info to serial number

Add connections to device_info (mac address)

* rename to make pylint happy

* Fix import of custom_url

* claim rachio

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-13 22:46:17 -07:00
Bram Kragten 460857a765
Updated frontend to 20200313.0 (#32777) 2020-03-13 13:43:39 -07:00
J. Nick Koston e2a113a2de
Bump py-august to 0.25.0 (#32769)
Fixes a bug in the conversion to async where code validation failed.
2020-03-13 18:07:53 +01:00
Franck Nijhof 11a25157c1
Upgrade sqlalchemy to 1.3.15 (#32747) 2020-03-13 00:28:26 +01:00
Bram Kragten a3dd9979d2
Updated frontend to 20200312.0 (#32741) 2020-03-12 14:41:04 -07:00
J. Nick Koston ac30e5799c
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 10:31:55 +01:00
Quentame 19be4a5d6d
Refactor Freebox : add config flow + temperature sensor + signal dispatch (#30334)
* Add config flow to Freebox

* Add manufacturer in device_tracker info

* Add device_info to sensor + switch

* Add device_info: connections

* Add config_flow test + update .coveragerc

* Typing

* Add device_type icon

* Remove one error log

* Fix pylint

* Add myself as CODEOWNER

* Handle sync in one place

* Separate the Freebox[Router/Device/Sensor] from __init__.py

* Add link step to config flow

* Make temperature sensors auto-discovered

* Use device activity instead of reachablility for device_tracker

* Store token file in .storage

Depending on host if list of Freebox integration on the future without breaking change

* Remove IP sensors + add Freebox router as a device with attrs : IPs, conection type, uptime, version & serial

* Add sensor should_poll=False

* Test typing

* Handle devices with no name

* None is the default for data

* Fix comment

* Use config_entry.unique_id

* Add async_unload_entry with asyncio

* Add and use bunch of data size and rate related constants (#31781)

* Review

* Remove useless "already_configured" error string

* Review : merge 2 device & 2 sensor classes

* Entities from platforms

* Fix unload + add device after setup + clean loggers

* async_add_entities True

* Review

* Use pathlib + refactor get_api

* device_tracker set + tests with CoroutineMock()

* Removing active & reachable from tracker attrs

* Review

* Fix pipeline

* typing

* typing

* typing

* Raise ConfigEntryNotReady when HttpRequestError at setup

* Review

* Multiple Freebox s

* Review: store sensors in router

* Freebox: a sensor story
2020-03-11 22:15:59 +01:00
Chris Talkington cea5cac6e2
Update directpy==0.7 for directv. (#32694) 2020-03-11 20:33:02 +01:00
Bram Kragten c9a9bd16fe
Updated frontend to 20200311.1 (#32691) 2020-03-11 12:18:11 -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
Bram Kragten 99109d162b
Updated frontend to 20200311.0 (#32675) 2020-03-11 12:10:00 +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
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
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
Paulus Schoutsen a3c55b5e96
Upgrade to coronavirus 1.1.0 (#32648) 2020-03-10 11:47:07 -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
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
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
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
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
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
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
jey burrows 5ace7de171
Bump rflink to 0.0.52 (#32588) 2020-03-09 09:35:54 +01:00
Oliver 963b5db763
Bump denonavr to 0.8.0 (#32578) 2020-03-08 23:43:12 +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
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
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
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
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
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 7b5b909f0a
ZHA Dependencies bump (#32483)
* ZHA Dependencies bump.

* Bump up ZHA dependencies.
2020-03-04 17:35:07 -08: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
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
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
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
Robert Svensson 02c8cd07f3
UniFi - Fix websocket bug (#32449) 2020-03-03 17:32:13 -08:00
Maciej Bieniek 2f8381b1bf
Bump brother library (#32436) 2020-03-03 16:59:02 +01: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
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
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
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
Alexei Chetroi 5fbaaf41dc
Bump up ZHA depdendency (#32336) 2020-02-28 19:13:49 -05:00
Bram Kragten 3dc1ece33c
Updated frontend to 20200220.5 (#32312) 2020-02-28 07:56:39 -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
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
Aaron Bach aab2fd5ec3
Bump simplisafe-python to 9.0.2 (#32273) 2020-02-27 12:18:26 -07:00
Aaron Bach df04fe3258
Bump simplisafe-python to 9.0.0 (#32215) 2020-02-26 18:52:07 -08:00
Jc2k 92a47f14bb
homekit_controller test cleanups (#32212) 2020-02-26 09:44:04 -08:00
Bram Kragten 5a67d73a37
Updated frontend to 20200220.4 (#32205) 2020-02-26 11:32:15 +01: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
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
Bram Kragten b0fdbebd56
Updated frontend to 20200220.3 (#32189) 2020-02-25 23:15:25 +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
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
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
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 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
Paulus Schoutsen 51b5796916
Updated frontend to 20200220.1 (#32046) 2020-02-20 14:51:27 -08:00
Paulus Schoutsen 20e3c91ebd
Updated frontend to 20200220.0 (#32033) 2020-02-20 11:01:20 -08: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
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
Daniel Perna 136ed12ec5
Update pyhomematic to 0.1.65 (#32006) 2020-02-19 22:27:50 -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
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
Bram Kragten e90d29ea36
Updated frontend to 20200219.0 (#31979) 2020-02-19 12:46:40 +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
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
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
Malte Franken 70910ecc61
Bump aio_geojson_geonetnz_quakes to 0.12 (#31930) 2020-02-17 15:30:31 -08:00
Bram Kragten e52adbb942
Updated frontend to 20200217.0 (#31922) 2020-02-17 22:03:42 +01:00
Aaron Bach 74f0262e82
Bump simplisafe-python to 8.1.1 (#31915) 2020-02-17 13:16:24 -07: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
SukramJ 2366b5f6ca
Bump dependency to 0.10.17 for HomematicIP Cloud (#31911) 2020-02-17 18:31:09 +01:00
Paulus Schoutsen b77f2670a7
Upgrade aiohue (#31903) 2020-02-17 09:52:54 +01:00
Maikel Punie e5e7c9fa25
Upgrade python-velbus to 2.0.41 (#31875) 2020-02-16 12:36:13 +01: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
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
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
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
Chris Talkington f9fda7d616
update directv to directpy==0.6 (#31812) 2020-02-13 17:47:16 -08: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
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
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
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
Diogo Gomes 787edf9417
pyipma version bump (#31739) 2020-02-11 17:37:48 -08: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
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
Maikel Punie 5a7e0b84ff
Bump velbus version + load velbus module names into device info (#31664) 2020-02-10 21:22:09 +01:00
Balazs Sandor 41f3fb291a Add ZHA Texas Instruments CC device support (#31621) 2020-02-09 12:13:22 -05:00
Oliver a5b4f43ea5 Bump denonavr to 0.7.12 (#31629) 2020-02-08 13:46:13 +01:00
Alexei Chetroi 57ab30d534 Bump ZHA dependencies. (#31619)
Bump up zigpy-homeassistant==0.13.2
2020-02-08 06:50:50 -05: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
MatthewFlamm f9e037a823
update pynws to 0.10.4 (#31591) 2020-02-07 09:16:56 -05:00
Franck Nijhof d093b5f5e8
Bump adguardhome to 0.4.1 (#31565) 2020-02-06 16:02:00 -08:00
Alexei Chetroi 0e68ace3dd
Bump ZHA dependencies. (#31555) 2020-02-06 16:34:28 -05:00
Josh Bendavid eee1ca9211
update aiopylgtv to 0.3.3 (#31545) 2020-02-06 10:00:54 -08: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 ba9892e1f1
Updated frontend to 20200130.2 (#31502) 2020-02-05 14:41:01 -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
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
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
Robert Svensson 883b8f21ce
deCONZ - Library cleanup (#31410)
* Follow library changes

* Bump dependency to v70

* Fix test
2020-02-02 19:07:20 +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
Fabian Affolter 48402d49dc
Upgrade praw to 6.5.1 (#31393) 2020-02-02 13:06:44 +01:00
Fabian Affolter 55a1bf3832
Upgrade holidays to 0.10.1 (#31392) 2020-02-02 02:17:24 -08: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
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
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
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
Bram Kragten 0a1e397119
Updated frontend to 20200130.0 (#31318) 2020-01-30 09:30:59 -08:00
Alexei Chetroi 24f4f53f16
ZHA dependencies bump (#31295)
* ZHA dependencies bump.

* Bump bellows-homeassistant.
2020-01-30 10:04:06 -05: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
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
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
Pascal Vizeli 28bfc6ae76
Update homeassistant-pyozw to 0.1.8 (#31270) 2020-01-29 12:04:05 +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
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
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
Franck Nijhof 6be9a45333
Upgrade HAP-python to 2.7.0 (#31201) 2020-01-27 11:42:09 +01:00