diff --git a/examples/authentication/generate_user_credentials.py b/examples/authentication/generate_user_credentials.py index 9a137c047..9d6777363 100755 --- a/examples/authentication/generate_user_credentials.py +++ b/examples/authentication/generate_user_credentials.py @@ -161,7 +161,7 @@ def parse_raw_query_params(data): # Decode the request into a utf-8 encoded string decoded = data.decode("utf-8") # Use a regular expression to extract the URL query parameters string - match = re.search("GET\s\/\?(.*) ", decoded) + match = re.search(r"GET\s\/\?(.*) ", decoded) params = match.group(1) # Split the parameters to isolate the key/value pairs pairs = [pair.split("=") for pair in params.split("&")] diff --git a/google/ads/googleads/config.py b/google/ads/googleads/config.py index 409bb580c..890f0e68c 100644 --- a/google/ads/googleads/config.py +++ b/google/ads/googleads/config.py @@ -206,7 +206,7 @@ def _validate_customer_id(customer_id, id_type): """ if customer_id is not None: # Checks that the string is comprised only of 10 digits. - pattern = re.compile("^\d{10}", re.ASCII) + pattern = re.compile(r"^\d{10}", re.ASCII) if not pattern.fullmatch(customer_id): raise ValueError( f"The specified {id_type} customer ID is invalid. It must be a "