Lint: W605 invalid escape sequence '\d'
This is the only one where forcing an `r` type to the string was required; the remainder of W605 were replaced with character class enclosures.
This commit is contained in:
parent
7aaca92cdb
commit
27c6ac2b66
|
@ -39,7 +39,7 @@ def get_zookeeper_key():
|
|||
print('ERROR: DNSMASQ_BRIDGE_INTERFACE environment variable not found: {}'.format(e), file=sys.stderr)
|
||||
exit(1)
|
||||
# Get the ID of the interface (the digits)
|
||||
network_vni = re.findall('\d+', interface)[0]
|
||||
network_vni = re.findall(r'\d+', interface)[0]
|
||||
# Create the key
|
||||
zookeeper_key = '/networks/{}/dhcp4_leases'.format(network_vni)
|
||||
return zookeeper_key
|
||||
|
|
Loading…
Reference in New Issue