question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Update TaskFlow API example to use `@dag` decorator

See original GitHub issue

Description

Update https://github.com/apache/airflow/blob/master/airflow/example_dags/tutorial_taskflow_api_etl.py tp use @dag decorator instead of leveraging context manager to make it more TaskFlow-y.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:9 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
casassgcommented, Nov 11, 2020

@kaxil I would encourage all TaskFlow tutorials to be using @dag better? We can leave some w context manager so people undertstand it’s usable in both ways. But I was indeed refering to tutorial_taskflow_api_etl as @eflann mentions

0reactions
casassgcommented, Dec 8, 2020

This is documentation update. I would think it can be even done after release of 2.0 (aka 2.0.1?)

Read more comments on GitHub >

github_iconTop Results From Across the Web

Working with TaskFlow — Airflow Documentation
Here is a very simple pipeline using the TaskFlow API paradigm. ... import json import pendulum from airflow.decorators import dag, task @dag( schedule=None ......
Read more >
Introduction to Airflow decorators | Astronomer Documentation
Airflow decorators were introduced as part of the TaskFlow API, which also handles passing data between tasks using XCom and inferring task dependencies ......
Read more >
TaskFlow API in Airflow 2.0 - YouTube
Airflow 2.0 brought with it many great new features, one of which is the TaskFlow API. The TaskFlow API makes DAGs easier to...
Read more >
Writing Functional DAGs with Decorators - YouTube
Decorators, originally introduced as part of the TaskFlow API, provide an easy way of turning your functions into Airflow tasks.
Read more >
A simple DAG using Airflow 2.0 - Pedro Madruga
Airflow 2.x is a game-changer, especially regarding its simplified syntax using the new Taskflow API. In this tutorial, we're building a DAG ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found