Skip to content

Commit 2a7dece

Browse files
committed
Bugfix in monthly dag for gap_events
1 parent 88af2ec commit 2a7dece

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

airflow/pipe_events_dag.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def source_date_range(self):
2424
return '{{ yesterday_ds }}', '{{ yesterday_ds }}'
2525
elif self.schedule_interval == '@monthly':
2626
start_date = '{{ (execution_date.replace(day=1) + macros.dateutil.relativedelta.relativedelta(days=-1)).strftime("%Y-%m-%d") }}'
27-
end_date = '{{ (execution_date.replace(day=1) + macros.dateutil.relativedelta.relativedelta(months=1, days=-2)).strftime("%Y%m%d") }}'
27+
end_date = '{{ (execution_date.replace(day=1) + macros.dateutil.relativedelta.relativedelta(months=1, days=-2)).strftime("%Y-%m-%d") }}'
2828
return start_date, end_date
2929
else:
3030
raise ValueError('Unsupported schedule interval {}'.format(self.schedule_interval))
@@ -39,7 +39,6 @@ def build(self, dag_id):
3939

4040
publish_events = BashOperator(
4141
task_id='publish_events',
42-
depends_on_past=True,
4342
bash_command='{docker_run} {docker_image} gap_events '
4443
'{date_range} '
4544
'{project_id}:{source_dataset}.{position_messages} '

0 commit comments

Comments
 (0)