ephraimbuddy opened a new pull request, #22941:
URL: https://github.com/apache/airflow/pull/22941
This opens up the possibility of using one decorated task
in different dag files.
Take for example the below task:
- common.py
```python
@task(task_id='hello')
def hello():
print('Hello')
```
defined in a file and called in different dag files using different task ids:
- dag_file1.py:
```python
from common import hello
@dag
def mydag():
for i in range(3):
hello(task_id=f'myhellotask_{i}')
```
- dag_file2.py:
```python
from common import hello
@dag():
def mydag2():
for i in range(3):
hello(task_id=f'welcome_message_{i}')
```
They would all run with different task ids
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]