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:
1 parent
7714160f4c
commit
157f972d72
77 files changed
+158
-246
No files matched your search
@@ -28,8 +28,6 @@ from homeassistant.loader import bind_hass
|
||||
|
||||
DOMAIN = "input_boolean"
|
||||
|
||||
ENTITY_ID_FORMAT = DOMAIN + ".{}"
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
CONF_INITIAL = "initial"
|
||||
@@ -155,7 +153,7 @@ class InputBoolean(ToggleEntity, RestoreEntity):
|
||||
self._state = config.get(CONF_INITIAL)
|
||||
if from_yaml:
|
||||
self._editable = False
|
||||
self.entity_id = ENTITY_ID_FORMAT.format(self.unique_id)
|
||||
self.entity_id = f"{DOMAIN}.{self.unique_id}"
|
||||
|
||||
@property
|
||||
def should_poll(self):
|
||||
|
||||
Reference in new issue
Block a user