Use f-strings in integrations starting with "H" - "L" (#32265)

* Use f-strings in integrations starting with "H"

* Use f-strings in integrations starting with "I"

* Use f-strings in integrations starting with "J"

* Use f-strings in integrations starting with "K"

* Use f-strings in integrations starting with "L"

* Fix lint error

* Use join instead of f-string in homekit_controller

* Use local variables with f-strings

* Fix lint error

* Escape the characters in f-string

* Sort imports with isort in homeworks light

* Fix pylint error

* Fix broken tests

* Fix broken tests v2
This commit is contained in:
springstan authored and GitHub committed 2020-02-28 12:39:29 +01:00
1 parent 7714160f4c
commit 157f972d72
77 files changed
+158 -246

No files matched your search

+3 -2
View File
@@ -48,8 +48,9 @@ class KonnectedSwitch(ToggleEntity):
self._repeat = self._data.get(CONF_REPEAT)
self._state = self._boolean_state(self._data.get(ATTR_STATE))
self._name = self._data.get(CONF_NAME)
self._unique_id = "{}-{}-{}-{}-{}".format(
device_id, self._zone_num, self._momentary, self._pause, self._repeat
self._unique_id = (
f"{device_id}-{self._zone_num}-{self._momentary}-"
f"{self._pause}-{self._repeat}"
)
@property