uranusjr commented on code in PR #75184:
URL: https://github.com/apache/airflow/pull/75184#discussion_r4397346704
##########
task-sdk/src/airflow/sdk/bases/xcom.py:
##########
@@ -853,11 +877,20 @@ def _find_own_coordinate(dag_id: str, run_id: str,
task_id: str, map_index: int)
owner = running
else:
return None
- if (owner.dag_id, owner.run_id, owner.task_id, _public_map_index(owner))
== (
- dag_id,
- run_id,
- task_id,
- map_index,
- ):
- return _own_coordinate(owner)
+ if is_own_xcom(owner, dag_id, run_id, task_id, map_index):
+ return build_own_coordinate(owner)
return None
+
+
+def is_stored_through_backend(key: str) -> bool:
Review Comment:
This also changes Python tasks. Is it intended?
The prefix check is also a heuristic. Many provider links override xcom_key,
so they aren’t covered, and a user key that happens to start with `_link_` gets
moved into the DB. Could the link declare this itself, e.g. by having
`BaseOperatorLink.persist` write past the backend, instead of us guessing from
the key?
--
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]