diff --git a/SAS/TMSS/backend/src/tmss/tmssapp/subtasks.py b/SAS/TMSS/backend/src/tmss/tmssapp/subtasks.py index 674eeb5d3276ee30b7ae003ac48e75db8f4faf88..fa1ee8088b4d910737e91f135366b2a9c505df6d 100644 --- a/SAS/TMSS/backend/src/tmss/tmssapp/subtasks.py +++ b/SAS/TMSS/backend/src/tmss/tmssapp/subtasks.py @@ -1774,7 +1774,7 @@ def schedule_ingest_subtask(ingest_subtask: Subtask): # not very relevant for ingest subtasks, but it's nice for the user to see when the ingest task was scheduled. # please note that an ingest subtask may idle for some time while it is in the ingest queue. # the actual start/stop times are set by the IngestTMSSAdapter when the subtask starts and stops. - ingest_subtask.scheduled_on_sky_start_time = max([pred.stop_time for pred in ingest_subtask.predecessors] + [datetime.utcnow()]) + ingest_subtask.scheduled_on_sky_start_time = max([pred.scheduled_on_sky_stop_time for pred in ingest_subtask.predecessors] + [datetime.utcnow()]) ingest_subtask.scheduled_on_sky_stop_time = ingest_subtask.scheduled_on_sky_start_time + timedelta(hours=6) # step 2: link input dataproducts @@ -1852,7 +1852,7 @@ def schedule_cleanup_subtask(cleanup_subtask: Subtask): # not very relevant for ingest subtasks, but it's nice for the user to see when the cleanup task was scheduled. # please note that an cleanup subtask may idle for some time while it is in the cleanup queue. # the actual start/stop times are set by the IngestTMSSAdapter when the subtask starts and stops. - cleanup_subtask.scheduled_on_sky_start_time = max([pred.stop_time for pred in cleanup_subtask.predecessors] + [datetime.utcnow()]) + cleanup_subtask.scheduled_on_sky_start_time = max([pred.scheduled_on_sky_stop_time for pred in cleanup_subtask.predecessors] + [datetime.utcnow()]) cleanup_subtask.scheduled_on_sky_stop_time = cleanup_subtask.scheduled_on_sky_start_time + timedelta(hours=1) # step 2: link input dataproducts