Skip to content

Commit

Permalink
Introduce work_group_enforced
Browse files Browse the repository at this point in the history
  • Loading branch information
amacal committed Sep 5, 2024
1 parent 840e847 commit 9ddb520
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion dbt/adapters/athena/impl.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ class AthenaConfig(AdapterConfig):
Args:
work_group: Identifier of Athena workgroup.
work_group_enforced: Assummed value of the WorkGroup location enforcement.
s3_staging_dir: S3 location to store Athena query results and metadata.
external_location: If set, the full S3 path in which the table will be saved.
partitioned_by: An array list of columns by which the table will be partitioned.
Expand All @@ -102,6 +103,7 @@ class AthenaConfig(AdapterConfig):
"""

work_group: Optional[str] = None
work_group_enforced: Optional[bool] = None
s3_staging_dir: Optional[str] = None
external_location: Optional[str] = None
partitioned_by: Optional[str] = None
Expand Down Expand Up @@ -240,7 +242,7 @@ def is_work_group_output_location_enforced(self) -> bool:
conn = self.connections.get_thread_connection()
creds = conn.credentials

if creds.work_group:
if creds.work_group and creds.work_group_enforced is None:
work_group = self._get_work_group(creds.work_group)
output_location = (
work_group.get("WorkGroup", {})
Expand Down

0 comments on commit 9ddb520

Please sign in to comment.