Commit Graph

7 Commits (00b53502fbad3ec22a53e4c07dea5c420be1a447)

Author SHA1 Message Date
Thomas Schamm 0b7b1baf30
Add switch platform to bosch_shc integration (#62315)
* Add support for switch platform.

* Add untested files to .coveragerc.

* Differ between Light Switch and Smart Plug.
Bumped to boschshcpy==0.2.27

* Removed duplicated code.
Fixed suggestions from code review.

* Fixed pylint errors

* Fix pylint issue.

* Add property statement

* Fixed wrong attribute access

* Apply suggestions from code review

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

* Move switch function to base class.
Changes from code review.

* Apply suggestions from code review

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

* Merged camera switch into SHCSwitch class

* Type hint

* Removed deprecated sensor entities in switch device.
Added routing switch entity.

* Apply suggestions from code review

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

* Icon and EntityCategory as class attributes

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2022-03-08 10:35:29 +01:00
epenet 953a4f07fa
Add setup type hints [b] (#63427)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-01-05 15:04:17 +01:00
Thomas Schamm 40aa852a57
Fix missing power and energy sensors for light switches in bosch_shc (#62802) 2021-12-27 22:54:23 +01:00
epenet 76bdf9bc25
Use new DeviceClass enums in bosch_shc (#61324)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2021-12-09 09:16:14 +01:00
Erik Montnemery 4e07ab1b32
Move temperature conversions to sensor base class (1/8) (#48261)
* Move temperature conversions to entity base class (1/8)

* Update integrations a-c

* Leave old temperature conversion until all integrations are migrated

* tweak

* Use contextlib.suppress

* Remove the MeasurableUnitEntity mixin

* Address comments, add tests

* Fix f-string

* Drop deprecation warning from base entity class

* Update with _attr-shorthand

* Fix rebase mistakes

* Fix additional rebase mistakes

* Only report temperature conversion once

* Fix additional rebase mistakes

* Format homeassistant/components/bbox/sensor.py

* Fix check for overidden _attr_state

* Remove test workarounds from implementation

* Remove useless None-check

* Tweaks

* Migrate new sensors a-c

* Update climacell

* Push deprecation of temperature conversion forward

* Override __repr__ in SensorEntity

* Include native_value in SensorEntity attributes

* Pylint

* Black

* Black

* Fix rebase mistakes

* black

* Fix rebase mistakes

* Revert changes in august/sensor.py

* Revert handling of unit converted restored state

* Apply code review suggestion

* Fix arlo test
2021-08-11 10:45:05 +02:00
Robert Hillis cb1eab6c24
Use entity class attributes for bosch_shc (#53057) 2021-07-18 15:10:42 -05:00
Thomas Schamm ffe8b3e49b
Add bosch shc platforms for sensor devices (#50720) 2021-06-03 14:39:42 +02:00