diff --git a/ingestor/chalicelib/agg_speed_tables.py b/ingestor/chalicelib/agg_speed_tables.py index 03f8a78..388d78e 100644 --- a/ingestor/chalicelib/agg_speed_tables.py +++ b/ingestor/chalicelib/agg_speed_tables.py @@ -33,14 +33,14 @@ class TripsByLineParams: agg: Range -def populate_table(line: Line, range: Range): +def populate_table(line: Line, range: Range, start_date: str = "2016-01-01"): """Populate weekly or monthly aggregate speed table for a given line. Ran manually as a lambda in AWS console""" print(f"Populating {range} table") table = constants.TABLE_MAP[range] today = datetime.now().strftime(constants.DATE_FORMAT_BACKEND) trips = actual_trips_by_line( { - "start_date": "2016-01-01", + "start_date": start_date, "end_date": today, "line": line, "agg": range, diff --git a/ingestor/chalicelib/trip_metrics/backfill.py b/ingestor/chalicelib/trip_metrics/backfill.py index 7c5ae37..b3b5176 100644 --- a/ingestor/chalicelib/trip_metrics/backfill.py +++ b/ingestor/chalicelib/trip_metrics/backfill.py @@ -3,8 +3,8 @@ from .ingest import ingest_trip_metrics, get_date_ranges -START_DATE = date(2024, 3, 1) -END_DATE = date(2024, 5, 14) +START_DATE = date(2024, 5, 1) +END_DATE = date(2024, 7, 31) MAX_RANGE_SIZE = 90 if __name__ == "__main__":