From dca4505b7354f689d33ce2cf0d31e9e9ad4c364c Mon Sep 17 00:00:00 2001 From: Jonathan Klabunde Tomer Date: Tue, 16 Apr 2024 20:23:06 -0700 Subject: [PATCH] fix: ignore `.com.google.Chrome.*` files in download dir (#96) 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)