Prepare 0.4.0.dev3 (#172)

* Prepare 0.4.0.dev3

Most notable changes:

* Devices initialized by discovery are pre-initialized using the discovery response data, so no need for update() directly after discovery
* Only the basic information is requested during discovery, as some HS110 and HS220 devices do not respond to multi-module queries
* Fix mac address parsing for KL430
* Add support for KL125 color temperature ranges
* Documentation updates!

* add types-click for mypy hook

* use generator expression for sum
This commit is contained in:
Teemu R
2021-06-16 17:16:45 +02:00
committed by GitHub
parent 8a3ebbff6d
commit 0aa20f6cf9
5 changed files with 504 additions and 445 deletions

View File

@@ -143,7 +143,7 @@ class SmartStrip(SmartDevice):
async def current_consumption(self) -> float:
"""Get the current power consumption in watts."""
consumption = sum([await plug.current_consumption() for plug in self.children])
consumption = sum(await plug.current_consumption() for plug in self.children)
return consumption