From 16dfe4717b0ef0214c66dc2e575a7c0feebfea3c Mon Sep 17 00:00:00 2001 From: Ho Cheung Date: Mon, 20 Oct 2025 16:42:53 -0700 Subject: [PATCH] Fix a SyntaxWarning using raw strings 137: SyntaxWarning: invalid escape sequence '\d'. Bug: 40283283 Change-Id: I09864101f572ecc1a0c6abf2d6cf2653129d3b87 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7058230 Reviewed-by: Gavin Mak Reviewed-by: Brian Ryner Commit-Queue: Ho Cheung --- upload_to_google_storage_first_class.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/upload_to_google_storage_first_class.py b/upload_to_google_storage_first_class.py index 68ae3f8341..b3623e006a 100755 --- a/upload_to_google_storage_first_class.py +++ b/upload_to_google_storage_first_class.py @@ -134,7 +134,7 @@ def upload_to_google_storage(file: str, base_url: str, object_name: str, raise Exception( code, 'Encountered error on uploading %s to %s\n%s' % (file, file_url, err)) - pattern = re.escape(file_url) + '#(?P\d+)' + pattern = re.escape(file_url) + r'#(?P\d+)' # The geneartion number is printed as part of the progress / status info # which gsutil outputs to stderr to keep separated from any final output # data.