From 8dc239764f86851e3e493d42b7370ee959ba9747 Mon Sep 17 00:00:00 2001 From: Jonathan Klabunde Tomer Date: Mon, 12 Feb 2024 16:02:55 -0800 Subject: [PATCH] fix: ignore `.com.google.Chrome.*` files in download dir seems these now get written during in-progress downloads, confusing scrape_lib's detection of the download being finished and resulting in truncated downloads. --- finance_dl/scrape_lib.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/finance_dl/scrape_lib.py b/finance_dl/scrape_lib.py index fa4ca58..cfb4e1d 100644 --- a/finance_dl/scrape_lib.py +++ b/finance_dl/scrape_lib.py @@ -195,7 +195,7 @@ def get_downloaded_file(self): partial_names = [] other_names = [] for name in names: - if name.endswith('.part') or name.endswith('.crdownload'): + if name.endswith('.part') or name.endswith('.crdownload') or name.startswith('.com.google.Chrome'): partial_names.append(name) else: other_names.append(name)