mirror of
https://github.com/esphome/esphome.git
synced 2024-12-22 13:34:54 +01:00
Fix invalid escape sequences in regex (#1814)
This commit is contained in:
parent
86ac7f3a59
commit
4c4099966a
1 changed files with 1 additions and 2 deletions
|
@ -205,8 +205,7 @@ def maybe_simple_message(schema):
|
|||
|
||||
def validate_printf(value):
|
||||
# https://stackoverflow.com/questions/30011379/how-can-i-parse-a-c-format-string-in-python
|
||||
# pylint: disable=anomalous-backslash-in-string
|
||||
cfmt = """\
|
||||
cfmt = r"""
|
||||
( # start of capture group 1
|
||||
% # literal "%"
|
||||
(?:[-+0 #]{0,5}) # optional flags
|
||||
|
|
Loading…
Reference in a new issue