Commit Graph

17 Commits (fd24baa1f6bfaab7cc7f14a5faa1ce71a6c3bff4)

Author SHA1 Message Date
Ville Skyttä b4bac0f7a0
Exception chaining and wrapping improvements (#39320)
* Remove unnecessary exception re-wraps

* Preserve exception chains on re-raise

We slap "from cause" to almost all possible cases here. In some cases it
could conceivably be better to do "from None" if we really want to hide
the cause. However those should be in the minority, and "from cause"
should be an improvement over the corresponding raise without a "from"
in all cases anyway.

The only case where we raise from None here is in plex, where the
exception for an original invalid SSL cert is not the root cause for
failure to validate a newly fetched one.

Follow local convention on exception variable names if there is a
consistent one, otherwise `err` to match with majority of codebase.

* Fix mistaken re-wrap in homematicip_cloud/hap.py

Missed the difference between HmipConnectionError and
HmipcConnectionError.

* Do not hide original error on plex new cert validation error

Original is not the cause for the new one, but showing old in the
traceback is useful nevertheless.
2020-08-28 13:50:32 +02:00
Daniel Shokouhi 6ad794e1f8
Switch back to create task for Neato (#37913) 2020-07-17 09:29:20 -07:00
Daniel Shokouhi ddfbeffd28
Fix zone cleaning and raise config entry not ready when needed (#37741) 2020-07-14 22:59:03 +02:00
Bas Nijholt 9df71ecae2 Sort imports according to PEP8 for neato (#29724) 2019-12-09 11:05:22 +01:00
Santobert c0619944fa Neato reduce API calls (#29156)
* initial commit

* Fix a bug where some values are not available

* Workaround if git_robot_info() is not available
2019-11-30 21:26:44 -08:00
Santobert 9fb0812ce5 Improve neato tests (#27578)
* Improve tests

* Rename account to configflow

* configflow to config_flow

* Patch pybotvac instead of own code
2019-10-13 13:56:34 -07:00
Santobert 80f6781f21 Migrate Neato to use top-level imports (#27363)
* Neato move imports up

* Move one last import

* Fix tests
2019-10-10 08:08:11 +02:00
Santobert 1a9d07dbdc Improve Neato login process (#27327)
* initial commit

* Readded log message

* Clean up try-except
2019-10-08 10:05:35 -07:00
Daniel Shokouhi 35bca702b4 Neato battery sensor (#27286)
* initial commit

* Pring log only once if available

* Update coverage

* Review comments

* Move variables
2019-10-07 11:09:08 -07:00
Santobert dae8cd8801 Bump pybotvac and use new exceptions (#27249)
* Bump pybotvac

* Fix tests

* Remove super calls

* Surround some more statements

* Correct logger message for vacuum
2019-10-06 20:10:11 +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
Paulus Schoutsen 4de97abc3a Black 2019-07-31 12:25:30 -07:00
Daniel Shokouhi 32e89dcbb6 Add vendor support for vorwerk robots and fix zone retrieval (#25200)
* Add vendor support for vorwerk robots and fix zone retrieval

* Lint

* Review comments

* Lint

* Review commeent

* Remove unused variable

* Review comment

* Remove unused variable
2019-07-18 10:22:05 -07:00
cgtobi 2c07bfb9e0 Remove dependencies and requirements (#23024)
* Remove dependencies and requirements

* Revert "Remove dependencies and requirements"

This reverts commit fe7171b4cd.

* Remove dependencies and requirements

* Revert "Remove dependencies and requirements"

This reverts commit 391355ee2c.

* Remove dependencies and requirements

* Fix flake8 complaints

* Fix more flake8 complaints

* Revert non-component removals
2019-04-12 10:13:30 -07:00
Jérôme W a8a2daeac5 Add custom and zone cleaning to Neato Vacuums (#20779)
* Adding custom and zone cleaning to Neato Vacuums

* Fixing line length and missing imports

* Line too long

* Adding details to the custom service

* Fix linting issues

* Reverting ACTION

* Code cleanup

* Typo

* Requested modifications

* Changing the custom service domain

* No service schema depency anymore

* Removing useless code

* Linting

* Requested changes

* Requested changes for domain

* Revert the service domain back to vacuum
2019-02-23 15:55:55 -06:00
Fabian Affolter 161c368c9d Update file header (#21054)
* Update file header

* Update __init__.py
2019-02-13 20:35:12 -08:00
Paulus Schoutsen e2d3c27e85
Embed all platforms into components (#20677)
* Consolidate all components with platforms

* Organize tests

* Fix more tests

* Fix Verisure tests

* one final test fix

* Add change

* Fix coverage
2019-02-02 07:13:16 -08:00