@@ -421,7 +421,7 @@ def check_field(self, field, required_channels="all"):
421421 # Record specification fields
422422 elif field == "record_name" :
423423 # Allow letters, digits, hyphens, and underscores.
424- accepted_string = re .match ("[-\w]+" , self .record_name )
424+ accepted_string = re .match (r "[-\w]+" , self .record_name )
425425 if (
426426 not accepted_string
427427 or accepted_string .string != self .record_name
@@ -461,7 +461,7 @@ def check_field(self, field, required_channels="all"):
461461
462462 if field == "file_name" :
463463 # Check for file_name characters
464- accepted_string = re .match ("[-\w]+\.?[\w]+" , item [ch ])
464+ accepted_string = re .match (r "[-\w]+\.?[\w]+" , item [ch ])
465465 if (
466466 not accepted_string
467467 or accepted_string .string != item [ch ]
@@ -505,7 +505,7 @@ def check_field(self, field, required_channels="all"):
505505 "baseline values must be between -2147483648 (-2^31) and 2147483647 (2^31 -1)"
506506 )
507507 elif field == "units" :
508- if re .search ("\s" , item [ch ]):
508+ if re .search (r "\s" , item [ch ]):
509509 raise ValueError (
510510 "units strings may not contain whitespaces."
511511 )
@@ -520,7 +520,7 @@ def check_field(self, field, required_channels="all"):
520520 "block_size values must be non-negative integers"
521521 )
522522 elif field == "sig_name" :
523- if re .search ("\s" , item [ch ]):
523+ if re .search (r "\s" , item [ch ]):
524524 raise ValueError (
525525 "sig_name strings may not contain whitespaces."
526526 )
@@ -534,7 +534,7 @@ def check_field(self, field, required_channels="all"):
534534 # Segment names must be alphanumerics or just a single '~'
535535 if item [ch ] == "~" :
536536 continue
537- accepted_string = re .match ("[-\w]+" , item [ch ])
537+ accepted_string = re .match (r "[-\w]+" , item [ch ])
538538 if (
539539 not accepted_string
540540 or accepted_string .string != item [ch ]
0 commit comments