Skip to content

Commit f0fed07

Browse files
committed
fix(build): fix Python warning
f"\S" is interpreted as f"\\S", but a warning is issued by Python: tools/collect-copyright:837: SyntaxWarning: invalid escape sequence '\S' match = re.match(f"^(?P<package>\S+): (?P<file>.*)$", line) Fix this warning by writing f"\\S" explicitly.
1 parent ac3e925 commit f0fed07

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/collect-copyright

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -834,7 +834,7 @@ class Debian:
834834

835835
packages = []
836836
for line in process.stdout.splitlines():
837-
match = re.match(f"^(?P<package>\S+): (?P<file>.*)$", line)
837+
match = re.match(f"^(?P<package>\\S+): (?P<file>.*)$", line)
838838
if match is not None:
839839
file = match.group("file")
840840
package_name = match.group("package")

0 commit comments

Comments
 (0)