Skip to content

Commit

Permalink
Search for transitfeeds files after cta files
Browse files Browse the repository at this point in the history
  • Loading branch information
dcjohnson24 committed Sep 27, 2023
1 parent ce6251a commit e8e5c7c
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions scrape_data/cta_data_downloads.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,19 +139,12 @@ def download_s3_file(fname: str) -> sga.GTFSFeed:
def compare_realtime_sched(
date_range: typing.List[str] = ['2022-05-20', today]) -> None:

_, found_list = find_s3_zipfiles(date_range=date_range)
schedule_list = csrt.create_schedule_list(month=5, year=2022)
schedule_list_filtered = [
s for s in schedule_list
if s['feed_start_date'] >= min(date_range)
and s['feed_start_date'] <= max(date_range)
]
# schedule_list_filtered = find_transitfeeds_zipfiles(zip_filename_list, found_list)
zip_filename_list, found_list = find_s3_zipfiles(date_range=date_range)
schedule_list_filtered = find_transitfeeds_zipfiles(zip_filename_list, found_list)
# Extract data from s3 zipfiles
s3_data_list = []
for fname in found_list:
data = download_s3_file(fname)

s3_data_list.append({'fname': fname, 'data': data})

# TODO Download the zipfiles from s3 instead of transitfeeds.
Expand Down

0 comments on commit e8e5c7c

Please sign in to comment.