From f230ed7298ca9b45da4fe4ab075970876989daf7 Mon Sep 17 00:00:00 2001 From: Hans Ginzel Date: Mon, 22 Apr 2024 15:36:01 +0200 Subject: [PATCH] q.py: Use timezone-aware objects to represent datetimes in UTC q.py:1624: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). now = datetime.datetime.utcnow().isoformat() Python 3,12 --- bin/q.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/q.py b/bin/q.py index 2a2f6771..57e11023 100755 --- a/bin/q.py +++ b/bin/q.py @@ -1663,7 +1663,7 @@ def __analyze_delimited_file(self,database_info): xprint("after perform_analyze") self.content_signature = table_creator._generate_content_signature() - now = datetime.datetime.utcnow().isoformat() + now = datetime.datetime.now(datetime.UTC) database_info.sqlite_db.add_to_qcatalog_table(target_sqlite_table_name, self.content_signature,