ashb commented on code in PR #57952:
URL: https://github.com/apache/airflow/pull/57952#discussion_r2510483346


##########
task-sdk/src/airflow/sdk/definitions/dag.py:
##########
@@ -1389,13 +1437,13 @@ def _run_task(
             # it is run.
             ti.set_state(TaskInstanceState.QUEUED)
             task_sdk_ti = TaskInstanceSDK(
-                id=ti.id,
+                id=_to_uuid(ti.id, field_name="TaskInstance.id"),
                 task_id=ti.task_id,
                 dag_id=ti.dag_id,
                 run_id=ti.run_id,
                 try_number=ti.try_number,
                 map_index=ti.map_index,
-                dag_version_id=ti.dag_version_id,
+                dag_version_id=_require_uuid(ti.dag_version_id, 
field_name="TaskInstance.dag_version_id"),

Review Comment:
   Specifically here, we are talking about code that can only run once a TI has 
made it to a worker. In that case, will it always have a dag version or could 
it still be missing at that point?



-- 
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