From 3cdd7ee96f39b347179f729295d8d5c69f140d69 Mon Sep 17 00:00:00 2001 From: chrischin478 <47199426+chrischin478@users.noreply.github.com> Date: Fri, 15 Mar 2024 10:34:53 -0400 Subject: [PATCH] fix: Use dbt-core md5 to inheret FIPS compatibility (#604) Co-authored-by: chrischin <> --- dbt/adapters/athena/connections.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dbt/adapters/athena/connections.py b/dbt/adapters/athena/connections.py index a39ba345..e896c452 100644 --- a/dbt/adapters/athena/connections.py +++ b/dbt/adapters/athena/connections.py @@ -1,4 +1,3 @@ -import hashlib import json import re import time @@ -35,6 +34,7 @@ from dbt.adapters.sql import SQLConnectionManager from dbt.contracts.connection import AdapterResponse, Connection, ConnectionState from dbt.exceptions import ConnectionError, DbtRuntimeError +from dbt.utils import md5 @dataclass @@ -72,7 +72,7 @@ def type(self) -> str: @property def unique_field(self) -> str: - return f"athena-{hashlib.md5(self.s3_staging_dir.encode()).hexdigest()}" + return f"athena-{md5(self.s3_staging_dir)}" @property def effective_num_retries(self) -> int: