Don't check if the push_data.json file already exists, directly attempt redownloading if it was updated

This commit is contained in:
Marco Castelluccio 2020-01-11 15:31:01 +01:00
Родитель ab48d66ea5
Коммит 476d6b617e
1 изменённых файлов: 3 добавлений и 5 удалений

Просмотреть файл

@ -97,12 +97,10 @@ file = {{ driver = "file", path = "{os.path.abspath(cache_path)}" }}
zstd_compress("push_data.json")
def generate_test_scheduling_history(self):
if not os.path.exists("push_data.json"):
download_check_etag(PUSH_DATA_URL)
updated = download_check_etag(PUSH_DATA_URL)
if updated:
zstd_decompress("push_data.json")
assert os.path.exists(
"push_data.json"
), "Decompressed push data file exists"
assert os.path.exists("push_data.json"), "Decompressed push data file exists"
# Get the commits DB.
assert db.download(repository.COMMITS_DB)