Commit Graph

12089 Commits (72c35468b337cfbfd51afdaefc688aada0298d15)

Author SHA1 Message Date
Marc Khouri 72c35468b3 Remove asyncio.test_utils to fix tests in Docker/Python 3.7 (#12102)
The module `asyncio.test_utils` has been removed from Python in the 3.7 branch, because it was intended to be a private module for internal testing of asyncio. For more information, see the upstream bug report at https://bugs.python.org/issue32273 and the upstream PR at https://github.com/python/cpython/pull/4785.

For this commit, I have migrated the small amount of functionality that was being used from the `asyncio.test_utils` directly into the `RunThreadsafeTests` Class. To see the original `asyncio.test_utils.TestCase` class, which I pulled some functionality from, please see: https://github.com/python/cpython/blob/3.6/Lib/asyncio/test_utils.py#L440

Note: In addition to being broken in 3.7, this test case also seems to be broken in Python 3.6.4 when using Docker. This PR fixes the test when run in docker.

To reproduce: `./script/test_docker -- tests/util/test_async.py`
failing output (prior to this commit):

```
... trimmed ...
py36 runtests: PYTHONHASHSEED='3262989550'
py36 runtests: commands[0] | py.test --timeout=9 --duration=10 --cov --cov-report= tests/util/test_async.py
Test session starts (platform: linux, Python 3.6.4, pytest 3.3.1, pytest-sugar 0.9.0)
rootdir: /usr/src/app, inifile: setup.cfg
plugins: timeout-1.2.1, sugar-0.9.0, cov-2.5.1, aiohttp-0.3.0
timeout: 9.0s method: signal

―――――――――――――――――― ERROR collecting tests/util/test_async.py ――――――――――――――――――――――――
ImportError while importing test module '/usr/src/app/tests/util/test_async.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
tests/util/test_async.py:3: in <module>
from asyncio import test_utils
/usr/local/lib/python3.6/asyncio/test_utils.py:36: in <module>
from test import support
E ImportError: cannot import name 'support'
```
2018-02-02 14:59:05 +00:00
Eleftherios Chamakiotis 87c0fd98c7 Add support for "off" function to iTunes (#12109)
fixes #7614
2018-02-02 14:54:47 +00:00
Rene Nulsch 1d2e930900 OpenALPR Cloud API - transfer image in body of POST request (#12112)
* Send image in body of POST request

* Fix tests

* Implement requested change
2018-02-02 14:19:13 +01:00
Paul Annekov ad24cbddcc fixed wrong check for valid range of 'rgb' values (#12132) 2018-02-02 14:02:11 +01:00
nordlead2005 65f22b09ae Dark sky precip accumulation (#12127)
* Added DarkSky Precipitation Accumulation as an hourly forecast field

* fixed spacing
2018-02-02 10:23:27 +01:00
hawk259 569f7e2fea Adds SUPPORT_TARGET_TEMPERATURE_HIGH and SUPPORT_TARGET_TEMPERATURE_LOW support (#12110)
Fixes: [Issue 12048]
2018-02-02 10:11:13 +01:00
Daniel Høyer Iversen 12dc0db856
except vol.MultipleInvalid in Broadlink #11795 (#12107)
* except vol.MultipleInvalid in Broadlink #11795

* typo
2018-02-02 09:05:54 +01:00
Marius 6d5a87afb6 Fixes away_mode error on startup (#12121)
* Fixes away_mode error on startup

* Updated based on feedback
2018-02-02 09:05:19 +01:00
Timmo 30ad591a59 Downgrade Sonarr and Radarr 'Host is not avaliable' errors to warnings (#12119) 2018-02-01 20:57:33 +01:00
Alok Saboo be37bb14b7 Update jinja2 to 2.10 (#12118) 2018-02-01 19:21:15 +01:00
Craig J. Ward 53a99dc9fa Goalfeed channel (#12086)
* fix event channel name

* I guess accidentally added timeout here too.
2018-02-01 11:24:02 +01:00
jodur 2f07ffc4e4 added media_stop (#12100)
* added media_stop

VLC was missing the media_stop. The pause was present, but starting the same file result in resuming the file instead of start over new

* Corrected style issues

Style issues and added Support Flag to Support VLC

* fixed other style issues

* remove trailing whitespace
2018-02-01 09:49:39 +01:00
Philip Kleimeyer 8991690d53 update tahoma api to version 0.0.11 (#12099) 2018-02-01 08:15:13 +01:00
c727 764343dbf8 Fix detection of mobile browsers (#12075)
* Fix detection of mobile browsers

* Move break

* Add Mobile browsers to list

`Mobile Safari` is covered by iOS and `Opera Mini` does not support es6
... And Edge doesn't even work on desktop for me...
2018-01-31 10:44:33 -08:00
Philip Kleimeyer e11e066684 updated sensor name (#12084)
* updated sensor name

* Lint
2018-01-31 10:10:35 -08:00
Phil Elson 40af9f2676 Correct use of middleware async handling. (#12078) 2018-01-31 09:04:32 -08:00
Fabian Affolter 424fe95ce4 Upgrade keyring to 11.0.0 (#12082)
* Upgrade keyring to 11.0.0

* Address the removal of 'keyring.__version__'
2018-01-31 09:03:20 -08:00
John Mihalic 81a6178931 Squeezebox Fix duplicate server from discovery (#12063)
* Fix duplicate server from discovery

* Use hass.data instead of global

* Simplify
2018-01-31 15:32:08 +01:00
escoand e9508405bc Add conditions to forecast (#12074)
* add conditions to forecast chart

* Fix pylint issues
2018-01-31 13:05:15 +01:00
Gerben Meijer 6ae3fa40cf Set flux default stop time to dusk (#12062)
This is more in line with how one would expect light temperature
transitions to take place, but still allows for a user defined
stop_time.
2018-01-31 12:00:47 +01:00
Taylor Peet 434d2afbfc Influx import improvements (#11988)
* Influx import improvements

* fix line length issues

* fixing pylint spaces

* Added refined except clause

* Fix progress bar and exclude issues

* fix travis lint too many blank lines

* Minor changes
2018-01-31 11:39:15 +01:00
Ville Skyttä 0376cc0917 Handle more file closing using context manager (#11942) 2018-01-31 11:30:48 +01:00
escoand 4cb1f93019 fixed timestamp problem in firefox (#12073) 2018-01-31 11:26:35 +01:00
Craig J. Ward ebfb380449 fix event channel name (#12077) 2018-01-30 21:46:47 -05:00
Marius 3e41422caa Fix demo platform support (#12070)
* Fixing demo platform to use support_flags

* Fixed tests as well

* Moved humidity low / high as always available based on defaults

* Updated demo platform to show more combinations
2018-01-30 14:59:43 -08:00
Ville Skyttä cab6c694c5 Flake8 bugbear fixes (#12072)
* Don't use mutable argument defaults (bugbear B006)

* Use callable(x) instead of hasattr(x, '__call__') (bugbear B004)

* Remove/mark unused loop control variables (bugbear B007)

* Fix stripping protocol from kodi host name (bugbear B005)

* Fix plant daily history add default date (bugbear B008)
2018-01-30 14:44:05 -08:00
Kane610 37034a7450 Deconz use entity registry (#12067)
* Support for entity registry

* Not everything is a sensor...
2018-01-30 14:42:24 -08:00
Anders Melchiorsen 990fbdf3ca Unique ID for LIFX lights (#12064) 2018-01-30 14:40:44 -08:00
Pierre Ståhl dfd2d631ae Publish errors on the event bus (#11964)
* Publish errors on the event bus

* Add block till done to test.

* Update test_system_log.py

* Remove old logger handlers
2018-01-30 11:25:58 -05:00
Alex Osadchyy 12182d6e49 Bumped up pymochad requirement to 0.2.0 as a fix for #11928 (#12014)
* Bumped up pymochad requirement to 0.2.0 as a fix for #11928

* requirements_all.txt updated to match pymochad requirements
2018-01-30 05:13:30 -08:00
Anders Melchiorsen d7017f2138 Prepare for recorder purge to be active by default (#11976) 2018-01-30 12:41:33 +01:00
Paulus Schoutsen ec1c395f09 Extract requirements (#12051) 2018-01-30 12:30:47 +01:00
Joe Lu 71cb4df817 Return all attributes that are not None in base lock entity class (#12049)
* Return all attributes that are not None in base lock entity class

* Update __init__.py
2018-01-30 12:20:20 +01:00
Paulus Schoutsen e51427b284 Entity registry (#11979)
* Entity#unique_id defaults to None

* Initial commit entity registry

* Clean up unique_id property

* Lint

* Add tests to entity component

* Lint

* Restore some unique ids

* Spelling

* Remove use of IP address for unique ID

* Add tests

* Add tests

* Fix tests

* Add some docs

* Add one more test

* Fix new test…
2018-01-30 10:39:39 +01:00
Phil Kates 8e441ba03b Refactor Google Assistant query_device (#12022)
* google_assistant: Refactor query_device

The previous code had issues where domains could break out and end up
with weird brightness values and we weren't enforcing the `on` and
`oneline` keys in the response.

* google_assistant: Add media_player to query test
2018-01-30 01:19:24 -08:00
freol35241 5b1c51bdf6 Handling of payload not for this entity. (#11836)
* Handling of payload not for this entity.

The update state-method should not be called if the payload is not intended for this entity.

* Fixing linter errors

* Adding warning for case when no matching payload is found
2018-01-30 10:18:45 +01:00
Phil Frost 8624799c45 Refactor alexa smart_home tests (#12044)
* Refactor alexa smart_home tests

The previous tests had a lot of copy pasta due to a lack of expressions
for higher-level assertions. I'm hoping this makes it more reasonable to
extend all interfaces to support properties.

* Lint
2018-01-29 20:33:39 -08:00
Fabian Affolter 10263230f7 Upgrade astral to 1.5 (#12042) 2018-01-29 16:08:01 -08:00
Anders Melchiorsen 5609b42863 Upgrade pyharmony to 1.0.20 (#12043) 2018-01-29 15:54:49 -08:00
Paulus Schoutsen 24c6285567 Bump frontend to 20180130.0 2018-01-29 15:51:43 -08:00
smoldaner 6d59dad1ce Fix parameter escaping (#12008)
From rfc3986: The characters slash ("/") and question mark ("?") may represent data within the query component

See https://tools.ietf.org/html/rfc3986#section-3.4
2018-01-29 15:02:26 -08:00
Frantz 99c6a10b99 Set default values for Daikin devices that don't support fan direction and fan speed features (#12000) 2018-01-29 14:56:55 -08:00
kennedyshead 7ad870c4ff Online state for samsungtv is jumping when TV is idle (#11998)
* Set timeout to offline

* Have to rewrite to use ping instead.
2018-01-29 14:55:39 -08:00
Rene Nulsch 89e0b26b73 Error handling, in case no connections are available (#12010)
* Error handling, in case no connections are available

* Fix elif to if
2018-01-29 14:49:38 -08:00
Otto Winter 8dcfd35b8b Spelling fixes (#12041)
* Spelling fixes

*Lots* of them.

* Spelling breaking changes

* Fix lint errors
2018-01-29 23:37:19 +01:00
Otto Winter 38fd9b65bf Fix MQTT cover availability subscription (#12036) 2018-01-29 23:19:08 +01:00
c727 105522f03f Fix 404 for Hass.io panel using frontend dev (#12039)
* Fix 404 for Hass.io panel using frontend dev

* Hound
2018-01-29 23:18:33 +01:00
akloeckner 8b9dc71cde sensor.deutsche_bahn: add only_direct option (#11999)
* sensor.deutsche_bahn: add only_direct option

This adds the `only_direct` option to the HA interface as provided by the schiene class.

* fix line length

as requested by @houndci-bot and @fabaff

* No line breaks needed
2018-01-29 23:17:58 +01:00
Dan Cinnamon ff0fd71608 Bump upstream lib version. (#12021) 2018-01-29 12:35:13 +01:00
Andy Castille 12a53e2747 Fix DoorBird push notifications for installations with an API password (#12020) 2018-01-29 12:15:53 +01:00