Commit Graph

431 Commits (7752789c3abda110b864849c658a925c899bf7ee)

Author SHA1 Message Date
Joakim Plate c576a68d33
Upgrade pytest-aiohttp (#82475)
* Upgrade pytest-aiohttp

* Make sure executors, tasks and timers are closed

Some test will trigger warnings on garbage collect, these warnings
spills over into next test.

Some test trigger tasks that raise errors on shutdown, these spill
over into next test.

This is to mimic older pytest-aiohttp and it's behaviour on test
cleanup.

Discussions on similar changes for pytest-aiohttp are here:
https://github.com/pytest-dev/pytest-asyncio/pull/309

* Replace loop with event_loop

* Make sure time is frozen for tests

* Make sure the ConditionType is not async

  /home-assistant/homeassistant/helpers/template.py:2082: RuntimeWarning: coroutine 'AsyncMockMixin._execute_mock_call' was never awaited
    def wrapper(*args, **kwargs):
  Enable tracemalloc to get traceback where the object was allocated.
  See https://docs.pytest.org/en/stable/how-to/capture-warnings.html#resource-warnings for more info.

* Increase litejet press tests with a factor 10

The times are simulated anyway, and we can't stop the normal
event from occuring.

* Use async handlers for aiohttp

tests/components/motioneye/test_camera.py::test_get_still_image_from_camera
tests/components/motioneye/test_camera.py::test_get_still_image_from_camera
tests/components/motioneye/test_camera.py::test_get_stream_from_camera
tests/components/motioneye/test_camera.py::test_get_stream_from_camera
tests/components/motioneye/test_camera.py::test_camera_option_stream_url_template
tests/components/motioneye/test_camera.py::test_camera_option_stream_url_template
  /Users/joakim/src/hass/home-assistant/venv/lib/python3.9/site-packages/aiohttp/web_urldispatcher.py:189: DeprecationWarning: Bare functions are deprecated, use async ones
    warnings.warn(

* Switch to freezegun in modbus tests

The tests allowed clock to tick in between steps

* Make sure skybell object are fully mocked

Old tests would trigger attempts to post to could services:

```
DEBUG:aioskybell:HTTP post https://cloud.myskybell.com/api/v3/login/ Request with headers: {'content-type': 'application/json', 'accept': '*/*', 'x-skybell-app-id': 'd2b542c7-a7e4-4e1e-b77d-2b76911c7c46', 'x-skybell-client-id': '1f36a3c0-6dee-4997-a6db-4e1c67338e57'}
```

* Fix sorting that broke after rebase
2022-11-29 22:36:36 +01:00
Aarni Koskela 69d519418e
Remove unnecessary truthiness checks for integration.manifest (#82319) 2022-11-28 15:33:14 +01:00
uvjustin 9390359fe3
Bump httpx to 0.23.1 (#82725) 2022-11-26 10:04:22 -10:00
epenet 0538154767
Add type hints to requirements script (#82075) 2022-11-16 13:00:35 +01:00
Franck Nijhof e510dd64f1
Pin uamqp==1.6.0 (#80678) 2022-10-20 18:30:00 +02:00
Marc Mueller 33c94b0052
Add strict typing for WLED (#79822)
* Add strict typing for WLED

* Update backoff constraint
2022-10-07 21:56:29 +03:00
Paulus Schoutsen f41b69e19e
Bump cryptography to 38 (#79067) 2022-09-25 17:39:42 -04:00
Paulus Schoutsen 0cc03c37bb
Pin pyOpenSSL to 22.0.0 (#79066) 2022-09-25 15:19:06 -04:00
Paulus Schoutsen 57c766c03c
Pin Pandas 1.4.3 (#77679) 2022-09-01 15:00:50 -04:00
Franck Nijhof 3d567d2c1b
Update numpy to 1.23.2 (#76855) 2022-08-16 16:18:40 +02:00
Allen Porter 9e76e8cef8
Bump grpc requirements to 1.48.0 (#75603) 2022-07-31 13:37:29 +02:00
qiz-li 1f73a553c8
Bump Switchmate dependency to 0.5.1 (#75163)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-07-25 16:50:04 -10:00
puddly 5e46fa6f8b
Skip `iso4217` version 1.10, which includes a broken `__init__.pyi` file (#75200) 2022-07-14 12:38:22 -05:00
Paulus Schoutsen 1768315c50
Block bad pubnub version (#75138) 2022-07-13 14:12:53 -07:00
Franck Nijhof 792c825699
Update numpy to 1.23.1 (#74851) 2022-07-10 14:58:05 -07:00
Franck Nijhof 105b1b9d58
Update numpy to 1.23.0 (#74250) 2022-06-30 10:04:59 -07:00
Franck Nijhof 42533ebbb3
Update requests to 2.28.1 (#74210) 2022-06-29 20:40:58 -05:00
Joakim Sørensen 2f60db6f80
Pin charset-normalizer to 2.0.12 (#74104) 2022-06-28 18:20:56 +02:00
RenierM26 10ea88e0ea
Switchbot bump Dependency 0.14.0 (#74001)
* Bump requirement.

* Switchbot depenacy update, full async.

* Update tests, remove redundant config entry check.

* Update requirements_test_all.txt

* Update requirements_all.txt

* Remove asyncio lock. Not required anymore with bleak.

* Update requirements_all.txt

* Update requirements_test_all.txt

* pyswitchbot no longer uses bluepy
2022-06-27 13:56:51 +02:00
Pascal Vizeli 6cf9b22b5a
Python 3.10 / Base image 2022.06.01 (#73830)
* Python 3.10 / Base image 2022.06.01

* Update requirements

* push opencv

* we don't need numpy on core for now

* Remove unused ignore

Co-authored-by: Franck Nijhof <git@frenck.dev>
2022-06-22 12:04:39 -05:00
Christopher Bailey 133cb7ccef
Add package constraint for pydantic (#72799)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-05-31 20:04:35 -10:00
uvjustin 01b5f98414
Bump httpx to 0.23.0 (#72573)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-05-26 21:20:37 -10:00
Marc Mueller 1ac71455cb
Move remaining metadata to pyproject (#72469) 2022-05-26 02:54:49 +02:00
Allen Porter cd2898886b
Upgrade grpcio to 1.46.1 (#71865) 2022-05-14 12:24:52 -07:00
Franck Nijhof c8d171c475
Remove deprecated Raspberry Pi GPIO integration (#71777) 2022-05-13 12:13:26 +02:00
Franck Nijhof d95113c8f2
Pin grpcio-status to 1.45.0 (#71293) 2022-05-04 16:56:29 +02:00
Marc Mueller 0959ee4353
Pin backoff <2.0 (#70817) 2022-04-26 22:12:48 +02:00
epenet 2c0153a32e
Revert "Pin click to fix typer issue" (#68927) 2022-03-31 14:53:18 +02:00
epenet 35a5cca1ca
Cleanup package constraints (#68833)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-03-29 11:44:19 +02:00
epenet f067aa6d71
Pin click to fix typer issue (#68808)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-03-29 00:07:29 +02:00
Franck Nijhof f562f4264f
Update grpcio to 1.45.0 (#68632) 2022-03-24 20:45:18 +01:00
Franck Nijhof 2686be921c
Remove deprecated (old) Z-Wave integration (#67221)
* Remove deprecated (old) Z-Wave integration

* Mark migration tests as skip, for later cleanup
2022-03-18 13:09:10 +01:00
Marc Mueller aabf46b1b3
Fix point by adding authlib constraint (#68176)
* Fix point by pinning authlib

* Use constraint
2022-03-15 15:56:08 +01:00
uvjustin a81fa31314
Bump httpx and httpcore (#67438) 2022-03-01 09:17:25 -10:00
Franck Nijhof 487f4dcd90
Remove deprecated Raspihats integration (#67380) 2022-02-28 23:10:58 +01:00
Franck Nijhof 0db6a0b248
Remove deprecated Bosch BME680 Environmental Sensor integration (#67273) 2022-02-28 13:29:13 +01:00
Franck Nijhof e4903f9a13
Remove deprecated HTU21D(F) Sensor integration (#67279) 2022-02-27 15:35:39 +01:00
Franck Nijhof 9920b3eef5
Remove deprecated Enviro pHAT integration (#67277) 2022-02-26 13:35:13 -08:00
Franck Nijhof fbfdabe4fc
Remove deprecated Raspberry Pi RF integration (#67283) 2022-02-26 13:26:41 -08:00
Franck Nijhof ae073d132c
Remove deprecated Bosch BME280 Environmental Sensor integration (#67185) 2022-02-24 23:54:01 +02:00
Franck Nijhof dd927adba9
Remove deprecated Blinkt! integration (#67165) 2022-02-24 19:26:32 +02:00
Franck Nijhof 636e4ed90b
Remove deprecated Time of Flight integration (#67167) 2022-02-24 14:47:20 +01:00
Timothy Kist 6a5215dc0e
Allow multidict 6.0.2+ to fix ZHA, gTTS and other integrations (#67046) 2022-02-23 12:25:54 +01:00
Marc Mueller 8eb7507482
Cleanup after setup.py removal (#67036) 2022-02-22 14:32:55 +01:00
Allen Porter 703d01e772
Bump grpcio to 1.44.0 (#66787) 2022-02-17 23:12:05 -08:00
Franck Nijhof 276fd4f42c
Add Python 3.10 to CI (#59729) 2022-02-17 14:58:24 +01:00
Marc Mueller 86ed720335
Move `install_requires` to `setup.cfg` (#65095) 2022-01-27 22:34:18 -08:00
uvjustin 3b3a8db291
Bump httpx to 0.21.3 and pin requirements for httpcore, anyio, and h11 (#64822) 2022-01-24 10:43:39 +01:00
Michael 2f0059fa8b
Revert fix MultiDict typing with multidict-6.0.0 (#64733) (#64792)
* revert #64733

* pin down multidict to < 6.0.0
2022-01-23 23:22:16 +01:00
uvjustin 5654490aa8
Update version requirements for httpcore and anyio (#64711) 2022-01-22 13:52:41 -10:00
Allen Porter fec669f9c8
Revert "Add version constraint for google-auth (#64583)" (#64605)
This reverts commit 3792b8b3ca.
2022-01-21 08:12:04 +01:00
Marc Mueller 3792b8b3ca
Add version constraint for google-auth (#64583) 2022-01-21 00:11:22 +01:00
Marc Mueller c6acd8efa4
Pin python-engineio and python-socketio (#64074)
Prevent potential dependency conflicts between sisyphus-control and aioambient
2022-01-14 10:25:28 +02:00
Franck Nijhof d1eecba36a
Pin libcst==0.3.23 (#64036) 2022-01-13 18:25:28 +01:00
Marc Mueller 0922627612
Remove unused pillow 8.2.0 constraint (#64011) 2022-01-13 00:28:32 +01:00
Allen Porter aab5a097a0
Bump google-cloud-pubsub to 2.9.0 (attempt #3) (#63911) 2022-01-11 17:25:50 +01:00
Shay Levy 1f92c25b8c
Remove package constraint to websockets (#63703) 2022-01-09 05:04:19 +01:00
Matt Zimmerman ae3ff0a8ce
Skip empty test directories in gen_requirements_all (#62970) 2022-01-07 16:45:27 +01:00
Allen Porter 1ed2497ec9
Revert "Bump google-cloud-pubsub to 2.9.0 (attempt #2) (#63522)" (#63561)
This reverts commit 1baa3d87d1.
2022-01-06 09:46:11 -08:00
Allen Porter 1baa3d87d1
Bump google-cloud-pubsub to 2.9.0 (attempt #2) (#63522) 2022-01-06 15:47:06 +01:00
Franck Nijhof ce31af5b42
Revert "Bump google-cloud-pubsub to 2.9.0 (to bump grpcio)" (#63517) 2022-01-05 22:50:11 +01:00
Allen Porter f786237def
Bump google-cloud-pubsub to 2.9.0 (#63493)
The primary motivation is to kick off building wheels for grpcio
2022-01-05 12:03:45 -08:00
epenet 25cf690b20
Tidy up package constraint messages (#61866)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2021-12-15 12:28:04 +01:00
Martin Hjelmare a818afdad1
Revert pillow 8.3.2 (#61793)
* Revert "Bump pillow from 8.2.0 to 8.3.2 (#61661)"

This reverts commit 3635946211.

* Add comment

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>

* Fix comment

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2021-12-15 03:10:06 +01:00
Paulus Schoutsen 009a28ba7a
Block pytest_asyncio (#61141) 2021-12-06 22:07:56 -08:00
Franck Nijhof 32784d1b83
Constrain urllib3 to >=1.26.5 (#59043) 2021-11-04 11:21:30 +01:00
J. Nick Koston 2b175a37a7
Add package constraint to websockets (#58626) 2021-10-28 21:32:22 +02:00
uvjustin dd9bfe7aa0
Add package constraint anyio>=3.3.1 (#55997) 2021-09-09 15:33:09 +02:00
Ian de5a22953d
Whole-string match reqs in comment_requirement (#55192)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2021-08-30 08:20:02 -07:00
Joakim Sørensen 2fcd77098d
Pin regex to 2021.8.28 (#55368) 2021-08-28 15:00:14 +02:00
Allen Porter 58f170ba45
Pin google-api-core to avoid new version of grpcio (#55115) 2021-08-24 09:43:29 +02:00
Allen Porter 22acaa8e63
Pin google-cloud-pubsub to an older version (#54239)
Pin google-cloud-pubsub to an older version, since newer versions have a
pin that is incompatible with the existing grpcio pin already in package_constraints.txt
2021-08-07 21:00:37 -07:00
Pascal Vizeli f3e7fb5798
Pin pandas to 1.3.0 (#53607)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-07-28 10:30:05 +02:00
Kuzj d0b9d82287
Refactor bme280, add SPI support (#48775)
* bme280 refactoring, add SPI support

* isort, requirements

* __init_.py add to .coveragerc

* Re-run CI jobs

* const.py to .coveragerc

* Add support for IoT class in manifest

* Keepalive

* review suggestions

* scan_interval with coordinator

* black, isort

* coordinator review suggestions

* Set device_class

* review suggestions

* review suggestions

* review suggestions

* review suggestions

* review suggestions

* review suggestions

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

* add bme280spi to commented requirements

* run script.gen_requirements_all

* black

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-07-27 16:29:43 -04:00
J. Nick Koston 0ce071e0a4
Bump httpx to 0.18.2 (#53257) 2021-07-20 21:47:13 -07:00
Joakim Sørensen 33ac4dba5a
Add httpcore with version 0.13.3 (#51799) 2021-06-13 10:21:26 +02:00
Pascal Vizeli 3d119fd4ab
Revert "GRPC is fixed, don't need a workaround" (#51289)
This reverts commit 9d174e8a05.
2021-05-31 14:03:26 +02:00
Pascal Vizeli 9d174e8a05
GRPC is fixed, don't need a workaround (#50605)
* GRPC is fixed, don't need a workaround

* Update gen_requirements_all.py
2021-05-14 14:30:48 +02:00
karliemeads e9f8b3e7ef
Remove unused py_noaa dependency (#50494) 2021-05-12 00:44:17 +02:00
Franck Nijhof 14af6d3884
Remove DHT from Raspberry Pi machine builds (#49829) 2021-04-28 22:43:40 +02:00
J. Nick Koston dcb5b9f8b5
Bump httpx to 0.18.0 and respx to 0.17.0 (#49805) 2021-04-28 11:22:09 +02:00
Marc Mueller 6fc3406c93
Ignore python-typing-update for pre-commit requirements (#48292) 2021-03-24 20:05:53 +01:00
Paulus Schoutsen 633a7aeb22
Remove deprecated credstash + keyring (#47033) 2021-02-25 09:48:19 +01:00
Franck Nijhof 0181cbb312
Upgrade and constrain httplib2>=0.19.0 (#46725) 2021-02-18 12:31:07 +01:00
Tobias Bielohlawek 6e67b943da
Remove Nuimo integration (#45600) 2021-02-01 16:58:00 +01:00
J. Nick Koston c6105900f6
Update httpcore to prevent unhandled exception on dropped connection (#45667)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2021-01-29 09:11:24 +01:00
Robert Svensson c4fbfc25e3
Bump H11 library to support non RFC line endings (#44735) 2021-01-01 18:39:59 +01:00
michaeldavie a3e8968e8a
Remove OpenCV dependecy from Environment Canada (#43235)
* Bump env_canada to 0.2.2

* Revert PR #38731
2020-11-14 21:16:14 +01:00
Franck Nijhof e320c3b735
Pin gRPC to 1.31.0 to workaround amrv7 issues (#40678) 2020-09-27 21:51:37 +02:00
Martin Hjelmare 50c573eb4d
Activate hassfest requirements CI check (#39940)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2020-09-11 21:38:32 +02:00
Ville Skyttä 6ae9399237
Upgrade isort to 5.4.2 (#37939) 2020-08-29 08:23:55 +02:00
Ville Skyttä 98993d8503
Trivial requirements cleanups (#39222) 2020-08-27 16:56:53 +02:00
Paulus Schoutsen b47992dba0
Bump CI cache (#39283) 2020-08-26 16:53:22 +02:00
Paulus Schoutsen e96d8a961c
Block typing from being installed (#37707) 2020-08-26 14:51:41 +02:00
Paulus Schoutsen df9de8eb5d
Prevent bluepy from being part of requirements_all.txt (#39275) 2020-08-26 14:50:14 +02:00
Paulus Schoutsen 2a9da208d4
Allow disabling integrations in manifest, block uuid package being installed and disable ezviz (#38444) 2020-08-26 10:20:14 +02:00
Franck Nijhof ea65eb270f
Ignore requirements for env_canada (#38731) 2020-08-10 18:00:02 +02:00
Jason Hunter 3546a82cfb
Upgrade to TensorFlow 2 (#38384)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2020-08-07 08:56:28 +02:00
Paulus Schoutsen 0ffeb4dea4
Add MQTT to constraints file (#38049) 2020-07-21 19:19:32 -07:00
Paulus Schoutsen 0bcc8624b7
Reference constraint files from requirement files (#37751)
* Reference constraint files from requirement files

* Update azure-pipelines-wheels.yml

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-07-11 06:20:14 -07:00
Franck Nijhof 1aafa459e5
Fix building of Python Wheels (#37433) 2020-07-03 21:33:35 +02:00
Franck Nijhof 573134fcb4
Add GitHub Actions for CI (#37419)
* Add GitHub Actions for CI

* Add base/full to step descriptions
2020-07-03 19:18:01 +02:00
Paulus Schoutsen 691ec21ba4
Mark min version of httplib2 (#36330) 2020-06-01 09:44:18 +02:00
Franck Nijhof d33cf28936
Add check executables have shebangs (in pre-commit and CI) (#33703)
* Add check executables have shebangs (in pre-commit and CI)

* Fix file permissions

* Adjust Azure Pipelines
2020-04-05 18:45:43 +02:00
springstan fca90a8ddc
Improve string formatting v5 (#33697)
* Improve string formatting v5

* Address review comments
2020-04-05 17:48:55 +02:00
Franck Nijhof 39336d3ea3
Add prettier (in pre-commit and CI) (#33693)
* Add prettier (in pre-commit and CI)

* Make all file prettier

* Change order

* Add to Azure Pipelines

* Fix a YAML file prettier caught as invalid

* Remove flow mapping using curly braces from all YAML service files
2020-04-05 17:27:16 +02:00
springstan e3bcfb88e7
Improve string formatting v4 (#33668)
* Improve string formatting v4

* Use normal strings instead of f-strings

* Fix zeroconf test by adding back part of a condition
2020-04-05 16:01:41 +02:00
Franck Nijhof 24840b54ac
Add yamllint (in pre-commit and CI) (#33676)
* Add yamllint (in pre-commit and CI)

* Fix linting for all YAML files

* Bump and add it to requirements

* Fix gen_requirements for pre-commit, remove 'v' from version
2020-04-05 10:33:45 +02:00
Paulus Schoutsen f1d3c0d19b
Remove unused manifest fields (#33595) 2020-04-03 12:58:19 -07:00
Paulus Schoutsen 1d3647e6a1
Make gen_requirements_all.py case insensitive for ignored pack… (#30885) 2020-03-04 17:39:59 -08:00
Franck Nijhof bf1092ec80
Add minimal version contrain to urllib3 (#32031) 2020-02-20 19:19:09 +01:00
Franck Nijhof b2f2afaf0c
Prevent committing to dev/master/rc directly (#32029)
* Prevent committing to dev/master/rc directly

* Skip pre-commit on version bump
2020-02-20 09:34:30 -08:00
Ville Skyttä dc5ca461a9
Run mypy through a pyenv/virtualenv enabler wrapper script (#30922) 2020-02-01 07:12:46 -08:00
Oscar Calvo d813618d0d Add Gammu based local SMS notifications (#31233)
* Add sms integration

Committer: ocalvo <oscar@calvonet.com>

* Fix PyLint

* Update requirements
2020-01-28 09:35:41 +01:00
Bas Delfos 0d688faa56 Fix 'NewIPAddress' error in component fritz (#30210)
* Fix 'NewIPAddress' error in component fritzbox

* Upgrade to fritzconnection 1.2.0
2020-01-14 09:46:16 +01:00
Ville Skyttä 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
Franck Nijhof 87ca61ddd7 Add check-json to CI and Pre-commit (#29912)
* Add check-json to CI and Pre-commit

* Add ignore pre-commit hooks to gen_requirements_all
2019-12-16 11:06:16 +01:00
Ville Skyttä 445fd15f76 Drop Python 3.6 support (#29978) 2019-12-16 07:29:19 +01:00
Bas Nijholt 5cb6d1b21f Sort imports according to PEP8 for 'script' folder (#29790) 2019-12-09 16:24:03 +01:00
Ville Skyttä 804b6bbc0e Reduce test requirements duplication, sync flake8 and related (#28538)
* Generate pre-commit test dependencies instead of duplicating

* Upgrade/sync to flake8 3.7.9, flake8-docstrings 1.5.0, and pydocstyle 4.0.1

https://flake8.readthedocs.io/en/latest/release-notes/3.7.9.html
https://gitlab.com/pycqa/flake8-docstrings/blob/1.4.0/HISTORY.rst
https://gitlab.com/pycqa/flake8-docstrings/blob/1.5.0/HISTORY.rst
http://www.pydocstyle.org/en/4.0.1/release_notes.html

* Include requirements_test.txt from *_all.txt instead of copying
2019-11-04 21:21:52 -08:00
Paulus Schoutsen 54c24de158
Install requirements for all deps with tests (#27362)
* Install requirements for all deps with tests

* Remove unused REQUIREMENTS var

* Print diff if not the same

* Simplify

* Update command line

* Fix detecting empty dirs

* Install non-integration

* Fix upnp tests

* Lint

* Fix ZHA test
2019-10-09 16:16:29 -07:00
Robert Van Gorkom 071476343c Fix connection issues with withings API by switching to a maintained codebase (#27310)
* Fixing connection issues with withings API by switching to a maintained client codebase.

* Updating requirements files.

* Adding withings api to requirements script.
2019-10-08 20:14:52 +02:00
ktnrg45 1ecc883ef4 PS4 bump to renamed dependency (#27144)
* Change to renamed dependency pyps4-2ndscreen 0.9.0

* Rename / bump to ps4 dependency to 1.0.0

* update requirements

* Rename test req

* Fix import

* Bump 1.0.1

* Fix flaky test leaving files behind
2019-10-06 14:43:34 +02:00
Santobert bd6bbcd5af Neato config flow (#26579)
* initial commit

* Minor changes

* add async setup entry

* Add translations and some other stuff

* add and remove entry

* use async_setup_entry

* Update config_flows.py

* dshokouhi's changes

* Improve workflow

* Add valid_vendors

* Add entity registry

* Add device registry

* Update entry from configuration.yaml

* Revert unneccesary changes

* Update .coveragerc

* Prepared tests

* Add dshokouhi and Santobert as codeowners

* Fix unload entry and abort when already_configured

* First tests

* Add test for abort cases

* Add test for invalid credentials on import

* Add one last test

* Add test_init.py with some tests

* Address reviews, part 1

* Update outdated entry

* await instead of add_job

* run IO inside an executor

* remove faulty test

* Fix pylint issues

* Move IO out of constructur

* Edit error translations

* Edit imports

* Minor changes

* Remove test for invalid vendor

* Async setup platform

* Edit login function

* Moved IO out if init

* Update switches after added to hass

* Revert update outdated entry

* try and update new entrys from config.yaml

* Add test invalid vendor

* Default to neato
2019-10-06 13:05:51 +02:00
mvn23 6ae908b883 Add opentherm_gw config flow (#27148)
* Add config flow support to opentherm_gw.
Bump pyotgw to 0.5b0 (required for connection testing)
Existing entries in configuration.yaml will be converted to config entries and ignored in future runs.

* Fix not connecting to Gateway on startup.
Pylint fixes.

* Add tests for config flow.
Remove non-essential options from config flow.
Restructure config entry data.

* Make sure gw_id is slugified
2019-10-04 17:38:26 -07:00
Maciej Bieniek 8ba4ee1012 Add Airly integration (#26375)
* Add Airly integration

* Update .coveragerc file

* Remove AVAILABLE_CONDITIONS and fix device_class

* Don't create client on every update

* Rename client to session

* Rename state_attributes to device_state_attributes

* Remove log latitude and longitude

* Fix try...except

* Change latitude and longitude to HA defaults

* _show_config_form doesn't need coroutine

* Simplify config_flow errors handlig

* Preetier

* Remove unnecessary condition

* Change sensor platform to air_quality

* Remove PM1

* Make unique_id more unique

* Remove ,

* Add tests for config_flow

* Move conf to CONFIG

* Remove domain from unique_id

* Change the way update of attrs

* Language and attrs

* Fix attrs

* Add aiohttp error handling

* Throttle as decorator

* Suggested change

* Suggested change

* Invert condition

* Cleaning

* Add tests

* Polish no sesnor error handling

* Better strings

* Fix test_invalid_api_key

* Fix documentation url

* Remove unnecessary test

* Remove language option

* Fix test_invalid_api_key once again

* Sort imports

* Remove splits in strings
2019-10-04 13:58:29 +02:00
jjlawren 571ab5a978 Plex external config flow (#26936)
* Plex external auth config flow

* Update requirements_all

* Test dependency

* Bad await, delay variable

* Use hass aiohttp session, bump plexauth

* Bump requirements

* Bump library version again

* Use callback view instead of polling

* Update tests for callback view

* Reduce timeout with callback

* Review feedback

* F-string

* Wrap sync call

* Unused

* Revert unnecessary async wrap
2019-10-01 17:20:30 +02:00
Tiit Rätsep 48d07467d9 Add support for SOMA Smartshades devices (#26226)
* Add Soma integration

* Fixed cover position get/set

* Try to list devices before creating config entries to see if Soma Connect can be polled

* Style fixes

* Updated requirements

* Updated .coveragerc to ignore Soma component

* Fixed linter errors

* Implemented stop command

* Test coverage fixes according to feedback

* Fixes to code according to feedback

* Added error logging and tested config from yaml

* Indentation fix

* Removed unnecessary method

* Wrong indentation

* Added some tests

* Added test for import step leading to entry creation

* Added feedback to user form in case of connection error

* Minor fixes according to feedback

* Changed exception type in error handling for connection to Connect

* To keep API consistent for Google Home and Alexa we swapped the open/closed position values back and I reversed them in this integration as well

* regenerated requirements, ran black, addde __init__.py to ignore file

* Added pysoma library to gen_requirements_all.py

* Added missing test case

* removed useless return value
2019-09-30 14:23:08 +02:00
Rami Mosleh 82b77c2d29 Add config flow to transmission (#26434)
* Add config flow to transmission

* Reworked code to add all sensors and switches

* applied fixes

* final touches

* Add tests

* fixed tests

* fix get_api errors and entities availabilty update

* update config_flows.py

* fix pylint error

* update .coveragerc

* add codeowner

* add test_options

* fixed test_options
2019-09-26 11:14:57 +02:00
Mark Coombes f6995b8d17 Add config flow to ecobee (#26634)
* Add basic config flow

* Fix json files

* Update __init__.py

* Fix json errors

* Move constants to const.py

* Add ecobee to generated config flows

* Update config_flow for updated API

* Update manifest to include new dependencies

Bump pyecobee, add aiofiles.

* Update constants for ecobee

* Modify ecobee setup to use config flow

* Bump dependency

* Update binary_sensor to use config_entry

* Update sensor to use config_entry

* Update __init__.py

* Update weather to use config_entry

* Update notify.py

* Update ecobee constants

* Update climate to use config_entry

* Avoid a breaking change on ecobee services

* Store api key from old config entry

* Allow unloading of config entry

* Show user a form before import

* Refine import flow

* Update strings.json to remove import step

Not needed.

* Move third party imports to top of module

* Remove periods from end of log messages

* Make configuration.yaml config optional

* Remove unused strings

* Reorganize config flow

* Remove unneeded requirement

* No need to store API key

* Update async_unload_entry

* Clean up if/else statements

* Update requirements_all.txt

* Fix config schema

* Update __init__.py

* Remove check for DATA_ECOBEE_CONFIG

* Remove redundant check

* Add check for DATA_ECOBEE_CONFIG

* Change setup_platform to async

* Fix state unknown and imports

* Change init step to user

* Have import step raise specific exceptions

* Rearrange try/except block in import flow

* Convert update() and refresh() to coroutines

...and update platforms to use async_update coroutine.

* Finish converting init to async

* Preliminary tests

* Test full implementation

* Update test_config_flow.py

* Update test_config_flow.py

* Add self to codeowners

* Update test_config_flow.py

* Use MockConfigEntry

* Update test_config_flow.py

* Update CODEOWNERS

* pylint fixes

* Register services under ecobee domain

Breaking change!

* Pylint fixes

* Pylint fixes

* Pylint fixes

* Move service strings to ecobee domain

* Fix log message capitalization

* Fix import formatting

* Update .coveragerc

* Add __init__ to coveragerc

* Add option flow test

* Update .coveragerc

* Act on updated options

* Revert "Act on updated options"

This reverts commit 56b0a859f2e3e80b6f4c77a8f784a2b29ee2cce9.

* Remove hold_temp from climate

* Remove hold_temp and options from init

* Remove options handler from config flow

* Remove options strings

* Remove options flow test

* Remove hold_temp constants

* Fix climate tests

* Pass api key to user step in import flow

* Update test_config_flow.py

Ensure that the import step calls the user step with the user's api key as user input if importing from ecobee.conf/validating imported keys fails.
2019-09-25 22:38:21 +02:00
Robin 1d60cccc21 Put draw_box in image_processing (#26712)
* Put draw_box in image_processing

* Update draw_box

* Update __init__.py

* run isort

* Fix lints

* Update __init__.py

* Update requirements_all.txt

* Adds type hints

* Update gen_requirements_all.py

* Update requirements_test_all.txt

* rerun script/gen_requirements_all.py

* Change Pillow to pillow

* Update manifest.json

* Run script/gen_requirements_all.py
2019-09-24 12:09:16 +02:00
Kevin Eifinger 5c0fa35d4a Add here_travel_time (#24603)
* Add here_travel_time

* Bump herepy version to 0.6.2

* Update requirements_all.txt

* Disable pylint and catch errors

* Add herepy to requirements_test_all

* Correctly place test req for herepy

* use homeassistant.const.LENGTH_METERS

* Implemented Requested Changes

* Better error message for cryptic error code

* add requested changes

* add_entities instead of async

* Add route attr and distance in km instead of m

* fix linting errors

* attribute duration in minutes instead of seconds

* Correct pattern for longitude

* dont split attribute but rather local var

* move strings to const and use travelTime

* Add tests

* Add route for pedestrian and public

* fix public transport route generation

* remove print statement

* Standalone pytest

* Use hass fixture and increase test cov
_resolve_zone is redundant

* Clean up redundant code

* Add type annotations

* Readd _resolve_zone and add a test for it

* Full test cov

* use caplog

* Add origin/destination attributes
According to https://github.com/home-assistant/home-assistant/pull/24956

* Add mode: bicycle

* black

* Add mode: publicTransportTimeTable

* Fix error for publicTransportTimeTable
Switch route_mode and travel_mode in api request.

* split up config options

* More type hints

* implement *_entity_id

* align attributes with google_travel_time

* route in lib
apply requested changes

* Update requirements_all.txt

* remove DATA_KEY

* Use ATTR_MODE

* add attribution

* Only add attribution if not none

* Add debug log for raw response

* Add _build_hass_attribution

* clearer var names in credentials check

* async _are_valid_client_credentials
2019-09-23 11:50:18 +02:00
Penny Wood b68b8430a4 Izone component (#24550)
* iZone component

* Rename constants to const.

* Changes as per code review.

* Stop listening if discovery times out.

* Unload properly

* Changes as per code review

* Climate 1.0

* Use dispatcher instead of listener

* Free air settings

* Test case for config flow.

* Changes as per code review

* Fix error on shutdown

* Changes as per code review

* Lint fix

* Black formatting

* Black on test

* Fix test

* Lint fix

* Formatting

* Updated requirements

* Remaining patches

* Per code r/v
2019-09-19 23:31:54 +02:00
jjlawren 2d12bac0e2 Add Plex config flow support (#26548)
* Add config flow support

* Log error on failed connection

* Review comments

* Unused errors

* Move form to step

* Use instance var instead of passing argument

* Only share servers created by component

* Return errors early to avoid try:else

* Separate debug for validation vs setup

* Unnecessary

* Unnecessary checks

* Combine import flows, move logic to component

* Use config entry discovery handler

* Temporary lint fix

* Filter out servers already configured

* Remove manual config flow

* Skip discovery if a config exists

* Swap conditional to reduce indenting

* Only discover when no configs created or creating

* Un-nest function

* Proper async use

* Move legacy file import to discovery

* Fix, bad else

* Separate validate step

* Unused without manual setup step

* Async oops

* First attempt at tests

* Test cleanup

* Full test coverage for config_flow, enable tests

* Lint

* Fix lint vs black

* Add test init

* Add test package requirement

* Actually run script

* Use 'not None' convention

* Group exceptions by result

* Improve logic, add new error and test

* Test cleanup

* Add more asserts
2019-09-19 23:29:26 +02:00
Paulus Schoutsen 7468cc21be
Refactor Cast (#26550)
* Refactor Cast

* Fix tests & address comments

* Update reqs
2019-09-10 13:05:46 -07:00
Maikel Punie 28beebac61 Enable SolarEdge config entries (#26282)
* Initial commit for the solaredge configflow

* rerun the hassfest script

* Adding testcases

* Rerun hassfest, problem with black?

* Requirements for the tests

* Remove CONF_MONITORED_CONDITIONS from configuration.yaml

* Remove the options flow strings

* Resolve some comments

* Comments

* More comments

* Move the config from the sensor platform to the component itself

* More comments

* More comments

* Added solaredge __init__

* Added more test to increase coverage
2019-09-08 21:49:20 +02:00
Florent Thoumie 0abb2f3eb8 Add new integration for Jandy iAqualink pool control (#26034)
* Import new iaqualink component with climate platform.

* Style and unittest changes, fix async_step_import.

* Reorder imports.

* Fix stale doctstrings and add unittest.
2019-09-06 22:21:56 +02:00
Quentame b4058b5c7f Add config flow to linky (#26076)
* Linky: setup ConfigFlow

* async_track_time_interval

* Review from @MartinHjelmare 1

* Review from @MartinHjelmare 2

* Review from @MartinHjelmare 3

* Review from @MartinHjelmare 4

* black --fast homeassistant tests

* Bump pylinky to 0.4.0 and add error user feedback

* Fix .coveragerc

* Linky platform moved to integration in config.yml and with multiple accounts

* Remove useless logs

* Review from @MartinHjelmare 5

* Add config flow tests

* Add config flow tests : login + fetch on failed
2019-09-04 07:04:26 +02:00
John Luetke 757482ee85 Refactor pihole integration (#25837)
* Adds tests for pi_hole integration

* Refactor pi_hole component to an integration supporting multiple platforms

* Adds mock of Hole dependency

* Aborts platform setup when discovery_info is none

* Removes use of monitored_conditions

* Adds integration setup test

* Removes PlatformNotReady check

* Adds sensor test

* Code review updates

* Refactor tests to assert state through hass

* Reorder imports
2019-09-03 16:18:06 -07:00
Robert Van Gorkom 614cf74225 Add Withings support (#25154)
* Rebasing with a clean branch.
Addressing PR feedback.
Cleaning up some static code checks.
Fixing bug with saving credentials.

* Removing unecessary change.

* Caching data manager.

* Removing configurable measures.

* Using import step in config flow.

* Updating config flows.

* Addressing PR feedback.

* Formatting source.

* Addressing PR feedback and rebasing.
2019-08-31 14:30:59 +02:00
Jeff Irion 789ad38c38 Bump androidtv to 0.0.25 and add tests (#26202)
* Add tests for androidtv

* Test that the error and reconnection attempts are logged correctly.

> "Handles device/service unavailable. Log a warning once when
> unavailable, log once when reconnected."

https://developers.home-assistant.io/docs/en/integration_quality_scale_index.html

* Clarify comment

* Add test for when the ADB shell command returns None

* Bump androidtv to 0.0.25
2019-08-29 12:03:03 +02:00
Franck Nijhof decf13b948 Use literal string interpolation in core (f-strings) (#26166) 2019-08-23 09:53:33 -07:00
MatthewFlamm 17750a604e Add NWS weather (#23647)
* Add nws weather.

* Hassfest

* Address multiple comments

* Add NWS icon weather code link

* Add metar fallback.

Use metar code from nws observation if normal api is missing data.

* only get 1 observation - we dont use more than 1

* add mocked metar for tests

* lint

* mock metar package for all tests

* add check for metar attributes

* catch errors in setup

* add timeout error

* handle request exceptions

* check and test for missing observations

* refactor to new pynws

* change to simpler api

* Make py3.5 compatible

Remove f string

* bump pynws version

* gen_requirements

* fix wind bearing observation

* Revert "Make py3.5 compatible"

This reverts commit 4946d91779.

* Precommit black missed a file?

* black test

* add exceptional weather condition

* bump pynws version

* update requirements_all

* address comments

* move observation and forecast outside try-except-else

* Revert "move observation and forecast outside try-except-else"

This reverts commit 53b78b3283.

* remove else from update forecast block

* remove unneeded ConfigEntryNotReady import

* add scan_interval, reduce min_time_between_updates

* pytest tests

* lint test docstring

* use async await

* lat and lon inclusive in config
2019-08-23 14:13:06 +02:00
Tomas Kislan eee2b2d543 Add Minio component (#23567)
* Add minio implementation

* Static check changes

* Added docstrings

* Update docstrings

* Update docstrings

* Fix linter errors

* Finally fix all docstring errors

* Create services.yaml

* Update CODEOWNERS

* Final changes

* Remove double underscores

* Minor changes

* Update config.yml

* Review changes

* Added tests

* Fix lint errors

* Move tests from unittest to pytest

* Add minio as test requirement

* Update test_minio_helper.py

* Better event thread handling, added hass test

* Update tests

* Fixed lint errors

* Update test_minio.py

* Review changes

* More review changes

* Removed tests

* Applied code style changes

* Reformat test code
2019-08-20 11:56:11 +02:00
Johann Kellerman b867e3314b
SMA simplify config (#25880) 2019-08-19 22:10:35 +02:00
Pascal Vizeli 1077ec1704
Add packages version to Tensoflow for wheels packages (#26068)
* Add packages version to Tensoflow for wheels packages

* Uncomment tensorflow

* fix string

* Revert version
2019-08-19 16:56:57 +02:00
Malte Franken 9e6732e530 GeoNet NZ Quakes feed integration (#25736)
* initial working version

* support configured unit system and convert distance automatically

* properly unloading integration when removed and stopping refreshes

* ran isort

* fixed pylint

* introduced time filter of seven days into past

* adding unit tests

* fixed lint

* removed unused code

* added test case

* added test case for config flow

* fixed lint

* fixed comment

* removed unused test code

* increased test coverage

* fixed filtering by time

* changed wording in config flow

* reformatted with black

* removed unused logger

* fixed black

* changed default mmi

* reduced the options in the config flow form; fixed a few schema options and processing of data

* moved unsubscribing signals

* fixed minimum magnitude and modified tests

* fixed radius in imperial unit system

* increased test coverage

* simplified code

* fixed lint

* changed string formatting; simplified code

* removed unused strings

* added translation
2019-08-10 12:50:27 +02:00
Ville Skyttä c2556d90ea
Huawei LTE sensor unique id improvements (#25609)
* Convert sensor setup to async

* Improve sensor unique ids

* Save some indent levels, use f-string formatting

* Require getmac in tests

* Fix RouterData init in tests

* Make discovery_info optional in async_setup_platform signature
2019-08-01 19:22:04 +03:00
Ville Skyttä 6b22dbcd0b Blacken top level *.py (#25621)
* Blacken top level *.py

* Tolerate double quotes too in setup.py dependency extraction
2019-08-01 08:30:49 -07:00
Paulus Schoutsen 4de97abc3a Black 2019-07-31 12:25:30 -07:00