Skip to content

Commit

Permalink
Change filenames to help distinguish full data from chunks
Browse files Browse the repository at this point in the history
  • Loading branch information
woctezuma committed Sep 19, 2021
1 parent 1c1692b commit 97f1f99
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions query_geforce_backup.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,17 @@ def main():
data = fetch_all_pages(
is_slim_query=True, use_original_endpoint=use_gfn_endpoint, app_ids=app_ids
)
save_to_disk(data, f"data/backup_slim_{chunk_no}.json", verbose=True)
save_to_disk(data, f"data/backup_slim_chunk_{chunk_no}.json", verbose=True)

data = fetch_all_pages(
is_slim_query=False, use_original_endpoint=use_gfn_endpoint, app_ids=app_ids
)
save_to_disk(data, f"data/backup_full_{chunk_no}.json", verbose=True)
save_to_disk(data, f"data/backup_full_chunk_{chunk_no}.json", verbose=True)

# Export to disk
for keyword in ["slim", "full"]:
data = list()
for fname in glob.glob(f"data/backup_{keyword}_*.json"):
for fname in glob.glob(f"data/backup_{keyword}_chunk_*.json"):
data += load_from_disk(fname)
save_to_disk(data, f"backup_{keyword}.json", verbose=True)

Expand Down

0 comments on commit 97f1f99

Please sign in to comment.