Skip to content

Conversation

@kaxil
Copy link
Member

@kaxil kaxil commented Jan 21, 2025

This PR re-uses the Context dict from the Task SDK in models/taskinstance.py.

Once, CeleryExecutor & KubernetesExecutor are ported over to Task SDK, we can remove all of this code. This PR unifies some of that code.

This also uncovered flawed logic where a Task/TI is in running state but DagRun is in Queued or None state!!!


^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in newsfragments.

@kaxil kaxil requested review from XD-DENG, ashb and potiuk as code owners January 21, 2025 14:51
@kaxil kaxil force-pushed the use-new-context branch 3 times, most recently from 0e774a5 to 4f9ace7 Compare January 21, 2025 19:21
@kaxil kaxil requested a review from uranusjr as a code owner January 21, 2025 19:21
@kaxil kaxil force-pushed the use-new-context branch 5 times, most recently from f6ac4a6 to 995924e Compare January 21, 2025 20:52
This PR ports re-uses the Context dict from the Task SDK in `models/taskinstance.py`.

Once, CeleryExecutor & KubernetesExecutor are ported over to Task SDK, we can remove all of this code. This PR unifies some of that code.
Copy link
Contributor

@amoghrajesh amoghrajesh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah changes look good. Can we add TODO in taskinstance.py for the parts that we want to undo once Celery / K8s executors are integrated?

@kaxil
Copy link
Member Author

kaxil commented Jan 22, 2025

Yeah changes look good. Can we add TODO in taskinstance.py for the parts that we want to undo once Celery / K8s executors are integrated?

Most of that file we get nuked :)

@kaxil kaxil merged commit 0e7c639 into apache:main Jan 22, 2025
46 checks passed
@kaxil kaxil deleted the use-new-context branch January 22, 2025 07:32
kaxil added a commit to astronomer/airflow that referenced this pull request Jan 22, 2025
kaxil added a commit to astronomer/airflow that referenced this pull request Jan 22, 2025
kaxil added a commit to astronomer/airflow that referenced this pull request Jan 22, 2025
kaxil added a commit to astronomer/airflow that referenced this pull request Jan 22, 2025
kaxil added a commit to astronomer/airflow that referenced this pull request Jan 22, 2025
dauinh pushed a commit to dauinh/airflow that referenced this pull request Jan 24, 2025
This PR ports re-uses the Context dict from the Task SDK in `models/taskinstance.py`.

Once, CeleryExecutor & KubernetesExecutor are ported over to Task SDK, we can remove all of this code. This PR unifies some of that code.
@utkarsharma2 utkarsharma2 added the type:new-feature Changelog: New Features label Jan 27, 2025
@utkarsharma2 utkarsharma2 added this to the Airflow 3.0.0 milestone Jan 27, 2025
gpathak128 pushed a commit to gpathak128/airflow that referenced this pull request Jan 29, 2025
This PR ports re-uses the Context dict from the Task SDK in `models/taskinstance.py`.

Once, CeleryExecutor & KubernetesExecutor are ported over to Task SDK, we can remove all of this code. This PR unifies some of that code.
got686-yandex pushed a commit to got686-yandex/airflow that referenced this pull request Jan 30, 2025
This PR ports re-uses the Context dict from the Task SDK in `models/taskinstance.py`.

Once, CeleryExecutor & KubernetesExecutor are ported over to Task SDK, we can remove all of this code. This PR unifies some of that code.
niklasr22 pushed a commit to niklasr22/airflow that referenced this pull request Feb 8, 2025
This PR ports re-uses the Context dict from the Task SDK in `models/taskinstance.py`.

Once, CeleryExecutor & KubernetesExecutor are ported over to Task SDK, we can remove all of this code. This PR unifies some of that code.
kosteev pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this pull request May 28, 2025
Some test failures like https://github.com/apache/airflow/actions/runs/12903540392/job/35979200770?pr=45865 were not caught in #45834

Follow-up of apache/airflow#45834

GitOrigin-RevId: 2193be2a5e53760ae00d1b85c825087e995f8eb1
kosteev pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this pull request Sep 23, 2025
Some test failures like https://github.com/apache/airflow/actions/runs/12903540392/job/35979200770?pr=45865 were not caught in #45834

Follow-up of apache/airflow#45834

GitOrigin-RevId: 2193be2a5e53760ae00d1b85c825087e995f8eb1
kosteev pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this pull request Oct 21, 2025
Some test failures like https://github.com/apache/airflow/actions/runs/12903540392/job/35979200770?pr=45865 were not caught in #45834

Follow-up of apache/airflow#45834

GitOrigin-RevId: 2193be2a5e53760ae00d1b85c825087e995f8eb1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants