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/08/08 07:58:02 UTC
[GitHub] [airflow] potiuk commented on pull request #22658: Fix incorrect data_interval_start due to scheduling time change
potiuk commented on PR #22658:
URL: https://github.com/apache/airflow/pull/22658#issuecomment-1207792295
I think what woudl be great here is to add a few more tests showing the different cases and maybe explaining the context in the test a bit better?
The case here is either not tested or it's not clear that it is tested I think:
```
def _align_to_prev(self, current: DateTime) -> DateTime:
"""Get the prev scheduled time.
This is ``current - interval``, unless ``current`` falls right on the
interval boundary, when ``current`` is returned.
"""
prev_time = self._get_prev(current)
if self._get_next(prev_time) != current:
return prev_time
return current
```
--
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