This is how black sometimes breaks up long strings. Since the line break is between the curly braces, it still works just fine, it just looks weird. Feel free to change it if you'd like to. FWIW, I've moved away from including \ in multiline strings. I'd just do it like below, but any of these 3 ways (current, your fix, my fix) will work fine.
_LOGGER.info(
f"{self.entity_type.title()} Callback ({self.name}): "
f"{state}. User Data: {user_data}"
)
This is how black sometimes breaks up long strings. Since the line break is between the curly braces, it still works just fine, it just looks weird. Feel free to change it if you'd like to. FWIW, I've moved away from including
\
in multiline strings. I'd just do it like below, but any of these 3 ways (current, your fix, my fix) will work fine.