Skip to content
Snippets Groups Projects
Commit 13d416d5 authored by Alan De Smet's avatar Alan De Smet
Browse files

FileSet description omit time if daily

If a dataset has a period longer than a day, omit the timestamp from the
automatically generated description. Makes logs a bit briefer.
parent 87286d97
No related branches found
No related tags found
No related merge requests found
......@@ -658,8 +658,12 @@ class Downloader:
expected = self.is_expected(time)
fmt_time = time.strftime("%Y-%m-%d")
if self.period < timedelta(days=1):
fmt_time += time.strftime("%H:%M:%S")
priority_desc = f'"{priority}"' if priority != "" else '"" (empty string)'
description = f"{self.name} for {time} at priority {priority_desc}"
description = f"{self.name} for {fmt_time} at priority {priority_desc}"
fs = FileSet(urls_to_files, expected, description)
filesets.append(fs)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment