我使用airflow-cli airflow backfill -s 2016-04-01 -e 2016-05-01 -I -m test_backfill
来回填我的笨蛋但状态卡在队列中永远不会运行,除非我点击Run on task ui。
我的default_args有问题吗?
default_args = {
'owner': 'airflow',
'depends_on_past': False,
'start_date': datetime(2018, 5, 1),
'retries': 1,
'retry_delay': timedelta(minutes=5),
'catchup_by_default': False
}
dag = DAG(
'test_backfill',
default_args=default_args,
schedule_interval='0 5 1 * *',
dagrun_timeout=timedelta(hours=2)
)
def print_execution_date(**context):
print(context.get('execution_date'))
print(context.get('next_execution_date'))
t1 = PythonOperator(
task_id='print_date',
provide_context=True,
python_callable=print_execution_date,
dag=dag
)
以下是日志
[2018-06-01 15:33:50,761] {{models.py:1197}} INFO - Dependencies all met for <TaskInstance: test_backfill.print_date 2016-04-01 05:00:00 [scheduled]>
[2018-06-01 15:33:50,778] {{base_executor.py:49}} INFO - Adding to queue: airflow run test_backfill print_date 2016-04-01T05:00:00 --mark_success --pickle 17 --local
[2018-06-01 15:33:55,649] {{celery_executor.py:74}} INFO - [celery] queuing ('test_backfill', 'print_date', datetime.datetime(2016, 4, 1, 5, 0)) through celery, queue=default
[2018-06-01 15:33:55,751] {{models.py:4584}} INFO - Updating state for <DagRun test_backfill @ 2016-04-01 05:00:00: backfill_2016-04-01T05:00:00, externally triggered: False> considering 1 task(s)
[2018-06-01 15:33:55,771] {{jobs.py:2125}} INFO - [backfill progress] | finished run 0 of 1 | tasks waiting: 0 | succeeded: 0 | kicked_off: 1 | failed: 0 | skipped: 0 | deadlocked: 0 | not ready: 0
[2018-06-01 15:34:00,666] {{jobs.py:2011}} ERROR - Executor reports task instance <TaskInstance: test_backfill.print_date 2016-04-01 05:00:00 [queued]> finished (failed) although the task says its queued. Was the task killed externally?
[2018-06-01 15:34:00,666] {{models.py:1595}} ERROR - Executor reports task instance <TaskInstance: test_backfill.print_date 2016-04-01 05:00:00 [queued]> finished (failed) although the task says its queued. Was the task killed externally?
NoneType: None
[2018-06-01 15:34:00,667] {{models.py:1616}} INFO - Marking task as UP_FOR_RETRY
[2018-06-01 15:34:00,683] {{models.py:1644}} ERROR - Executor reports task instance <TaskInstance: test_backfill.print_date 2016-04-01 05:00:00 [queued]> finished (failed) although the task says its queued. Was the task killed externally?