melugoyal commented on code in PR #47126:
URL: https://github.com/apache/airflow/pull/47126#discussion_r1972487829


##########
airflow/api_fastapi/execution_api/routes/task_instances.py:
##########
@@ -151,14 +151,16 @@ def ti_run(
                 "previous_state": previous_state,
             },
         )
-    log.info("Task with %s state started on %s ", previous_state, 
ti_run_payload.hostname)
+    else:
+        log.info("Task with %s state started on %s ", previous_state, 
ti_run_payload.hostname)
     # Ensure there is no end date set.
     query = query.values(
         end_date=None,
         hostname=ti_run_payload.hostname,
         unixname=ti_run_payload.unixname,
         pid=ti_run_payload.pid,
-        state=State.RUNNING,
+        state=TaskInstanceState.RUNNING,
+        last_heartbeat_at=timezone.utcnow(),

Review Comment:
   yeah reasonable. i'll close the other PR in favor of this then



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to