1
mirror of https://github.com/home-assistant/core synced 2024-10-07 10:13:38 +02:00
Commit Graph

237 Commits

Author SHA1 Message Date
Dermot Duffy
7ad2a6be30
Add hyperion config options flow (#43673) 2020-11-30 18:38:52 +01:00
Ron Klinkien
ea52ffc2d9
Add FireServiceRota/BrandweerRooster integration (#38206)
Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-11-25 16:38:49 +01:00
starkillerOG
0c30abda61
Add Motion Blinds integration (#42989)
Co-authored-by: J. Nick Koston <nick@koston.org>
2020-11-23 10:33:14 -10:00
Brig Lamoreaux
c42b1f65b3
Add Srp energy component (#41091) 2020-11-20 08:18:02 -05:00
David
f693c8a9fd
Add twinkly integration (#42103)
* Add twinkly integration

* Add tests for the Twinkly integration

* Update Twinkly client package to fix typo

* Remove support of configuration.yaml from Twinkly integration

* Add ability to unload Twinkly component from the UI

* Remove dead code from Twinkly

* Fix invalid error namespace in Twinkly for python 3.7

* Fix tests failing on CI

* Workaround code analysis issue

* Move twinkly client init out of entry setup so it can be re-used between entries

* Test the twinkly component initialization

* React to PR review and add few more tests
2020-11-19 12:22:12 -05:00
Aaron Bach
24840cce23
Add a config flow for Recollect Waste (#43063)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-11-12 11:00:42 +01:00
djtimca
d47b3a5f44
Fix Aurora integration including externalizing API to PyPi and adding config_flow (#43045)
Co-authored-by: Pawel <pszafer@gmail.com>
2020-11-11 20:36:16 +01:00
Pawel
df38c59dc8
Add config flow to epson and fix timeouts (#39697) 2020-11-07 18:15:29 +01:00
epenet
6ef53a2c5d
Add config flow for One wire (#39321)
* Add support for config_flow
Add support for switches
Add support for binary sensors

* Add config flow strings

* Update .coveragerc

* black-formatting

* fixes for isort and flake

* fixes for pylint

* fixes for isort

* fixes for isort

* fixes for config_flow

* Add devices to Device Registry

* Updated comments

* fixes for flake8

* Updated comments

* Updated comments

* Implement async_unload_entry

* remove binary_sensor and switch implementation (will move to new PR)

* Update .coveragerc

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update .coveragerc

* Review config flow to store the configuration type

* Add config_flow tests

* Move CONF_NAMES to constants

* Fix isort

* Tweak to onewire logger

* Tweak to onewire logger for sensor

* Reset _LOGGER variable

* Normalise header

* Normalise header

* Update to use references in config flow translations

* Improve test coverage

* fixes for isort

* Update async_unload_entry

* Update common strings

* Update imports

* Move connect attempt to executor

* Update common strings

* Remove OWFS from config_flow

* Prevent duplicate config entries

* Fix isort

* Fix flake8

* Fix tests following removal of OWFS implementation

* Fix flake8

* Adjust config from yaml to config-flow, and add ability to specify sysbus directory

* Ajust unique_id for config entries

* Fix test_config_flow

* Fix invalid merge

* Convert yaml to config_entry

* Update sysbus tests

* Tweaks to yaml import process, and add OWFS warning

* Enable migration of OWFS platform config to config_entry

* update the existing corresponding config entry on OWFS conversion

* Remove CONFIG_SCHEMA

* Move data_schema to constants

* Remove log message

* Remove duplicate warning

* Update already_configured to use already_configured_device constant

* Schedule get_entities on the executor

* Update duplicate entry check for OWServer

* Review TryCatch

* Schedule os.path.isdir on the executor

* rename owhost/owport

* Update checks for empty

* Fix incorrect patch

* Move config_flow validation methods to new OneWireHub

* Fix typo and pre-commit

* Cleanup try/else

* patch async_setup/async_setup_entry

* cleanup implicit exit point

* Fix invalid patch

* cleanup implicit exit point

* cleanup implicit exit point

Co-authored-by: Chris Talkington <chris@talkingtontech.com>
2020-10-23 20:57:16 -05:00
Chris Talkington
d8577a1550
Add config flow for cloudflare (#41167)
* add config flow for cloudflare

* Create const.py

* work on flow.

* remove const.

* lint.

* Apply suggestions from code review

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

* Update config_flows.py

* Update homeassistant/components/cloudflare/strings.json

* Apply suggestions from code review

* Apply suggestions from code review

* Apply suggestions from code review

* Update strings.json

* Apply suggestions from code review

* Update __init__.py

* Update __init__.py

Co-authored-by: J. Nick Koston <nick@koston.org>
2020-10-21 09:09:00 -05:00
Maciej Bieniek
798f7d1c63
Fix zeroconf name (#41908) 2020-10-16 05:38:39 -05:00
Ville Skyttä
a9f342ef74
Convert UpCloud to config flow, improve error handling (#37941) 2020-10-15 23:26:01 +02:00
Clifford Roche
839b9f226e
Add gree climate integration (#37498)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-10-14 15:15:56 +02:00
Jason Hunter
9877e8e25b
Add Xbox Integration (#41697)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-10-13 15:37:01 +02:00
Brett
3e41c682f4
Add Advantage Air Integration (#40159)
Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-10-12 13:22:15 +02:00
Gabe Cook
4b617db669
Add Ruckus Unleashed integration (#40002)
* Add Ruckus Unleashed integration

* Tweak catches to better rely on CoordinatorEntity error handling, rename LoginError to AuthenticationError

* Make router_update be a callback function

* Make name property return hint match the newer value

* Add entity to tracked set when restoring on boot

* Add a device's MAC to the attributes
2020-10-10 13:01:53 +02:00
Erik Montnemery
343e5d64b8
Add MQTT integration discovery (#41332)
* Add MQTT integration discovery

* Add script/hassfest/mqtt.py

* Unsubscribe if config entry exists

* Add homeassistant/generated/mqtt.py

* Fix bad loop

* Improve tests

* Improve tests

* Apply suggestions from code review

Co-authored-by: Fabian Affolter <mail@fabian-affolter.ch>

* Prevent initiating multiple config flows

Co-authored-by: Fabian Affolter <mail@fabian-affolter.ch>
2020-10-07 18:30:51 +02:00
Martin Hjelmare
e006e0ddb3
Revert zoneminder config flow (#41395) 2020-10-07 16:28:49 +02:00
Erik Montnemery
06e9489fc7
Add Tasmota integration (#39624)
* Add Tasmota integration

* Refactor

* Add tests, small improvements

* isort

* Attempt to fix tests failing with Python 3.8

* Revert "Attempt to fix tests failing with Python 3.8"

This reverts commit 11454f8a00136f068ea27204183fa3e62f3cd263.

* Fix tests failing with Python 3.8

* Cleanup tests

* Address review comments

* Address review comments

* Address review comments

* Use MAC address for device identification

* Bump hatasmota

* Bump hatasmota

* Apply suggestions from code review

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

* Fix indentation

* Remove preparation for device remove WS API

* Address review comments

* Remove useless try-except

* Tweak

* Improve tests

* Tweak

* Address review comments

* Correct test

* Update manifest.json

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-10-06 14:51:58 +02:00
J. Nick Koston
494d4a262a
Add Profiler integration (#41175)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-10-05 07:57:07 -05:00
Rob Bierbooms
c5041b41c8
Implement config and option flow for rfxtrx integration (#39117)
* Create option flow for Rfxtrx integration (#37982)

* Implement config flow for rfxtrx integration (#39299)

* Add config flow

* Add strings

* Add first series of tests

* Add tests

* Adjust tests according review comments

* Adjust strings

* Add executor for testing connection

* Change ports to dict

* Fix pylint issue

* Adjust tests

* Migrate config entry for rfxtrx integration (#39528)

* Add rfxtrx device connection validation when importing (#39582)

* Implement import connection validation

* Fix binary sensor tests

* Move rfxtrx data

* Fix cover tests

* Fix test init

* Fix light tests

* Fix sensor tests

* Fix switch tests

* Refactor rfxtrx test data

* Fix strings

* Fix check

* Rework device string in test code

* Add option to delete multiple rfxtrx devices (#39625)

* Opt to remove multiple devices

* Fix devices key

* Add tests (phase 1)

* Add tests (phase 2)

* Tweak remove devices test

* Implement device migration function in rfxtrx option flow (#39694)

* Prompt option to replace device

* Revert unwanted changes

* Add replace device function

* WIP replace entities

* Remove device/entities and update config entry

* Fix styling

* Add info

* Add test

* Fix strings

* Refactor building migration map

* Allow migration for all device types

* Add test to migrate control device

* Fixup some names

* Fixup entry names in test code

* Bump pyRFXtrx to 0.26 and deprecate debug config key (#40679)

* Create option flow for Rfxtrx integration (#37982)

* Implement config flow for rfxtrx integration (#39299)

* Add config flow

* Add strings

* Add first series of tests

* Add tests

* Adjust tests according review comments

* Adjust strings

* Add executor for testing connection

* Change ports to dict

* Fix pylint issue

* Adjust tests

* Migrate config entry for rfxtrx integration (#39528)

* Add rfxtrx device connection validation when importing (#39582)

* Implement import connection validation

* Fix binary sensor tests

* Move rfxtrx data

* Fix cover tests

* Fix test init

* Fix light tests

* Fix sensor tests

* Fix switch tests

* Refactor rfxtrx test data

* Fix strings

* Fix check

* Rework device string in test code

* Add option to delete multiple rfxtrx devices (#39625)

* Opt to remove multiple devices

* Fix devices key

* Add tests (phase 1)

* Add tests (phase 2)

* Tweak remove devices test

* Implement device migration function in rfxtrx option flow (#39694)

* Prompt option to replace device

* Revert unwanted changes

* Add replace device function

* WIP replace entities

* Remove device/entities and update config entry

* Fix styling

* Add info

* Add test

* Fix strings

* Refactor building migration map

* Allow migration for all device types

* Add test to migrate control device

* Fixup some names

* Fixup entry names in test code

* Bump version number

* Remove debug key from connect

* Remove debug option from config flow

* Remove debug from tests

* Fix event test

* Add cv.deprecated

* Fix test

* Fix config schema

* Add timeout on connection

* Rework config schema

* Fix schema...again

* Prevent creation of duplicate device in rfxtrx option flow (#40656)
2020-10-01 08:55:57 +02:00
tkdrob
67a7b28c84
Add Integration for Goal Zero Yeti Power Stations (#39231)
* Add Integration for Goal Zero Yeti Power Stations

* Goal Zero Yeti integration with config flow

* Remove unused entities

* Remove entry from requirements_test_all

* Pylint fix

* Apply suggestions from code review

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

* Add tests for goalzero integration

* Fix UNIT_PERCENTAGE to PERCENTAGE

* isort PERCENTAGE

* Add tests

* Add en translation

* Fix tests

* bump goalzero to 0.1.1

* fix await

* bump goalzero to 0.1.2

* Update tests/components/goalzero/__init__.py

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

* apply recommended changes

* isort

* bump goalzero to 0.1.4

* apply recommended changes

* apply recommended changes

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
Co-authored-by: J. Nick Koston <nick@koston.org>
2020-09-27 12:44:21 -05:00
Oliver Acevedo
0c12af347e
Add Omnilogic integration (#40474)
* Scaffold

* Added the en translation

* Modified the name

* Basic functionality for config flow.

* Pulled in enough to validate config flow works.

* Update manifest.json

* initial data polling (water and air temp sensors)

* Adding sensors, debugging update function

* polling updates working

* support for new data format from library

* Updated entity_id, friendly name, conversion for ppm, attributes for hayward display units, MSPSystemID and component systemID

* Fixed errors for PR

* clean up

* Add login exc, check if configured, test login.

* Remove debug print.

* Black formatting, ran isort, update requirements.

* Updated w isort. fix flake8 failures.

* Fix flake8 errors

* Fixed self.attrs to remove invalid self._ values - small change

* Missed on small change - fixing attributes

* Updated naming, updated unit of measure, updated icon, bumped omnilog…

* Updated to fix flake8 issues in __init__.py and config_flow.py

* Updated test_config_flow.py to pass, updated config_flow.py to correct errors in test

* Remove comments in preparation for PR

* update .covezragerc

* Formatting fix

* Rewrote sensors to dynamically add all BOWs, pumps, clorinators. Still to do - add CSAD sensors.

* Rewrote sensors to dynamically add all BOWs, pumps, clorinators. Still to do - add CSAD sensors.

* Added CSAD sensors for pools that have them.

* Added CSAD sensors for pools that have them.

* Fixed CSAD to not create if blank or don't exist, removed broad except usage to pass linting.

* Updated entity naming convention. Fixed linting issues.

* Added device association to the back yard / omnilogic system

* Removed .0 from ppm values when returning imperial values for salt sensor

* Updated to return state = None for water temp when pump is off, handled Chlorinator operatingMode = 2, and added PlatformNotReady check

* Corrected exception from Omnilogic library

* Bumped omnilogic to 0.3.7. Added alarm sensor/data to sensors. Handle pump off condition for ph and orp sensors.

* Bumped omnilogic to 0.3.7. Added alarm sensor/data to sensors. Handle pump off condition for ph and orp sensors.

* Bumped omnilogic to 0.3.7. Added alarm sensor/data to sensors. Handle pump off condition for ph and orp sensors.

* Removed nested_lookup dependency, bumped omnilogic.py to 0.3.8.

* Fixed lint error

* Added logging for sensor creation.

* Fixed linting errors with logging.

* Fixed explicit chaining of raised error. Fixed issue with alarm sensor.

* Fixed manifest.json based on feedback.

* Fixed self.attrs, should_poll, CoordinatorEntity, SCAN_INTERVAL from comments in PR.

* Addressed unique_id, moved data update coordinator, addressed minor other issues from testing

* Created main OmniLogic entity for common items, reworked DataUpdateCoordinator to it's own class.

* Addressed config_schema not used in __init__.py

* Fixed linting issues.

* Addressed several comments, still todo - separate sensor classes.

* Split the Omnilogic Sensors into separate logical classes for simpler logic.

* Fixed snake case lint error for AddAlarms (to add_alarms)

* Addressed config_flow issues from comments.

* Changed addressed ConfigNotReady issue from comments.

* Updated strings.json and generated corrected en.json with translations.

* Updated en.json to standard generated file.

* Added config_flow tests and updated issue with config_flow on cannot_connect

* Added test case for incomplete information entered.

* Compressed logic in the sensor classes to reduce duplication.

* Updated strings.json for polling_interval, added generic exception handling on config flow.

* Removed omnilogic from the .coveragerc omit file.

* Updated test_config_flow to follow recommended pattern.

* Excluded sensor.py from test coverage tests.

* Corected minor issues in test_config_flow from comments

* Fixed linting issues on last commits

* Fixed linting issues.

* Corrected issue when temp state is not available from Omnilogic

* Added omnililogic_common.py from .coveragerc to bypass test coverage check.

* Return false on Login Exception, handle OmniLogicException in config_flow and in tests.

* Handle all exceptions and in config_flow and tests, clarified test naming.

* Broke out test cases per comments.

* Regenerated en.json file.

* Addressed changes from comments in PR.

* Added session and bumped API to 0.4.0, addressed other comments from PR.

* Addressed entitydata (missed earlier).

* Fixed pylint issue

* Added test case for options flow in test_config_flow.py

* Removed super() and used self when calling methods in current class.

* Addressed comments in PR.

* Addressed comments in PR.

* Updated translations file.

* Rewrote data coordinator to output dict for easy searching.

* Updated chlorinator unit when chlorinator is on/off only

* Scaffold

* Added the en translation

* Modified the name

* Basic functionality for config flow.

* Pulled in enough to validate config flow works.

* Update manifest.json

* initial data polling (water and air temp sensors)

* Adding sensors, debugging update function

* polling updates working

* support for new data format from library

* Updated entity_id, friendly name, conversion for ppm, attributes for hayward display units, MSPSystemID and component systemID

* Fixed errors for PR

* clean up

* Add login exc, check if configured, test login.

* Remove debug print.

* Black formatting, ran isort, update requirements.

* Updated w isort. fix flake8 failures.

* Fix flake8 errors

* Fixed self.attrs to remove invalid self._ values - small change

* Missed on small change - fixing attributes

* Updated naming, updated unit of measure, updated icon, bumped omnilog…

* Updated to fix flake8 issues in __init__.py and config_flow.py

* Updated test_config_flow.py to pass, updated config_flow.py to correct errors in test

* Remove comments in preparation for PR

* update .covezragerc

* Formatting fix

* Rewrote sensors to dynamically add all BOWs, pumps, clorinators. Still to do - add CSAD sensors.

* Rewrote sensors to dynamically add all BOWs, pumps, clorinators. Still to do - add CSAD sensors.

* Added CSAD sensors for pools that have them.

* Added CSAD sensors for pools that have them.

* Fixed CSAD to not create if blank or don't exist, removed broad except usage to pass linting.

* Updated entity naming convention. Fixed linting issues.

* Added device association to the back yard / omnilogic system

* Removed .0 from ppm values when returning imperial values for salt sensor

* Updated to return state = None for water temp when pump is off, handled Chlorinator operatingMode = 2, and added PlatformNotReady check

* Corrected exception from Omnilogic library

* Bumped omnilogic to 0.3.7. Added alarm sensor/data to sensors. Handle pump off condition for ph and orp sensors.

* Bumped omnilogic to 0.3.7. Added alarm sensor/data to sensors. Handle pump off condition for ph and orp sensors.

* Bumped omnilogic to 0.3.7. Added alarm sensor/data to sensors. Handle pump off condition for ph and orp sensors.

* Removed nested_lookup dependency, bumped omnilogic.py to 0.3.8.

* Fixed lint error

* Added logging for sensor creation.

* Fixed linting errors with logging.

* Fixed explicit chaining of raised error. Fixed issue with alarm sensor.

* Fixed manifest.json based on feedback.

* Fixed self.attrs, should_poll, CoordinatorEntity, SCAN_INTERVAL from comments in PR.

* Addressed unique_id, moved data update coordinator, addressed minor other issues from testing

* Created main OmniLogic entity for common items, reworked DataUpdateCoordinator to it's own class.

* Addressed config_schema not used in __init__.py

* Fixed linting issues.

* Addressed several comments, still todo - separate sensor classes.

* Split the Omnilogic Sensors into separate logical classes for simpler logic.

* Fixed snake case lint error for AddAlarms (to add_alarms)

* Addressed config_flow issues from comments.

* Changed addressed ConfigNotReady issue from comments.

* Updated strings.json and generated corrected en.json with translations.

* Updated en.json to standard generated file.

* Added config_flow tests and updated issue with config_flow on cannot_connect

* Added test case for incomplete information entered.

* Compressed logic in the sensor classes to reduce duplication.

* Updated strings.json for polling_interval, added generic exception handling on config flow.

* Removed omnilogic from the .coveragerc omit file.

* Updated test_config_flow to follow recommended pattern.

* Excluded sensor.py from test coverage tests.

* Corected minor issues in test_config_flow from comments

* Fixed linting issues on last commits

* Fixed linting issues.

* Corrected issue when temp state is not available from Omnilogic

* Added omnililogic_common.py from .coveragerc to bypass test coverage check.

* Return false on Login Exception, handle OmniLogicException in config_flow and in tests.

* Handle all exceptions and in config_flow and tests, clarified test naming.

* Broke out test cases per comments.

* Regenerated en.json file.

* Addressed changes from comments in PR.

* Added session and bumped API to 0.4.0, addressed other comments from PR.

* Addressed entitydata (missed earlier).

* Fixed pylint issue

* Added test case for options flow in test_config_flow.py

* Removed super() and used self when calling methods in current class.

* Addressed comments in PR.

* Addressed comments in PR.

* Updated translations file.

* Rewrote data coordinator to output dict for easy searching.

* Updated chlorinator unit when chlorinator is on/off only

* Fixed ORP method not being @property, fixed unique_id potential issue. Does not address comments from PR.

* Rewrote coordinator for updated dict structure, rewrote sensors to parse new data structure.

* Added alarms as attributes on all entities which support alarm reporting.

* Updated SENSOR_TYPES to sensor_types to adhere to snake case in pylint.

* Addressed PR comments.

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/sensor.py

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

* Removed binary sensor conditions (alarms, on/off sensor types) and added ability for multiple guard conditions

* Update homeassistant/components/omnilogic/sensor.py

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

* Updated per comments in PR for Pump Type and removal of force_update().

* Update homeassistant/components/omnilogic/sensor.py

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

* Update homeassistant/components/omnilogic/common.py

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

* Correctly asserting conditions for the login exception case.

* Update .coveragerc

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

Co-authored-by: Mike Hershberger <mike.hershberger@gmail.com>
Co-authored-by: Chad <54695185+chadlyy@users.noreply.github.com>
Co-authored-by: Tim Empringham <tim.empringham@live.ca>
Co-authored-by: djtimca <60706061+djtimca@users.noreply.github.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-09-25 17:55:10 +02:00
Chris Talkington
f563068ce6
Add config flow to canary (#40055)
* Create config_flow.py

* Update config_flow.py

* work on config flow

* Update test_config_flow.py

* Update __init__.py

* Update camera.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update config_flow.py

* Update conftest.py

* Update test_config_flow.py

* Update test_init.py

* Update test_init.py

* Apply suggestions from code review

* Update camera.py

* Update test_init.py

* Update camera.py

* Update __init__.py

* Update test_init.py

* Update test_init.py

* Update __init__.py

* Update __init__.py

* Apply suggestions from code review

* Update __init__.py

* Update test_init.py

* Update __init__.py

* Update __init__.py

* Update config_flow.py

* Update test_config_flow.py

* Update config_flow.py

* Update config_flow.py
2020-09-18 23:22:19 -05:00
Robert Van Gorkom
70173488a8
Add config support to zoneminder integration (#37060)
* Add config support to zoneminder integration.

* Fixing spelling issue.
Adding self to maintainers.
Updating config flows generated file.

* Maintain zoneminder functionality without breaking changes.

* Addressing lint feedback.
Updating code owners.

* Using non-blocking calls.

* Adding tests package file.

* Update service description.

Co-authored-by: Rohan Kapoor <rohan@rohankapoor.com>

* Resolving conflicts in requirements file.

* Resolving more conflicts.

* Addressing PR feedback.

* Merging from dev.

Co-authored-by: Rohan Kapoor <rohan@rohankapoor.com>
2020-09-16 22:58:51 -07:00
Xiaonan Shen
d26160c755
Add rpi_power integration (#35527)
Co-authored-by: Toast <swetoast@users.noreply.github.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-09-14 12:53:01 +02:00
AJ Schmidt
c32f698671
Add Config Flow to AlarmDecoder (#37998) 2020-09-13 12:29:25 -05:00
J. Nick Koston
9389a7c9be
Limit zeroconf discovery to name/macaddress when provided (#39877)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-09-11 12:19:21 +02:00
J. Nick Koston
047dc19351
Add zeroconf discovery to homekit (#39907)
Ensures HomeKit Bridge is offered for onboarding if
homekit is detected on the network.
2020-09-10 20:44:11 +02:00
J. Nick Koston
d7e471e244
Add HomeKit discovery for iSmartGate (#39702) 2020-09-06 12:56:38 -05:00
Evgeny
b0192cf9c0
Add OpenWeatherMap config_flow (#34659)
Co-authored-by: J. Nick Koston <nick@koston.org>
2020-09-04 18:22:50 -05:00
Xiaonan Shen
45a927ffb2
Add config flow to yeelight (#37191) 2020-08-31 16:40:56 +02:00
Arda ŞEREMET
e707b50658
Add integration for ProgettiHWSW automation boards (#37922)
* Opened a new fresh page to clean my mess.

* Solved pylint warnings

* Fixing pylint issue of defining attr outside init.

* Excluded files from being tested by codecov.

* Solved binary sensor error.

* Fixed some stylisation errors.

* Resolved input not updating problem.

* Added port entry to test file.

* Added tests for create_entry.

* Added support for better state management.

* Increased code coverage of config_flow.py & made some tweaks.

* Increased coverage of config_flow.py by adding tests for unknown exceptions.

* A small bugfix.

* Stylised code as per Chris' suggestions.

* Stylised code again.

* Improved quality of test code.

* Added step_id in config flow tests.
2020-08-30 15:03:33 -05:00
Andrew Marks
3d1ff5b8d0
Add sharkiq integration for Shark IQ robot vacuums (#38272)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-08-30 15:26:11 +02:00
Chris Talkington
7469f57a7b
Add config flow to nzbget (#38938)
* work on config flow

* Update test_init.py

* work on config flow

* Update test_config_flow.py

* Update test_config_flow.py

* Update __init__.py

* Update test_config_flow.py

* Update __init__.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Apply suggestions from code review

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

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update config_flow.py

* Update __init__.py

* Update __init__.py

* Create coordinator.py

* Update __init__.py

* Update sensor.py

* Update __init__.py

* Update .coveragerc

* Update coordinator.py

* Update __init__.py

* Update coordinator.py

* Update __init__.py

* Update coordinator.py

* Update config_flow.py

* Update __init__.py

* Update coordinator.py

* Update __init__.py

* Update test_config_flow.py

* Update coordinator.py

* Update test_config_flow.py

* Update test_init.py

* Update homeassistant/components/nzbget/coordinator.py

* Update test_config_flow.py

Co-authored-by: J. Nick Koston <nick@koston.org>
2020-08-29 16:47:00 -05:00
Leonardo Figueiro
a47f73244c
Add Wilight integration with SSDP (#36694)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-08-24 14:15:07 +02:00
Paulus Schoutsen
ca2bc9906d
Add Shelly integration (#39178) 2020-08-24 12:43:31 +02:00
On Freund
1b8d9f7cc4
Add Risco integration (#36930)
* Risco integration

* Fix lint errors

* Raise ConfigEntryNotReady if can't connect

* Gracefully handle shutdown

* pass session to pyrisco

* minor change to init

* Fix retries

* Add exception log

* Remove retries

* Address code review comments

* Remove log
2020-08-21 23:49:09 -05:00
Eric Severance
f01634f75c
Add wemo 'Socket' model for Homekit discovery (#38765)
Corresponds with the model WSP080 WiFi Smart Plug
https://www.belkin.com/us/p/P-WSP080/

```
[homeassistant.components.zeroconf] Discovered new device Wemo Plug 603._hap._tcp.local. {'host': '10.234.200.95', 'port': 54664, 'hostname': 'Wemo Plug 603.local.', 'type': '_hap._tcp.local.', 'name': 'Wemo Plug 603._hap._tcp.local.', 'properties': {'_raw': {'c#': b'2', 'ff': b'2', 'id': b'63:30:B3:10:BA:B1', 'md': b'Socket', 'pv': b'1.1', 's#': b'1', 'sf': b'1', 'ci': b'7', 'sh': b'AD4l7g=='}, 'c#': '2', 'ff': '2', 'id': '63:30:B3:10:BA:B1', 'md': 'Socket', 'pv': '1.1', 's#' : '1', 'sf': '1', 'ci': '7', 'sh': 'AD4l7g=='}}
```
2020-08-21 08:36:20 -06:00
On Freund
c1ed584f2d
Add config flow to kodi (#38551)
* Add config flow to kodi

* Fix lint errors

* Remove entry update listener

* Create test_init.py

* Apply suggestions from code review

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update __init__.py

* fix indentation

* Apply suggestions from code review

* Apply suggestions from code review

* Update tests/components/kodi/__init__.py

* Fix init test

* Fix merge

* More review changes

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Fix black formatting

* Fix Flake8

* Don't store CONF_ID

* Fall back to entry id

* Apply suggestions from code review

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

* Update __init__.py

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: Chris Talkington <chris@talkingtontech.com>
Co-authored-by: J. Nick Koston <nick@koston.org>
2020-08-20 23:16:58 -05:00
Felipe Martins Diel
a2c1f08c8c
Implement config flow in the Broadlink integration (#36914)
* Implement config flow in the Broadlink integration

* General improvements to the Broadlink config flow

* Remove unnecessary else after return

* Fix translations

* Rename device to device_entry

* Add tests for the config flow

* Improve docstrings

* Test we do not accept more than one config entry per device

* Improve helpers

* Allow empty packets

* Allow multiple config files for switches related to the same device

* Rename mock_device to mock_api

* General improvements

* Make new attempts before marking the device as unavailable

* Let the name be the template for the entity_id

* Handle OSError

* Test network unavailable in the configuration flow

* Rename lock attribute

* Update manifest.json

* Import devices from platforms

* Test import flow

* Add deprecation warnings

* General improvements

* Rename deprecate to discontinue

* Test device setup

* Add type attribute to mock api

* Test we handle an update failure at startup

* Remove BroadlinkDevice from tests

* Remove device.py from .coveragerc

* Add tests for the config flow

* Add tests for the device

* Test device registry and update listener

* Test MAC address validation

* Add tests for the device

* Extract domains and types to a helper function

* Do not patch integration details

* Add tests for the device

* Set device classes where appropriate

* Set an appropriate connection class

* Do not set device class for custom switches

* Fix tests and improve code readability

* Use RM4 to test authentication errors

* Handle BroadlinkException in the authentication
2020-08-20 17:30:41 +02:00
Graham Wetzler
bb164bb32c
Smart Meter Texas integration (#37966)
* Run scaffold script

* Update version

* Bump version

* Initial commit

* Move meter and ESIID to device attributes

* Update internal to hourly due to api limit

* Format with Black

* Fix typo

* Update tests

* Update description

* Disable Pylint error

* Don't commit translations

* Remove meter number from sensor name

* Allow multiple meters per account

* Move data updates to a DataUpdateCoordinator

* Use setdefault to setup the component

* Move strings to const.py

* Fix tests

* Remove meter last updated attribute

* Bump smart-meter-texas version

* Fix logger call

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

* Remove unneeded manifest keys

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

* Remove icon property

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

* Handle instance where user already setup an account

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

* Remove icon constant

* Fix indentation

* Handle config flow errors better

* Use ESIID + meter number as unique ID for sensor

* Update config flow tests to reach 100% coverage

* Avoid reading meters on startup

Cherrypick @bdraco's suggestion

* Run scaffold script

* Update version

* Bump version

* Initial commit

* Move meter and ESIID to device attributes

* Update internal to hourly due to api limit

* Format with Black

* Fix typo

* Update tests

* Update description

* Disable Pylint error

* Don't commit translations

* Remove meter number from sensor name

* Allow multiple meters per account

* Move data updates to a DataUpdateCoordinator

* Use setdefault to setup the component

* Move strings to const.py

* Fix tests

* Remove meter last updated attribute

* Bump smart-meter-texas version

* Fix logger call

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

* Remove unneeded manifest keys

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

* Remove icon property

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

* Handle instance where user already setup an account

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

* Remove icon constant

* Fix indentation

* Handle config flow errors better

* Use ESIID + meter number as unique ID for sensor

* Update config flow tests to reach 100% coverage

* Remove unnecessary try/except block

This checks for the same exception just prior in execution on L51.

* Remove unused return values

* Add tests

* Improve tests and coverage

* Use more pythonic control flow

* Remove all uses of hass.data

Co-authored-by: J. Nick Koston <nick@koston.org>
2020-08-19 13:16:45 -05:00
Greg Dowling
e9b50706a9
Add roon media player integration (#37553)
* Import roon code.

* Fix flake8/pylint issues.

* Fix lint issues, extend timeout, change contact infomation.

* Add new files to .coveragerc

* Make file executable.

* Fix problem with integration not working after initial creation.

* Improve logic unavailable players by caching data.

* Review changes

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

* Review changes

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

* Review changes

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

* Review changes

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

* Review changes

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

* Review changes

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

* Review changes

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

* Review changes

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

* Review changes

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

* Review changes

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

* Update review suggestions

* Rremove custom play action script.

* Add test requirements.

* Tidy manifest.

* Missed fixes.

* Refactor config_flow to use current pattern.

* Add config_flow tests.

* Refactor to use signal dispatch helpers.

* Remove ToDo: for now.

* Remove remaining zone / source logic for initial release,

* Stop authenticate blocking, handle timeout.

* Removed unneeded code.

* Review comments update.

* Fix comment.

* Apply suggestions from code review

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

* Apply suggestions from code review

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

* Fix bug in seek.

* Use sync rather than async update

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

* Upgrade library, remove exception now caught in library,

* Review comments.

* Review changes

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

* Check for duplicate host before adding.

* Review comment.

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

* Remove unused code, revise turn_on/turn_off.

* Sync translations.

* Make interim timeout const.

* Refactor tests.

* Add tests with an existing config entry.

* Apply suggestions from code review

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

* Remove CannotConnect

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-08-12 09:09:47 -04:00
Tom Harris
b1fd931cdc
Add config flow to insteon component (#36467)
* Squashed

* Fix requirements_all

* Update homeassistant/components/insteon/__init__.py

Only update options if the result is to create the entry.

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

* Update homeassistant/components/insteon/__init__.py

No return value needed.

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

* Ref RESULT_TYPE_CREATE_ENTRY correctly

* Return result back to import config process

* Make DOMAIN ref more clear

Co-authored-by: J. Nick Koston <nick@koston.org>
2020-08-11 18:04:44 -05:00
Jc2k
f82f815304
Add water level sensors provided by UK Environment Agency (#31954) 2020-08-10 15:51:04 +02:00
David F. Mulcahey
f1fd8aa51f
Add support for Flo by Moen water shutoff devices (#38171) 2020-08-10 14:19:38 +02:00
bsmappee
07de9deab6
Implement local discovery of Smappee legacy devices (#37812)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-08-10 13:34:18 +02:00
Marcio Granzotto Rodrigues
761067559d
Add Nightscout integration (#38615)
* Implement NightScout sensor integration

* Add tests for NightScout integration

* Fix Nightscout captalization

* Change quality scale for Nightscout

* Trigger actions

* Add missing tests

* Fix stale comments

* Fix Nightscout manufacturer

* Add entry type service

* Change host to URL on nightscout config flow

* Add ConfigEntryNotReady exception to nighscout init

* Remote platform_schema from nightscout sensor

* Update homeassistant/components/nightscout/config_flow.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

Co-authored-by: Chris Talkington <chris@talkingtontech.com>
2020-08-09 13:15:56 -05:00
Quentame
21f4d694bb
Remove Linky integration (#38565) 2020-08-06 11:18:05 +02:00
Aidan Timson
caca762088
OVO Energy Integration (#36104)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2020-08-05 14:38:29 +02:00