From 6781219fe87a9dd3c39ac107cdb099261d97ec93 Mon Sep 17 00:00:00 2001 From: "Dr. Strangelove" Date: Wed, 1 May 2024 13:56:55 -0400 Subject: [PATCH] fix: backslash in regex causing warnings - switch to raw string (#1461) fix for https://github.com/looker-open-source/sdk-codegen/issues/1460 --- python/looker_sdk/error.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/looker_sdk/error.py b/python/looker_sdk/error.py index df15def31..b29ee3361 100644 --- a/python/looker_sdk/error.py +++ b/python/looker_sdk/error.py @@ -99,7 +99,7 @@ class ErrorDocHelper: ERROR_CODES_URL: str = "https://static-a.cdn.looker.app/errorcodes/" lookup_dict: Dict[str, Dict[str, str]] = {} RE_PATTERN: str = ( - """(https://docs\.looker\.com/r/err/|https://cloud\.google\.com/looker/docs/r/err/)(.*)/(\d{3})(.*)""" + r'(https://docs\.looker\.com/r/err/|https://cloud\.google\.com/looker/docs/r/err/)(.*)/(\d{3})(.*)' ) pattern = re.compile(RE_PATTERN, flags=re.IGNORECASE)