You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2022/03/22 19:22:02 UTC

[GitHub] [airflow] ybressler commented on issue #18116: Methods `TaskInstance.get_previous_execution_date()` & `TaskInstance.get_previous_ti()` are lying !

ybressler commented on issue #18116:
URL: https://github.com/apache/airflow/issues/18116#issuecomment-1075539765


   I'm experiencing this issue too.
   
   Could we not design this method to query the relational DB via the ORM directly?
   
   Ex:
   ```
   get_previous_ti(state):
       return TaskInstance.filter(state=state, task_id=self.task_id).order_by(date).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