From fb02166ffa6465b104cdca3544ef75f6fbcd5eeb Mon Sep 17 00:00:00 2001 From: duong tam kien Date: Thu, 7 Nov 2024 23:54:11 +0100 Subject: [PATCH] t --- scripts/import_wf_offload.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/scripts/import_wf_offload.py b/scripts/import_wf_offload.py index ed9a166..256b79a 100644 --- a/scripts/import_wf_offload.py +++ b/scripts/import_wf_offload.py @@ -66,7 +66,11 @@ def write_posts(posts): ) print(filename) - print(p['created']) + print(p['created'][:19]+"Z") + print(datetime.datetime.fromisoformat(p['created'][:19]+"Z")) + print(datetime.datetime.fromisoformat(p['created'][:19]+"Z").strftime('%s')) + print(datetime.datetime.fromisoformat(p['created'][:19]+"Z").astimezone(tz)) + print(datetime.datetime.fromisoformat(p['created'][:19]+"Z").astimezone(tz).strftime('%s')) print(post['title']) print(post['source'])