From 28d7416bc3c7526a9bc99adc0f6a048c6d15759a Mon Sep 17 00:00:00 2001 From: Abdel Jaidi Date: Wed, 1 May 2024 10:17:03 +0100 Subject: [PATCH] fix: correct TypeError message --- awswrangler/_sql_formatter.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/awswrangler/_sql_formatter.py b/awswrangler/_sql_formatter.py index 855b59386..e38b9df96 100644 --- a/awswrangler/_sql_formatter.py +++ b/awswrangler/_sql_formatter.py @@ -40,7 +40,7 @@ def format_decimal(self, value: decimal.Decimal) -> str: def format_timestamp(self, value: datetime.datetime) -> str: if value.tzinfo is not None: - raise TypeError(f"Supports only timezone aware datatype, got {value}.") + raise TypeError(f"Supports only timezone naive datatype, got {value}.") return f"TIMESTAMP '{value.isoformat(sep=' ', timespec='milliseconds')}'" @@ -132,7 +132,7 @@ def format_decimal(self, value: decimal.Decimal) -> str: def format_timestamp(self, value: datetime.datetime) -> str: if value.tzinfo is not None: - raise TypeError(f"Supports only timezone aware datatype, got {value}.") + raise TypeError(f"Supports only timezone naive datatype, got {value}.") return f"'{value.isoformat()}'"