dgvj-work opened a new pull request, #71459:
URL: https://github.com/apache/airflow/pull/71459

   Fix `DagRun.dag_versions` silently dropping older versions still in use 
after a partial `run_on_latest_version` clear.
   
   For bundle-versioned runs the property previously returned only 
`created_dag_version`. Clearing a subset with `run_on_latest_version=True` 
bumps that pointer to latest while uncleared TaskInstances keep their older 
`dag_version_id`, so the Grid UI could show a single version chip while tasks 
were still executing under mixed versions.
   
   This change always derives versions from the run's TaskInstance / 
TaskInstanceHistory rows (same path as unpinned runs).
   
   closes: #71454
   
   ## Testing
   
   - `uv run --project airflow-core pytest 
airflow-core/tests/unit/models/test_dagrun.py::TestDagRun::test_dag_run_dag_versions_method
 
airflow-core/tests/unit/models/test_dagrun.py::TestDagRun::test_dag_run_dag_versions_with_null_created_dag_version
 
airflow-core/tests/unit/models/test_dagrun.py::TestDagRun::test_dag_run_dag_versions_after_partial_run_on_latest_version
 
airflow-core/tests/unit/models/test_dagrun.py::TestDagRun::test_dag_run_version_number
 -q`
   
   ---
   
   ##### Was generative AI tooling used to co-author this PR?
   
   - [ ] Yes (please specify the tool below)
   
   ---
   
   * Read the **[Pull Request 
Guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#pull-request-guidelines)**
 for more information.
   
   Made with [Cursor](https://cursor.com)


-- 
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]

Reply via email to