From fdcaa9a7e79bd008a3f1d9e9bb7d2fb2d0fbab93 Mon Sep 17 00:00:00 2001 From: Yaron Kaikov Date: Thu, 10 Jul 2025 15:22:20 +0300 Subject: [PATCH] dist/common/scripts/scylla_sysconfig_setup: fix `SyntaxWarning: invalid escape sequence` There are invalid escape sequence warnings where raw strings should be used for the regex patterns Fixes: https://github.com/scylladb/scylladb/issues/24915 Closes scylladb/scylladb#24916 --- dist/common/scripts/scylla_sysconfig_setup | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dist/common/scripts/scylla_sysconfig_setup b/dist/common/scripts/scylla_sysconfig_setup index c775cb2f46..7b1d21a5c8 100755 --- a/dist/common/scripts/scylla_sysconfig_setup +++ b/dist/common/scripts/scylla_sysconfig_setup @@ -86,9 +86,9 @@ if __name__ == '__main__': ethpciid = '' if network_mode == 'dpdk': dpdk_status = out('/opt/scylladb/scripts/dpdk-devbind.py --status') - match = re.search('if={} drv=(\S+)'.format(ifname), dpdk_status, flags=re.MULTILINE) + match = re.search(r'if={} drv=(\S+)'.format(ifname), dpdk_status, flags=re.MULTILINE) ethdrv = match.group(1) - match = re.search('^(\\S+:\\S+:\\S+\.\\S+) [^\n]+ if={} '.format(ifname), dpdk_status, flags=re.MULTILINE) + match = re.search(r'^(\S+:\S+:\S+\.\S+) [^\n]+ if={} '.format(ifname), dpdk_status, flags=re.MULTILINE) ethpciid = match.group(1) if args.mode: