hussein-awala commented on issue #31677:
URL: https://github.com/apache/airflow/issues/31677#issuecomment-1573490372

   This is not a bug. It is not possible to unpack an Xcom in parsing time 
because it does not exist at that moment. Xcom is created at runtime after the 
first task is executed:
   ```python
   from datetime import datetime
   
   from airflow.decorators import dag, task
   
   @dag(schedule=None, start_date=datetime(2023, 1, 1), catchup=False)
   def testdag():
   
       @task()
       def test():
           return 'x', 'y'
   
       @task()
       def process_x(values):
           x = values[0]
           print(x)
   
       @task()
       def process_y(values):
           y = values[1]
           print(y)
   
       returned_values = test()
       process_x(returned_values)
       process_y(returned_values)
   
   testdag()
   ```


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