You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "mobuchowski (via GitHub)" <gi...@apache.org> on 2023/08/12 09:09:01 UTC

[GitHub] [airflow] mobuchowski opened a new pull request, #33343: openlineage: defensively check for provided datetimes in listener

mobuchowski opened a new pull request, #33343:
URL: https://github.com/apache/airflow/pull/33343

   This fixes following bug:
   ```
   [2023-08-11, 18:27:35 UTC] {trigger_dagrun.py:209} INFO - Waiting for trigger_target_dag on 2023-08-11T18:23:35.355250+00:00 to become allowed state ['success'] ...
   [2023-08-11, 18:28:35 UTC] {trigger_dagrun.py:209} INFO - Waiting for trigger_target_dag on 2023-08-11T18:23:35.355250+00:00 to become allowed state ['success'] ...
   [2023-08-11, 18:29:35 UTC] {taskinstance.py:1943} ERROR - Task failed with exception
   Traceback (most recent call last):
     File "/usr/local/lib/python3.11/site-packages/airflow/operators/trigger_dagrun.py", line 220, in execute
       raise AirflowException(f"{self.trigger_dag_id} failed with failed states {state}")
   airflow.exceptions.AirflowException: trigger_target_dag failed with failed states failed
   [2023-08-11, 18:29:35 UTC] {utils.py:401} ERROR - 'NoneType' object has no attribute 'isoformat'
   Traceback (most recent call last):
     File "/usr/local/lib/python3.11/site-packages/airflow/providers/openlineage/utils/utils.py", line 399, in wrapper
       return f(*args, **kwargs)
              ^^^^^^^^^^^^^^^^^^
     File "/usr/local/lib/python3.11/site-packages/airflow/providers/openlineage/plugins/listener.py", line 145, in on_failure
       end_time=task_instance.end_date.isoformat(),
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   AttributeError: 'NoneType' object has no attribute 'isoformat'
   ```
   
   Additionally, add fallback for any similar situation, where it's getting datetime from Airflow object, checking if it's not null first.


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [airflow] mobuchowski merged pull request #33343: openlineage: defensively check for provided datetimes in listener

Posted by "mobuchowski (via GitHub)" <gi...@apache.org>.
mobuchowski merged PR #33343:
URL: https://github.com/apache/airflow/pull/33343


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org