diff --git a/md_pdf/csl.py b/md_pdf/csl.py index 42ab5e5..1d45830 100644 --- a/md_pdf/csl.py +++ b/md_pdf/csl.py @@ -26,7 +26,8 @@ def download_csl(): remove_dir(CSL_DIR) def download_handle(count, block_size, total_size): - print(count, block_size, total_size, int(count * block_size * 100 / total_size)) + if total_size < 1: # only update the bar if we have a size + return bar.update(int(count * block_size * 100 / total_size)) _, download_location = tempfile.mkstemp()