1
0
mirror of https://github.com/esphome/esphome.git synced 2025-09-09 23:02:23 +01:00

Bump pylint from 2.10.2 to 2.11.1 (#2334)

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Otto winter <otto@otto-winter.com>
This commit is contained in:
dependabot[bot]
2021-09-19 19:22:28 +02:00
committed by GitHub
parent 50da630811
commit dbb195691b
40 changed files with 219 additions and 384 deletions

View File

@@ -266,8 +266,7 @@ async def to_code(config):
if CONF_SSL_FINGERPRINTS in config:
for fingerprint in config[CONF_SSL_FINGERPRINTS]:
arr = [
cg.RawExpression("0x{}".format(fingerprint[i : i + 2]))
for i in range(0, 40, 2)
cg.RawExpression(f"0x{fingerprint[i:i + 2]}") for i in range(0, 40, 2)
]
cg.add(var.add_ssl_fingerprint(arr))
cg.add_build_flag("-DASYNC_TCP_SSL_ENABLED=1")
@@ -353,9 +352,7 @@ def get_default_topic_for(data, component_type, name, suffix):
sanitized_name = "".join(
x for x in name.lower().replace(" ", "_") if x in allowlist
)
return "{}/{}/{}/{}".format(
data.topic_prefix, component_type, sanitized_name, suffix
)
return f"{data.topic_prefix}/{component_type}/{sanitized_name}/{suffix}"
async def register_mqtt_component(var, config):