Skip to content
Snippets Groups Projects
Commit d4d81ab3 authored by Alois Klink's avatar Alois Klink
Browse files

Improve progress bar printing

Fixes typos and new line bugs
parent 4d38c5bf
No related branches found
No related tags found
No related merge requests found
...@@ -260,7 +260,7 @@ def make_csv(location: Locations, ...@@ -260,7 +260,7 @@ def make_csv(location: Locations,
output_loc = output_dir / output_filename output_loc = output_dir / output_filename
combine_csvs(file_name_list, output_loc) combine_csvs(file_name_list, output_loc)
print(f"Made a CSV of {location} from date " tqdm.tqdm.write(f"Made a CSV of {location} from date "
f"{from_time.date()} to {to_time.date()} at {output_loc}") f"{from_time.date()} to {to_time.date()} at {output_loc}")
def download_all(): def download_all():
...@@ -281,7 +281,7 @@ def main(args): ...@@ -281,7 +281,7 @@ def main(args):
pbar = tqdm.tqdm(Locations, desc=("Iterating over " pbar = tqdm.tqdm(Locations, desc=("Iterating over "
f"{[x.value for x in Locations]}")) f"{[x.value for x in Locations]}"))
for loc in pbar: for loc in pbar:
pbar.set_description(f"Donwloading {loc.value} data.") pbar.set_description(f"Downloading {loc.value} data.")
make_csv(loc, **kwargs) make_csv(loc, **kwargs)
if __name__ == "__main__": if __name__ == "__main__":
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment