-
Notifications
You must be signed in to change notification settings - Fork 16.3k
Labels
affected_version:3.0Issues Reported for 3.0Issues Reported for 3.0area:corearea:dynamic-task-mappingAIP-42AIP-42kind:bugThis is a clearly a bugThis is a clearly a bugpriority:mediumBug that should be fixed before next release but would not block a releaseBug that should be fixed before next release but would not block a release
Milestone
Description
Apache Airflow version
3.0.4
If "Other Airflow 2 version" selected, which one?
No response
What happened?
Cannot restart a single mapped task. It always restarts all sibling mapped tasks as well. I found this old issue #24699 so I thought it should be working, but doesn't for me. We have multiple issues here:
- When clearing the individual task it shows all siblings in the "Downstream" selection.
- It re-runs all sibling tasks. Cannot tell for certain this isn't just a UI bug in this simple example. But in my real-world use case, where Airflow triggers Google Cloud Run Jobs, it does spawn n Cloud Run Jobs upon restart.
- It also re-runs all downstream tasks for all map indices.
- For previous task executions, upon UI reload, I only get "::group::Log message source details: sources=["Could not read served logs: 'TaskInstanceHistory' object has no attribute 'triggerer_job'"]" and not the actual logs.
Or am I misunderstanding this feature?
What you think should happen instead?
Only the selected mapped task should be restarted.
The logs should properly show up in the UI for previous task tries.
Only downstream tasks with the same map index should be re-run (not sure this is easily possible or intended, but without it I don't see how restarting individual tasks would be of much use).
How to reproduce
@task
def task1(val: str):
print("Task 2" + val)
@task
def task2(val: str):
print("Task 2" + val)
@dag(dag_id="test")
def get_dag() -> None:
t1 = task1.expand(val=["foo", "bar"])
t2 = task2.expand(val=["foo", "bar"])
t1 >> t2
get_dag()
Run once. Then re-run an individual task of task1.
Operating System
Debian GNU/Linux 12 (bookworm)
Versions of Apache Airflow Providers
No response
Deployment
Official Apache Airflow Helm Chart
Deployment details
No response
Anything else?
No response
Are you willing to submit PR?
- Yes I am willing to submit a PR!
Code of Conduct
- I agree to follow this project's Code of Conduct
matthieuauger, quassy and mattusifer
Metadata
Metadata
Assignees
Labels
affected_version:3.0Issues Reported for 3.0Issues Reported for 3.0area:corearea:dynamic-task-mappingAIP-42AIP-42kind:bugThis is a clearly a bugThis is a clearly a bugpriority:mediumBug that should be fixed before next release but would not block a releaseBug that should be fixed before next release but would not block a release