diff --git a/pscheduler-tool-ethr/ethr/run b/pscheduler-tool-ethr/ethr/run index 557801f0fa..bf2546bd98 100755 --- a/pscheduler-tool-ethr/ethr/run +++ b/pscheduler-tool-ethr/ethr/run @@ -167,7 +167,7 @@ def run_client(): # Make the result and return it - matcher = re.compile('^\[([^]]+)\]\s+(TCP|UDP)\s+([^\s]+)-([^\s]+)\s+[^\s]+\s*([^\s]+)$') + matcher = re.compile(r'^\[([^]]+)\]\s+(TCP|UDP)\s+([^\s]+)-([^\s]+)\s+[^\s]+\s*([^\s]+)$') def group_block(stream, start, end, bps): diff --git a/pscheduler-tool-globus/globus/run b/pscheduler-tool-globus/globus/run index 4cf47c6f42..bfcff81994 100755 --- a/pscheduler-tool-globus/globus/run +++ b/pscheduler-tool-globus/globus/run @@ -78,7 +78,7 @@ if True: for line in lines: logger.debug("searching line: {0}".format(line)) #make sure you grab the last one because each screen update its own line - test = re.search('\s*(\d+) bytes\s+(\S+) ([A-za-z])B/sec avg\s+\S+ [A-za-z]B/sec inst$', line) + test = re.search(r'\s*(\d+) bytes\s+(\S+) ([A-za-z])B/sec avg\s+\S+ [A-za-z]B/sec inst$', line) if test: logger.debug("looks like a performance metric line") bytes_sent = int(test.group(1)) diff --git a/pscheduler-tool-iperf2/iperf2/iperf2_parser.py b/pscheduler-tool-iperf2/iperf2/iperf2_parser.py index 4bb1090a99..14c920fd70 100644 --- a/pscheduler-tool-iperf2/iperf2/iperf2_parser.py +++ b/pscheduler-tool-iperf2/iperf2/iperf2_parser.py @@ -71,7 +71,7 @@ def parse_output(lines, expect_udp=False, logger=None): # Bogus numbers - if re.match('\(nan%\)', line): + if re.match(r'\(nan%\)', line): return { 'succeeded': False, 'error': 'Found NaN result' @@ -79,7 +79,7 @@ def parse_output(lines, expect_udp=False, logger=None): # Connection failures - if re.match('read failed: Connection refused', line): + if re.match(r'read failed: Connection refused', line): return { 'succeeded': False, 'error': 'Connection refused' @@ -91,7 +91,7 @@ def parse_output(lines, expect_udp=False, logger=None): # Client connecting to localhost, TCP port 5001 with pid 119661 (1 flows) # Client connecting to localhost, UDP port 5001 with pid 119686 (1 flows) - test = re.match('^Client connecting to .*, (TCP|UDP) port', line) + test = re.match(r'^Client connecting to .*, (TCP|UDP) port', line) if test: protocol = test.group(1) if (protocol == 'TCP' and expect_udp) or (protocol == 'UDP' and not expect_udp): @@ -108,7 +108,7 @@ def parse_output(lines, expect_udp=False, logger=None): # TCP window size: 2626560 Byte (default) # TCP window size: 425984 Byte (WARNING: requested 1000000 Byte) - test = re.match('^TCP window size:\s+(\d+) Byte (\(WARNING: requested (\d+) Byte\))?', line) + test = re.match(r'^TCP window size:\s+(\d+) Byte (\(WARNING: requested (\d+) Byte\))?', line) if test: assert not expect_udp results['tcp-window-size'] = int(test.group(1)) @@ -126,7 +126,7 @@ def parse_output(lines, expect_udp=False, logger=None): # stream. This shouldn't matter because, in theory, they # should all be the same. - test = re.match('^\[\s*\d+\].*\(icwnd/mss/irtt=\d+/(\d+)/\d+\)', line) + test = re.match(r'^\[\s*\d+\].*\(icwnd/mss/irtt=\d+/(\d+)/\d+\)', line) if test: assert not expect_udp results['mss'] = int(test.group(1)) @@ -134,7 +134,7 @@ def parse_output(lines, expect_udp=False, logger=None): # If we start seeing server reports, we've seen everything # from the client side. Treat it as EOF. - if re.match('^\[\s*(\d+|SUM) Server Report:', line): + if re.match(r'^\[\s*(\d+|SUM) Server Report:', line): break # Interval @@ -151,14 +151,14 @@ def parse_output(lines, expect_udp=False, logger=None): # [ 1] 4.00-6.00 sec 263130 Bytes 1052520 bits/sec 179/0 89 pps test = re.match( - '^\[\s*(\d+|SUM)\]' # 1 - Stream ID - '\s+(\d+\.\d+)' # 2 - Interval start - '-(\d+\.\d+) sec' # 3 - Interval end - '\s+(\d+) Bytes' # 4 - Bytes transferred - '\s+(\d+) bits/sec' # 5 - Bandwidth - '\s+(\d+)' # 6 - Writes - '/(\d+)' # 7 - Errors - '\s+(\d+) pps$' # 8 - Packets per second + r'^\[\s*(\d+|SUM)\]' # 1 - Stream ID + r'\s+(\d+\.\d+)' # 2 - Interval start + r'-(\d+\.\d+) sec' # 3 - Interval end + r'\s+(\d+) Bytes' # 4 - Bytes transferred + r'\s+(\d+) bits/sec' # 5 - Bandwidth + r'\s+(\d+)' # 6 - Writes + r'/(\d+)' # 7 - Errors + r'\s+(\d+) pps$' # 8 - Packets per second , line) if not test: @@ -184,21 +184,21 @@ def parse_output(lines, expect_udp=False, logger=None): # [ 1] 2.00-4.00 sec 11173888000 Bytes 44695552000 bits/sec 85250/0 10 1470K/33(4) us 169301333 test = re.match( - '^\[\s*(\d+|SUM)\]' # 1 - Stream ID - '\s+(\d+\.\d+)' # 2 - Interval start - '-(\d+\.\d+) sec' # 3 - Interval end - '\s+(\d+) Bytes' # 4 - Bytes transferred - '\s+(\d+) bits/sec' # 5 - Bandwidth - '\s+(\d+)' # 6 - Writes - '/(\d+)' # 7 - Errors - '\s+(\d+)' # 8 - Retransmits - '(' # 9 - Begin optional stuff - '\s+(\d+K)' # 10 - Window size in SI units - '/(\d+)' # 11 - RTT - '\((\d+)\) us' # 12 - RTT Variance(?) - '\s*(\d+)' # 13 - Net Power (Experimental) - ')?' - '\s*$' + r'^\[\s*(\d+|SUM)\]' # 1 - Stream ID + r'\s+(\d+\.\d+)' # 2 - Interval start + r'-(\d+\.\d+) sec' # 3 - Interval end + r'\s+(\d+) Bytes' # 4 - Bytes transferred + r'\s+(\d+) bits/sec' # 5 - Bandwidth + r'\s+(\d+)' # 6 - Writes + r'/(\d+)' # 7 - Errors + r'\s+(\d+)' # 8 - Retransmits + r'(' # 9 - Begin optional stuff + r'\s+(\d+K)' # 10 - Window size in SI units + r'/(\d+)' # 11 - RTT + r'\((\d+)\) us' # 12 - RTT Variance(?) + r'\s*(\d+)' # 13 - Net Power (Experimental) + r')?' + r'\s*$' , line) if not test: diff --git a/pscheduler-tool-nmapreach/nmapreach/run b/pscheduler-tool-nmapreach/nmapreach/run index 08077756fe..1a2f251f0a 100755 --- a/pscheduler-tool-nmapreach/nmapreach/run +++ b/pscheduler-tool-nmapreach/nmapreach/run @@ -140,7 +140,7 @@ nmap_first_args = [ 'nmap', '-n', '-sP', '-oG', '-', '--host-timeout', str(timeo # The lines we want look like this: # Host: 192.168.1.1 () Status: Up -nmap_output_matcher = re.compile("^Host:\s*([^\s]+)\s.*Status:\s*Up") +nmap_output_matcher = re.compile(r'^Host:\s*([^\s]+)\s.*Status:\s*Up') nmap_timeout = timeout * 1.5 diff --git a/pscheduler-tool-nuttcp/nuttcp/nuttcp_parser.py b/pscheduler-tool-nuttcp/nuttcp/nuttcp_parser.py index 5da9ec6314..42a14d3821 100644 --- a/pscheduler-tool-nuttcp/nuttcp/nuttcp_parser.py +++ b/pscheduler-tool-nuttcp/nuttcp/nuttcp_parser.py @@ -20,7 +20,7 @@ def parse_output(lines): # Example line: # 216.8125 MB / 1.00 sec = 1817.8571 Mbps 45 retrans 206 KB-cwnd - test = re.match('^.* (\d+)\.\d+ sec \=\s*(\d+(\.\d+)?) (\S)bps\s*(\d+) retrans(\s*(\d+)\s*(\S)\S\-cwnd)?', line) + test = re.match(r'^.* (\d+)\.\d+ sec \=\s*(\d+(\.\d+)?) (\S)bps\s*(\d+) retrans(\s*(\d+)\s*(\S)\S\-cwnd)?', line) if test: spacing = int(test.group(1)) value = test.group(2) @@ -52,7 +52,7 @@ def parse_output(lines): # Example UDP line # 25.1572 MB / 1.00 sec = 211.0065 Mbps 62 / 25823 ~drop/pkt 0.24 ~%loss 4.8672 msMaxJitter - test = re.match('^.* (\d+)\.\d+ sec \=\s*(\d+(\.\d+)?) (\S)bps\s*(\d+) / (\d+) ~drop/pkt\s*(\d+\.\d+) ~%loss\s*(\d+\.\d+) msMaxJitter', line) + test = re.match(r'^.* (\d+)\.\d+ sec \=\s*(\d+(\.\d+)?) (\S)bps\s*(\d+) / (\d+) ~drop/pkt\s*(\d+\.\d+) ~%loss\s*(\d+\.\d+) msMaxJitter', line) if test: spacing = int(test.group(1)) value = test.group(2) @@ -84,7 +84,7 @@ def parse_output(lines): # Example summary line: # 2197.0657 MB / 10.00 sec = 1842.3790 Mbps 8 %TX 90 %RX 90 retrans 237 KB-cwnd 0.50 msRTT - test = re.match('^.* (\d+)\.\d+ sec =\s*(\d+(\.\d+)?) (\S)bps \d+ %TX \d+ %RX (\d+) retrans(\s*(\d+)\s*(\S)\S\-cwnd)?', line) + test = re.match(r'^.* (\d+)\.\d+ sec =\s*(\d+(\.\d+)?) (\S)bps \d+ %TX \d+ %RX (\d+) retrans(\s*(\d+)\s*(\S)\S\-cwnd)?', line) if test: duration = int(test.group(1)) value = test.group(2) @@ -108,7 +108,7 @@ def parse_output(lines): # Example UDP summary line # 252.0586 MB / 10.00 sec = 211.4462 Mbps 99 %TX 50 %RX 1485 / 259593 drop/pkt 0.57 %loss 37.2012 msMaxJitter - test = re.match('^.* (\d+)\.\d+ sec \=\s*(\d+(\.\d+)?) (\S)bps\s*(\d+) %TX (\d+) %RX (\d+) / (\d+) drop/pkt\s*(\d+\.\d+) %loss\s*(\d+\.\d+) msMaxJitter', line) + test = re.match(r'^.* (\d+)\.\d+ sec \=\s*(\d+(\.\d+)?) (\S)bps\s*(\d+) %TX (\d+) %RX (\d+) / (\d+) drop/pkt\s*(\d+\.\d+) %loss\s*(\d+\.\d+) msMaxJitter', line) if test: duration = int(test.group(1)) value = test.group(2) diff --git a/pscheduler-tool-owping/owping/run b/pscheduler-tool-owping/owping/run index 4800020d21..fb94f6962f 100755 --- a/pscheduler-tool-owping/owping/run +++ b/pscheduler-tool-owping/owping/run @@ -167,7 +167,7 @@ if role == CLIENT_ROLE: pscheduler.succeed_json(results) #Parse output - owping_regex = re.compile('^(\d+) (\d+) (\d) ([-.0-9e+]*) (\d+) (\d) ([-.0-9e+]*) (\d+)$') + owping_regex = re.compile(r'^(\d+) (\d+) (\d) ([-.0-9e+]*) (\d+) (\d) ([-.0-9e+]*) (\d+)$') results['packets-sent'] = 0 results['packets-received'] = 0 results['packets-duplicated'] = 0 @@ -285,7 +285,7 @@ elif role == SERVER_ROLE: # pscheduler.fail("Control port must be an integer") # # #data-port-range must be in form N-M where N < M and both are integers -# range_match = re.compile("(\d+)-(\d+)").match(recv_participant_data['data-port-range']) +# range_match = re.compile(r'(\d+)-(\d+)').match(recv_participant_data['data-port-range']) # if not range_match: # pscheduler.fail("Data port range is not a valid range. Must be in form N-M where N < M and both are integers") # elif range_match.group(1) >= range_match.group(2): diff --git a/pscheduler-tool-paris-traceroute/paris-traceroute/run b/pscheduler-tool-paris-traceroute/paris-traceroute/run index 75c7783c87..49dc2f995b 100755 --- a/pscheduler-tool-paris-traceroute/paris-traceroute/run +++ b/pscheduler-tool-paris-traceroute/paris-traceroute/run @@ -230,10 +230,10 @@ ips = [] last_hop = 0 for line in stdout.split('\n'): - line = re.sub('\s+', ' ', line).strip() + line = re.sub(r'\s+', ' ', line).strip() - matches = re.match('^(\d*)\s+(.*)$', line) + matches = re.match(r'^(\d*)\s+(.*)$', line) if matches is None: log.debug("Discarding: %s", line) continue diff --git a/pscheduler-tool-powstream/powstream/powstream_utils.py b/pscheduler-tool-powstream/powstream/powstream_utils.py index c5f0540636..7199f5bc02 100644 --- a/pscheduler-tool-powstream/powstream/powstream_utils.py +++ b/pscheduler-tool-powstream/powstream/powstream_utils.py @@ -157,7 +157,7 @@ def parse_raw_owamp_output(file, raw_output=False, bucket_width=TIME_SCALE): 'schema': LATENCY_SCHEMA_VERSION, 'succeeded': False } - powstream_regex = re.compile('^(\d+) (\d+) (\d) ([-.0-9e+]*) (\d+) (\d) ([-.0-9e+]*) (\d+)$') + powstream_regex = re.compile(r'^(\d+) (\d+) (\d) ([-.0-9e+]*) (\d+) (\d) ([-.0-9e+]*) (\d+)$') results['packets-sent'] = 0 results['packets-received'] = 0 results['packets-duplicated'] = 0 diff --git a/pscheduler-tool-tcpping/tcpping/run b/pscheduler-tool-tcpping/tcpping/run index 6685f05c9c..abe4dcca51 100755 --- a/pscheduler-tool-tcpping/tcpping/run +++ b/pscheduler-tool-tcpping/tcpping/run @@ -184,18 +184,18 @@ result = { # TCP Ping Results: Connections (Total/Pass/Fail): [3/3/0] (Failed: 0%) -CONNECTED = re.compile('^Connected to\\s*[^\\s]+' - '\\s+\\(([^)]+)\)' - '\\s+.*:' - '\\s+tcp_seq=([0-9]+)' - '\\s+time=([0-9.]+) ms$') +CONNECTED = re.compile(r'^Connected to\\s*[^\\s]+' + r'\\s+\\(([^)]+)\)' + r'\\s+.*:' + r'\\s+tcp_seq=([0-9]+)' + r'\\s+time=([0-9.]+) ms$') # TCP Ping Results: Connections (Total/Pass/Fail): [3/3/0] (Failed: 0%) -COUNTED = re.compile('^TCP Ping Results: Connections \\(Total/Pass/Fail\\): \\[([0-9]+)/([0-9]+)/([0-9]+)\\]') +COUNTED = re.compile(r'^TCP Ping Results: Connections \\(Total/Pass/Fail\\): \\[([0-9]+)/([0-9]+)/([0-9]+)\\]') # rtt min/avg/max/mdev = 32.660/32.827/33.150/0.280 ms -STATS = re.compile('^rtt min/avg/max/mdev\\s+=\\s+' - '([0-9.]+)/([0-9.]+)/([0-9.]+)/([0-9.]+)\\s+ms') +STATS = re.compile(r'^rtt min/avg/max/mdev\\s+=\\s+' + r'([0-9.]+)/([0-9.]+)/([0-9.]+)/([0-9.]+)\\s+ms') diff --git a/pscheduler-tool-tracepath/tracepath/run b/pscheduler-tool-tracepath/tracepath/run index 908601cafe..278552f7c2 100755 --- a/pscheduler-tool-tracepath/tracepath/run +++ b/pscheduler-tool-tracepath/tracepath/run @@ -151,15 +151,15 @@ traced_hops = [] ips = [] last_hop = 0 -ttl_re = re.compile('^(\d*)\??:'); -no_reply_re = re.compile('no reply'); -reached_re = re.compile('reached'); -rtt_re = re.compile('([0-9]+\.[0-9]+)ms'); -mtu_re = re.compile('pmtu ([0-9]+)'); -error_re = re.compile('!(\w+)$'); +ttl_re = re.compile(r'^(\d*)\??:'); +no_reply_re = re.compile(r'no reply'); +reached_re = re.compile(r'reached'); +rtt_re = re.compile(r'([0-9]+\.[0-9]+)ms'); +mtu_re = re.compile(r'pmtu ([0-9]+)'); +error_re = re.compile(r'!(\w+)$'); path_mtu = None for line in stdout.split('\n'): - line = re.sub('\s+', ' ', line).strip() + line = re.sub(r'\s+', ' ', line).strip() matches = ttl_re.match(line) if matches is None: continue diff --git a/pscheduler-tool-traceroute/traceroute/run b/pscheduler-tool-traceroute/traceroute/run index e9fd5a594b..c5efb7cbbf 100755 --- a/pscheduler-tool-traceroute/traceroute/run +++ b/pscheduler-tool-traceroute/traceroute/run @@ -326,10 +326,10 @@ ips = [] last_hop = 0 for line in stdout.split('\n'): - line = re.sub('\s+', ' ', line).strip() + line = re.sub(r'\s+', ' ', line).strip() - matches = re.match('^(\d*)\s+(.*)$', line) + matches = re.match(r'^(\d*)\s+(.*)$', line) if matches is None: log.debug("Discarding: %s", line) continue diff --git a/pscheduler-tool-twping/twping/run b/pscheduler-tool-twping/twping/run index 20a29e0dc5..00893d8559 100755 --- a/pscheduler-tool-twping/twping/run +++ b/pscheduler-tool-twping/twping/run @@ -237,7 +237,7 @@ if role == CLIENT_ROLE: # RS recv synchronized boolean unsigned # RERR recv err estimate float (%g) # RTTL reflected ttl unsigned short - twping_regex = re.compile('^(\d+) (\d+) (\d) ([-.0-9e+]*) (\d+) (\d) ([-.0-9e+]*) (\d+) (\d+) (\d+) (\d) ([-.0-9e+]*) (\d+) (\d) ([-.0-9e+]*) (\d+)$') + twping_regex = re.compile(r'^(\d+) (\d+) (\d) ([-.0-9e+]*) (\d+) (\d) ([-.0-9e+]*) (\d+) (\d+) (\d+) (\d) ([-.0-9e+]*) (\d+) (\d) ([-.0-9e+]*) (\d+)$') results['packets-sent'] = 0 results['packets-received'] = 0 results['packets-duplicated'] = 0 @@ -416,7 +416,7 @@ elif role == SERVER_ROLE: # pscheduler.fail("Control port must be an integer") # # #data-port-range must be in form N-M where N < M and both are integers -# range_match = re.compile("(\d+)-(\d+)").match(recv_participant_data['data-port-range']) +# range_match = re.compile(r'(\d+)-(\d+)').match(recv_participant_data['data-port-range']) # if not range_match: # pscheduler.fail("Data port range is not a valid range. Must be in form N-M where N < M and both are integers") # elif range_match.group(1) >= range_match.group(2): diff --git a/python-pscheduler/pscheduler/pscheduler/jsonval.py b/python-pscheduler/pscheduler/pscheduler/jsonval.py index 7171086679..315277f890 100644 --- a/python-pscheduler/pscheduler/pscheduler/jsonval.py +++ b/python-pscheduler/pscheduler/pscheduler/jsonval.py @@ -350,7 +350,7 @@ "oneOf": [ { "type": "string", - "pattern": "^[0-9]+(\\.[0-9]+)?(\\s*[KkMmGgTtPpEeZzYy][Ii]?)?$" + "pattern": r'^[0-9]+(\\.[0-9]+)?(\\s*[KkMmGgTtPpEeZzYy][Ii]?)?$' }, { "type": "integer" diff --git a/python-pscheduler/pscheduler/pscheduler/limitprocessor/identifier/localsubnet.py b/python-pscheduler/pscheduler/pscheduler/limitprocessor/identifier/localsubnet.py index 5eb7a3ab6a..e50588da2e 100644 --- a/python-pscheduler/pscheduler/pscheduler/limitprocessor/identifier/localsubnet.py +++ b/python-pscheduler/pscheduler/pscheduler/limitprocessor/identifier/localsubnet.py @@ -20,7 +20,7 @@ def data_is_valid(data): # These are for ue by ipv6_netmask_size() -ipv6_netmask_re = re.compile("^([f]*)([ec80]?)0*$") +ipv6_netmask_re = re.compile(r'^([f]*)([ec80]?)0*$') ipv6_digit_bits = { "e": 3, diff --git a/python-pscheduler/pscheduler/pscheduler/mtu.py b/python-pscheduler/pscheduler/pscheduler/mtu.py index cd59e0e8b3..2d11fbb2e5 100644 --- a/python-pscheduler/pscheduler/pscheduler/mtu.py +++ b/python-pscheduler/pscheduler/pscheduler/mtu.py @@ -9,8 +9,8 @@ from .ipaddr import ip_addr_version from .program import run_program -mtu_match = re.compile("^.*pmtu ([0-9]+)") -hop_match = re.compile("^\s*[0-9]+\??:") +mtu_match = re.compile(r'^.*pmtu ([0-9]+)') +hop_match = re.compile(r'^\s*[0-9]+\??:') def mtu_path_is_safe(host, ipversion=None): diff --git a/python-pscheduler/pscheduler/pscheduler/ping.py b/python-pscheduler/pscheduler/pscheduler/ping.py index 51a446db2b..ce720c8cb9 100644 --- a/python-pscheduler/pscheduler/pscheduler/ping.py +++ b/python-pscheduler/pscheduler/pscheduler/ping.py @@ -20,20 +20,24 @@ def parse_ping(output, count): # Matchers for output lines we care about # - PACKET_RETURNED = re.compile("^([0-9]+) bytes" - "\s+from (.*):" - "\s+icmp_[rs]eq=([0-9]+)" - "\s+ttl=([0-9]+)" - "\s+time=([0-9.]+) ms" - "$") + PACKET_RETURNED = re.compile( + r'^([0-9]+) bytes' + r'\s+from (.*):' + r'\s+icmp_[rs]eq=([0-9]+)' + r'\s+ttl=([0-9]+)' + r'\s+time=([0-9.]+) ms' + r'$' + ) # Error: From 5.6.7.8 icmp_seq=7 Destination Net Unreachable - ERROR_RETURNED = re.compile("^From" - "\s+([^\s]+)" - "\s+icmp_seq=([0-9]+)" - "\s+(.*)" - "$") + ERROR_RETURNED = re.compile( + r'^From' + r'\s+([^\s]+)' + r'\s+icmp_seq=([0-9]+)' + r'\s+(.*)' + r'$' + ) # Error messages known to be output by ping ERROR_STRINGS = { @@ -47,24 +51,26 @@ def parse_ping(output, count): # Same, but require regexps to match ERROR_MATCHES = [ - ( re.compile("^Frag needed and DF set"), 'fragmentation-needed-and-df-set' ) + ( re.compile(r'^Frag needed and DF set'), 'fragmentation-needed-and-df-set' ) ] # Sent/received/loss statistics: # 5 packets transmitted, 5 received, 0% packet loss, time 4131ms LOSS_STATS = re.compile( - '^([0-9]+) packets transmitted,' - ' ([0-9]+) received,' - ' ([0-9.]+)% packet loss') + r'^([0-9]+) packets transmitted,' + r' ([0-9]+) received,' + r' ([0-9.]+)% packet loss') # Times: rtt min/avg/max/mdev = 19.631/24.191/29.874/4.262 ms - TIMES_RETURNED = re.compile("^rtt min/avg/max/mdev\s*=\s*" - "([0-9.]+)" - "/([0-9.]+)" - "/([0-9.]+)" - "/([0-9.]+)" - "\s+ms$") + TIMES_RETURNED = re.compile( + r'^rtt min/avg/max/mdev\s*=\s*' + r'([0-9.]+)' + r'/([0-9.]+)' + r'/([0-9.]+)' + r'/([0-9.]+)' + r'\s+ms$' + ) roundtrips = [] ips = [] diff --git a/python-pscheduler/pscheduler/pscheduler/sinumber.py b/python-pscheduler/pscheduler/pscheduler/sinumber.py index d13bffd40d..582c56af93 100644 --- a/python-pscheduler/pscheduler/pscheduler/sinumber.py +++ b/python-pscheduler/pscheduler/pscheduler/sinumber.py @@ -27,7 +27,7 @@ 'yi': 1024 ** 8 } -si_regex = re.compile('^(-?[0-9]+(\.[0-9]+)?)\s*([kmgtpezy][i]?)?$') +si_regex = re.compile(r'^(-?[0-9]+(\.[0-9]+)?)\s*([kmgtpezy][i]?)?$') def si_as_number(text):