Commit Graph

7 Commits (2b2275dfb38ad438dc0e98dae62fd5665d52a231)

Author SHA1 Message Date
Franck Nijhof 7cd68381f1
Search/replace RESULT_TYPE_* by FlowResultType enum (#74642) 2022-07-07 19:57:36 +03:00
Dave T b261f0fb41
Use more specific exception and simplify aurora_abb_powerone (#73338)
* Use more specific exception for comms timeout

* Remove defered uniqueid assigner now yaml has gone

Co-authored-by: Dave T <davet2001@users.noreply.github.com>
2022-06-13 09:36:46 +02:00
Robert Hillis b869b680fb
Remove deprecated yaml config from aurora abb (#62317) 2021-12-19 18:00:49 +01:00
Dave T 6419950283
Aurora abb improvements (#58504)
* Add type hints.

* Refactor AuroraDevice to AuroraDeviceEntity

* Refactor AuroraDevice to AuroraDeviceEntity

* Connection class is defined in manifest.

* Separate words with underscore in variable names

* Remove duplicated code.

* Remove unused "unknown" string

* Test import yaml when integration already setup

* Remove test already done in config_flow test

* Convert variable names to snake case

* Shorten AuroraDeviceEntity to AuroraEntity

* Add typing

* Remove unnecessary integration setup in test.

* Refactor "already_setup" to "already_configured"

* Use common string

* Reduce the amount of code in the try block.

* Fix merge

* Allow yaml setup to be deferred if no comms

* Properly setup all sensors for defered yaml setup.

* Apply suggestions from code review

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

* Add type hints.

* Refactor AuroraDevice to AuroraDeviceEntity

* Refactor AuroraDevice to AuroraDeviceEntity

* Connection class is defined in manifest.

* Separate words with underscore in variable names

* Remove duplicated code.

* Remove unused "unknown" string

* Test import yaml when integration already setup

* Remove test already done in config_flow test

* Convert variable names to snake case

* Shorten AuroraDeviceEntity to AuroraEntity

* Add typing

* Remove unnecessary integration setup in test.

* Refactor "already_setup" to "already_configured"

* Use common string

* Reduce the amount of code in the try block.

* Allow yaml setup to be deferred if no comms

* Properly setup all sensors for defered yaml setup.

* Code review: move line out of try block.

* Improve test coverage

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-11-04 04:38:47 +01:00
Dave T 51be7d53d6
Aurora abb defer unique_id assignment during yaml import (#58887)
* Defer unique_id assignment during yaml import if dark

* Back out variable name change to simplify.

* Allow config flow yaml setup deferral.

* Fix deferred yaml import

* Code review: only wrap necessary lines in try blk

* Code review: catch possible duplicate unique_id

* Simplify assignment.

* Code review: use timedelta to retry yaml import

* Code review: if a different error occurs, raise it

* Remove current config entry if duplicate unique_id

* Code review: remove unnecessary line.

* Code review: revert change, leave to other PR.

* Code review: remove unnecessary patch & min->sec

* Remove unnecessary else after raise.

* Increase test coverage.

* Check the number of config entries at each stage

* Raise ConfigEntryNotReady when connection fails.

* Log & return false for error on yaml import
2021-11-03 01:30:29 +01:00
Dave T 37930aeeb6
Aurora abb energy metering (#58454)
Co-authored-by: J. Nick Koston <nick@koston.org>
2021-10-28 16:47:49 -05:00
Dave T e22aaea5b2
Aurora abb (solar) configflow (#36300)
Co-authored-by: J. Nick Koston <nick@koston.org>
2021-10-25 20:04:42 -05:00