insomnes commented on issue #46665: URL: https://github.com/apache/airflow/issues/46665#issuecomment-2656087236
I think it is part of AIP-72 https://github.com/orgs/apache/projects/405 I got the overall idea of the current XCOM pulling state and how the mechanism of multiple map_indexes requests can be implemented. A direct approach can be very inefficient cause it would lead to task_ids * map_indexes requests to the API. But it is the only supported request variant for map_indexes, we either can request a single map_index, or all of them. There is also drift in desired behavior from docs and functions arguments: ``` map_indexes: int | Iterable[int] | None | ArgNotSet = NOTSET, ... When pulling one single task (``task_id`` is *None* or a str) without specifying ``map_indexes``, the return value is inferred from whether the specified task is mapped. If not, value from the one single task instance is returned. If the task to pull is mapped, an iterator (not a list) yielding XComs from mapped task instances is returned. In either case, ``default`` (*None* if not specified) is returned if no matching XComs are found. When pulling multiple tasks (i.e. either ``task_id`` or ``map_index`` is a non-str iterable), a list of matching XComs is returned. Elements in the list is ordered by item ordering in ``task_id`` and ``map_index``. ``` And the API handler itself distinguishes between None map_index and -1. With whom can I discuss or where can I read about the desired behavior? -- 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]
