Commit Graph

25415 Commits (cc443ff37a52c5f6b1a24cb7c724ff492435f2e8)

Author SHA1 Message Date
Eugenio Panadero 94b6ab2862
Use platform tag to register components on hue SensorManager (#32732)
* Use platform tag to register components on hue SensorManager

instead of a boolean flag to decide between sensor and binary sensor,
so it could be used externally (or to get ready for inclusion of other comps)

* Make new item discovery platform agnostic for SensorManager
2020-03-12 18:31:39 -07:00
Paulus Schoutsen a66f4ca4ec Bumped version to 0.107.0b1 2020-03-12 17:02:38 -07:00
Bram Kragten 3345d85dca Updated frontend to 20200312.0 (#32741) 2020-03-12 17:02:29 -07:00
Raman Gupta 9ad776e55d Set self._current_app to None when vizio device is off (#32725) 2020-03-12 17:02:29 -07:00
escoand 2f2a908573 Fix legacy Samsung TV (#32719)
* Update bridge.py

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

* check for None specifically

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

* F-string

* Add to properties

* Fixes
2020-03-12 17:02:26 -07:00
Aaron Bach 8db426e5da Broaden exception handling for IQVIA (#32708) 2020-03-12 17:02:25 -07:00
Franck Nijhof bfacd9a1c3 Remove deprecated hide_if_away from device trackers (#32705) 2020-03-12 17:02:24 -07:00
Barry Williams 943c7ee11a If device has volume disabled, the volume will be `None`. However in these (#32702)
instances whenever the volume was requested a division calculation was made
resulting in a TypeError. The volume adjustment from `0-100` to `0-1` is now
calculated during the `update()` method.
2020-03-12 17:02:23 -07:00
Franck Nijhof 11a25157c1
Upgrade sqlalchemy to 1.3.15 (#32747) 2020-03-13 00:28:26 +01:00
Franck Nijhof ff92a8b260
Add update class method to DataUpdateCoordinator (#32724)
* Add update class method to DataUpdateCoordinator

* Update homeassistant/helpers/update_coordinator.py

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

* Move update_method param

* Rename async_update_data to _async_update_data

* Raise NotImplementedError

* Re-raise NotImplementedError

* Remove caplog, not needed anymore

* Don't set last_update_success on NotImplementedError

* Fix test

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2020-03-13 00:27:19 +01:00
Paulus Schoutsen 1fe26c77e0
Sonos idle (#32712)
* Sonos idle

* F-string

* Add to properties

* Fixes
2020-03-12 14:47:57 -07:00
Franck Nijhof 00d5e5cfb2
Upgrade pre-commit to 2.2.0 (#32737) 2020-03-12 14:44:14 -07:00
Emilv2 c968e455a9
Fix delijn sensor stuck on last passage (#32710)
* Fix delijn sensor stuck on last passage

If the returned passage is an empty list that means there are
no next passages, so the sensor should be updated accordingly

* Mark the sensor as unavailable instead of emptying data

* use available property

* add available property
2020-03-12 14:43:52 -07:00
Bram Kragten a3dd9979d2
Updated frontend to 20200312.0 (#32741) 2020-03-12 14:41:04 -07:00
Raman Gupta 6e97975ff8
Set self._current_app to None when vizio device is off (#32725) 2020-03-12 15:04:34 +01:00
Franck Nijhof af7c01f957
Bumped version to 0.108.0dev0 (#32697) 2020-03-12 12:40:31 +01:00
Fabian Affolter 29533d8d4d
Upgrade sendgrid to 6.1.3 (#32721) 2020-03-12 12:06:01 +01:00
Robert Svensson 374a8157e7
Remove manual configuration support (#32699) 2020-03-12 11:56:50 +01:00
Fabian Affolter 40fc72aac2
Upgrade psutil to 5.7.0 (#32720) 2020-03-12 11:56:07 +01:00
Franck Nijhof b8fab33e69
Remove deprecated hide_if_away from device trackers (#32705) 2020-03-12 11:55:18 +01:00
Ville Skyttä 221d5205e4
Upgrade mypy to 0.770, tighten config a bit (#32715)
* Upgrade mypy to 0.770, related cleanups

https://mypy-lang.blogspot.com/2020/03/mypy-0770-released.html

* Clean up config and make it a notch stricter, address findings
2020-03-12 11:52:20 +01:00
Raman Gupta 77ebda0c20
Update Vizio `source` property to only return current app if i… (#32713)
* only return current app for source if current app is set

* check for None specifically

* make sure current app isn't called for speaker
2020-03-12 11:01:05 +01: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
escoand f9a0b4b3cf
Fix legacy Samsung TV (#32719)
* Update bridge.py

* Update test_init.py
2020-03-12 10:29:11 +01:00
Barry Williams 233568ac29
If device has volume disabled, the volume will be `None`. However in these (#32702)
instances whenever the volume was requested a division calculation was made
resulting in a TypeError. The volume adjustment from `0-100` to `0-1` is now
calculated during the `update()` method.
2020-03-12 09:54:25 +01:00
Aaron Bach 76b0302c7f
Broaden exception handling for IQVIA (#32708) 2020-03-11 19:34:54 -06:00
Erik Montnemery 8bc542776b
Cleanup entity and device registry on MQTT discovery removal (#32693)
* Cleanup entity and device registry on MQTT discovery removal.

* Review comments
2020-03-11 18:00:47 -07:00
Phil Bruckner 5f5cb8bea8
Add support for simultaneous runs of Script helper - Part 2 (#32442)
* Add limit parameter to service call methods

* Break out prep part of async_call_from_config for use elsewhere

* Minor cleanup

* Fix improper use of asyncio.wait

* Fix state update

Call change listener immediately if its a callback

* Fix exception handling and logging

* Merge Script helper if_running/run_mode parameters into script_mode

- Remove background/blocking _ScriptRun subclasses which are no longer needed.

* Add queued script mode

* Disable timeout when making fully blocking script call

* Don't call change listener when restarting script

This makes restart mode behavior consistent with parallel & queue modes.

* Changes per review

- Call all script services (except script.turn_off) with no time limit.
- Fix handling of lock in _QueuedScriptRun and add comments to make it
  clearer how this code works.

* Changes per review 2

- Move cancel shielding "up" from _ScriptRun.async_run to Script.async_run
  (and apply to new style scripts only.) This makes sure Script class also
  properly handles cancellation which it wasn't doing before.
- In _ScriptRun._async_call_service_step, instead of using script.turn_off
  service, just cancel service call and let it handle the cancellation
  accordingly.

* Fix bugs

- Add missing call to change listener in Script.async_run
  in cancelled path.
- Cancel service task if ServiceRegistry.async_call cancelled.

* Revert last changes to ServiceRegistry.async_call

* Minor Script helper fixes & test improvements

- Don't log asyncio.CancelledError exceptions.
- Make change_listener a public attribute.
- Test overhaul
  - Parametrize tests.
  - Use common test functions.
  - Mock timeout so tests don't need to wait for real time to elapse.
  - Add common function for waiting for script action step.
2020-03-11 16:34:50 -07:00
Fabian Affolter da761fdd39
Upgrade pylast to 3.2.1 (#32700) 2020-03-11 23:06:35 +01:00
Fabian Affolter 22415ce49a
Upgrade slacker to 0.14.0 (#32698) 2020-03-11 22:41:30 +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
Franck Nijhof 71155f548f
Bumped version to 0.107.0b0 2020-03-11 20:54:27 +01:00
Chris Talkington 180bcad477
Add codeowner for roku. (#32695) 2020-03-11 12:52:27 -07:00
Quentame 01dc81d8fb
Fetch iCloud family devices only when wanted (#32644)
* Fetch iCloud family devices only when wanted

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

* more work on config flow.

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

* cleanup tests.

* fix test.

* isort

* Update .coveragerc

* Update test_init.py

* Update test_init.py

* Update test_init.py

* Update test_config_flow.py

* Update test_config_flow.py

* Update test_config_flow.py

* correct upnp serial format.

* improve config flow coverage.

* review tweaks.

* further review tweaks

* simplify dtv data gathering job

* lint

* black

* Update test_init.py

* Update test_init.py

* Simplify exception handling.

* Simplify exception handling.

* Update media_player.py

* Update test_media_player.py

* Update test_media_player.py

* Update test_media_player.py

* Update test_media_player.py

* Update test_media_player.py

* fix failing test.

* restore change made during debug.

* isort.

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

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

* Fix logbook benchmarks

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

* Remove unnecessary mocks

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

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

* Improve disconnection handling.

* Update requirements-all

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

* Remove deleted from coverage omit list
2020-03-11 09:25:19 -07:00
Robert Svensson 015e779d56
UniFi - Client tracker schedules update on disconnect event (#32655) 2020-03-11 09:24:52 -07:00