Commit Graph
23521 Commits
Author SHA1 Message Date
Robert SvenssonandAndrew Sayre 2b26af89df Improve tests based on Martins feedback from Axis improve tests (#30442) 2020-01-03 12:23:17 -06:00
Marcelo Moreira de MelloandAndrew Sayre e7af759330 Bump ring to 0.2.9 (#30439) 2020-01-03 12:19:14 -06:00
Robert SvenssonandGitHub ec61342ec3 deCONZ - Improve tests based on Martins feedback in Axis integration (#30438) 2020-01-03 18:11:04 +01:00
Josh AndersonandPaulus Schoutsen 8a1fc8b8f0 Check status field for UPS online binary sensor (#30144)
Avoids issue where status was previously reported as offline when
battery was low or UPS was over voltage
2020-01-03 17:40:36 +01:00
Jc2kandPaulus Schoutsen 6b519499a7 Don't expose flows that aren't initialised. (#30432)
* Don't expose flows that aren't initialised.

If a flow init does not return immediately then there is a window where our
behaviour is screwy:

 * Can try to configure a flow that isn't ready
 * Can show notifications for discoveries that might yet return an abort

This moves the flow discovery events and notifications to after the flow is
initialised and hides flows that don't have a cur_step from async_progress

* Fix tradfri test

* Black.

* Lint fixes
2020-01-03 17:28:05 +01:00
Jc2kandGitHub df6c7b97f5 isort homekit (#30437) 2020-01-03 15:00:44 +00:00
Robert SvenssonandGitHub 536b201472 WIP deCONZ - Support Fyrtur/Kadrilj battery sensors (#30403)
* Sensor.binary is None means unsupported sensor
* Don't create ordinary sensor on ZHABattery type
2020-01-03 15:15:32 +01:00
Bas NijholtandMartin Hjelmare 0d5486f772 Add KEF speakers integration (#28959)
* add KEF speakers platform for the integration

This will work with the KEF LS50 Wireless and KEF LSX speakers.
The development of this code happened on https://github.com/basnijholt/media_player.kef

* rename DATA_KEF -> DOMAIN

* use aiokef v0.2.0 and support LSX and new features

* sort imports

* fix @MartinHjelmare's suggestions

* remove _CONFIGURING

* change STATE_UNKNOWN to None

* use lat and long for unique_id

* bump aiokef to v0.2.2

* use config[ATTR] instead of config.get(ATTR)

* use getmac

* fix case when MAC is None

* use host as instance lifetime id

* fix requirements
2020-01-03 14:59:44 +01:00
Ville SkyttäandPaulus Schoutsen fa4fa30461 Various string cleanups (#30435)
* Remove some unnecessary string concatenations

* Replace some simple str.formats with f-strings

* Replace some string concatenations with f-strings
2020-01-03 14:47:06 +01:00
SérgioandCharles Garwood 5ad209c6fd Handle telegram event commands with args (#30254)
* Handle telegram event commands with args

* Parse message regargless of command

* Lint

* Use multiple assignment
2020-01-03 08:22:14 -05:00
David KandCharles Garwood 859935e8bc Update HomeKit position state characteristic for covers (#27867)
* HomeKit: update position state characteristic for covers

position state is a mandatory characteristic for HK window coverings

* Test position state characteristic
2020-01-03 08:19:03 -05:00
Robert SvenssonandMartin Hjelmare b57da2f862 Axis - Improve tests based on feedback (#30430)
* Use MockConfigEntry, add_to_hass and hass.config_entries.async_setup

* Mock method instead of handling paths
2020-01-03 13:27:14 +01:00
Joakim PlateandPaulus Schoutsen 0944d02262 Mark API key as deprecated (#30402)
Service account should be used instead
2020-01-03 12:12:29 +01:00
Ian DuffyandPaulus Schoutsen 5580ee3fa1 Don't allow badly formed upnp devices to kill auto discovery (#30342)
Prevent the following from occurring:

```
2019-12-31 22:38:41 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 85, in async_init
    return await self._async_handle_step(flow, flow.init_step, data)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 145, in _async_handle_step
    result: Dict = await getattr(flow, method)(user_input)
  File "/usr/src/homeassistant/homeassistant/components/deconz/config_flow.py", line 182, in async_step_ssdp
    if discovery_info[ssdp.ATTR_UPNP_MANUFACTURER_URL] != DECONZ_MANUFACTURERURL:
KeyError: 'manufacturerURL'
2019-12-31 22:38:41 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 85, in async_init
    return await self._async_handle_step(flow, flow.init_step, data)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 145, in _async_handle_step
    result: Dict = await getattr(flow, method)(user_input)
  File "/usr/src/homeassistant/homeassistant/components/deconz/config_flow.py", line 182, in async_step_ssdp
    if discovery_info[ssdp.ATTR_UPNP_MANUFACTURER_URL] != DECONZ_MANUFACTURERURL:
KeyError: 'manufacturerURL'
```
2020-01-03 12:08:40 +01:00
Stefan AgnerandPaulus Schoutsen 3f33fc6122 convert to integer if rounding precision is zero (#30226)
Convert values to integer if rounding precision is zero. With that a
value which is an integer before filtering can be configured to stay
integer when using precision = 0. This also aligns behavior of filters
to how rounding behaves in tempaltes (homeassistant/helpers/template.py,
function forgiving_round).
2020-01-03 11:54:19 +01:00
Jc2kandPaulus Schoutsen fdfedd086b Rework FlowManager to use inheritance (#30133)
* Pull async_finish_flow/async_create_flow out of ConfigEntries

* Towards refactoring

* mypy fixes

* Mark Flow manager with abc.* annotations

* Flake8 fixes

* Mypy fixes

* Blacken data_entry_flow

* Blacken longer signatures caused by mypy changes

* test fixes

* Test fixes

* Fix typo

* Avoid protected member lint (W0212) in config_entries

* More protected member fixes

* Missing await
2020-01-03 11:52:01 +01:00
Robert SvenssonandPaulus Schoutsen 0a4f3ec1ec Use config entry unique id for deCONZ (#30122)
* Use config entry unique id

* Clean up

* Backwards compatiblity note

* Fix some of Balloobs comments

* Bump dependency to v66

* Black somehow missed config flow tests...

* Move set unique ID til after possibility to update existing entry
2020-01-03 11:50:53 +01:00
Ville SkyttäandPaulus Schoutsen c130e81638 Fix number of times seen in debug message (#30429) 2020-01-03 11:31:50 +01:00
tetienneandPaulus Schoutsen f5aa89dd06 Fix set tilt position (#30428) 2020-01-03 11:31:05 +01:00
ochlocracyandPaulus Schoutsen 3a18ef219b Add RTSP stream support for UVC (Unifi Video Client) integration (#30297)
* Add SUPPORT_STREAM to supported_features.

* Implement stream_source with channel RTSP URIs.

* Add Tests for Stream Support.

* Make stream_source async.

* Removed unused import.

* Re-wrote test to remove warning, and lint error.
2020-01-03 11:30:26 +01:00
OliverandAndrew Sayre b097a64010 Implemented media_play & media_pause / push to version 0.7.11 of denonavr (#30421)
* Implement media_play & media_pause / push to version 0.7.11 of denonavr

* fix denonavr version in requirements_test_all.txt
2020-01-02 22:06:33 -06:00
David F. MulcaheyandAlexei Chetroi ef8eefc7a0 Remove ZHA establish device mappings function (#30423)
* remove establish_device_mappings
* inline init
2020-01-02 21:21:09 -05:00
Josh BendavidandMartin Hjelmare 4c6e10a988 Cleanup of state handling in webostv (#30416)
* cleanup unnecessary manipulation of state variables

* update unit test
2020-01-03 02:46:32 +01:00
HomeAssistant Azure 4bf15a07a3 [ci skip] Translation update 2020-01-03 00:32:16 +00:00
Robert SvenssonandGitHub 9b961632af Axis - Improve tests (#30415) 2020-01-03 00:02:59 +01:00
Josh Bendavidandspringstan c1936f6fe4 Add generic command/button functionality to webostv (#30379)
* add generic command/button functionality to webostv

* update codeowners
2020-01-02 22:32:56 +01:00
Josh Bendavidandspringstan 9064058a03 Add generic command functionality to denonavr (#29295)
* Add generic command functionality to denonavr

* add minimal unit tests for denonavr

* fix import order

* simplify denonavr unit test

* handle domain specific service calls with dispatcher

* update unit tests

* update unit tests

* remove unnecessary return value

* fix handling of mock instances in unit tests
2020-01-02 22:30:20 +01:00
michaeldavieandAndrew Sayre b91cbb50c8 Bump env_canada to 0.0.31 (#30409) 2020-01-02 15:24:43 -06:00
springstanandAndrew Sayre 8e5ccfcb8a Bump miflora and bluepy (#30411) 2020-01-02 15:24:29 -06:00
Franck NijhofandAndrew Sayre 4f8663846b Migrate frontend tests from coroutine to async/await (#30386) 2020-01-02 14:23:56 -06:00
Franck NijhofandAndrew Sayre 4e6d415541 Migrate media_player tests from coroutine to async/await (#30387) 2020-01-02 14:23:35 -06:00
Franck NijhofandAndrew Sayre b9fcb87d2c Migrate generic tests from coroutine to async/await (#30388) 2020-01-02 14:23:16 -06:00
Franck NijhofandAndrew Sayre 1e3822bdd7 Migrate group tests from coroutine to async/await (#30389) 2020-01-02 14:22:49 -06:00
Franck NijhofandAndrew Sayre 332cbbd8b1 Migrate freedns tests from coroutine to async/await (#30390) 2020-01-02 14:22:30 -06:00
Franck NijhofandAndrew Sayre 5b2b86987b Migrate fido tests from coroutine to async/await (#30391) 2020-01-02 14:22:13 -06:00
Franck NijhofandAndrew Sayre 7b00e94184 Migrate local_file tests from coroutine to async/await (#30392) 2020-01-02 14:21:54 -06:00
Aaron David SchneiderandAndrew Sayre 5edf72c9ea fix issuecomment-570284682 (#30405) 2020-01-02 14:17:37 -06:00
Franck NijhofandAndrew Sayre 24d5e54eed Bump pre-commit to 1.21.0 (#30406) 2020-01-02 14:16:58 -06:00
Ville SkyttäandGitHub e6388e186c Remove unnecessary string literal concatenations (#30360) 2020-01-02 21:17:10 +02:00
Ernst KlamerandMartin Hjelmare cac750066a Remove unnessecary rfxtrx light property def (#30397) 2020-01-02 16:44:29 +01:00
Ernst KlamerandDaniel Høyer Iversen 77978a979b Restore state for Rfxtrx devices (#30309)
* Restore state rfxtrx switch

* Restore state RFXtrx lights

* Restore state RFXtrx covers

* Restore comment

* Remove line

* Remove logging

* fix black

* Fix typo
2020-01-02 07:59:13 +01:00
HomeAssistant Azure 769cf19052 [ci skip] Translation update 2020-01-02 00:32:24 +00:00
Alan TseandMartin Hjelmare fc08c62a31 Add charging rate sensor to Tesla (#30286)
* Add charging rate sensor to Tesla

* Remove reference to bin_type
2020-01-02 00:36:14 +01:00
Franck NijhofandAndrew Sayre 37d1771400 Migrate google_* tests from coroutine to async/await (#30377) 2020-01-01 17:24:30 -06:00
Franck NijhofandAndrew Sayre bcb47dab45 Migrate discovery tests from coroutine to async/await (#30376) 2020-01-01 17:22:32 -06:00
Franck NijhofandAndrew Sayre b43b50b6d2 Migrate ffmpeg tests from coroutine to async/await (#30375) 2020-01-01 17:22:08 -06:00
Franck NijhofandAndrew Sayre c5298dc4dc Migrate cast tests from coroutine to async/await (#30374) 2020-01-01 17:21:42 -06:00
Franck NijhofandAndrew Sayre c837f185f7 Migrate camera tests from coroutine to async/await (#30372) 2020-01-01 17:21:21 -06:00
Franck NijhofandAndrew Sayre 8814e1eadc Migrate no_ip tests from coroutine to async/await (#30370) 2020-01-01 17:18:40 -06:00
Franck NijhofandAndrew Sayre 47aa0043bf Migrate owntracks tests from coroutine to async/await (#30369) 2020-01-01 17:18:20 -06:00