Skip to content
Snippets Groups Projects
Commit b4590056 authored by Christophe Benz's avatar Christophe Benz
Browse files

Use isoformat for datetimes

parent 909ceba3
No related branches found
No related tags found
No related merge requests found
......@@ -92,7 +92,7 @@ def main():
else:
log.info(
"Argument --from-datetime=%r: only datasets that changed since that datetime will be downloaded",
args.from_datetime,
args.from_datetime.isoformat(),
)
toc_file_name = "table_of_contents.xml"
......@@ -224,7 +224,9 @@ def iter_datasets_to_download(toc_element, from_datetime: Optional[datetime] = N
last_update = datetime.strptime(last_update_str, "%d.%m.%Y").replace(tzinfo=timezone.utc)
if last_update >= from_datetime:
log.debug(
"Dataset %r lastUpdate is more recent than %r: it will be downloaded", dataset_code, from_datetime
"Dataset %r lastUpdate is more recent than %r: it will be downloaded",
dataset_code,
from_datetime.isoformat(),
)
yield leaf_element
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment