From 54174fd6d25650a36d7a3e9445e5b24af968e87e Mon Sep 17 00:00:00 2001 From: DanielConnelly Date: Tue, 2 Jun 2026 17:02:43 +0100 Subject: [PATCH] [ISS-1258][DC] adding encoding to resolve windows issues --- pre_commit_hooks/detect_aws_credentials.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pre_commit_hooks/detect_aws_credentials.py b/pre_commit_hooks/detect_aws_credentials.py index cab4ca4..b408edd 100644 --- a/pre_commit_hooks/detect_aws_credentials.py +++ b/pre_commit_hooks/detect_aws_credentials.py @@ -44,7 +44,7 @@ def get_aws_secrets_from_json(json_credentials_file: str) -> set[str]: """ aws_credentials_file_path = os.path.expanduser(json_credentials_file) - with open(aws_credentials_file_path) as f: + with open(aws_credentials_file_path, encoding='utf-8') as f: try: data = json.load(f) except json.JSONDecodeError: