You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "rino0601 (via GitHub)" <gi...@apache.org> on 2026/08/10 14:22:07 UTC
[PR] API: Return asset events for Dag Runs without a start date [airflow]
rino0601 opened a new pull request, #71379:
URL: https://github.com/apache/airflow/pull/71379
Return asset events even when a created Dag Run has not started.
Asset-event responses serialize linked Dag Runs through API models that treated `start_date` as required, although queued and cleared Dag Runs may have a NULL value. Align the Core API and Execution API contracts with their generated UI, Task SDK, and AirflowCTL clients.
Add regression coverage for Core `/assets/events`, upstream asset events, the Execution API, and client response parsing.
closes: #71360
Tests:
- `breeze --python 3.10 --backend postgres run pytest airflow-core/tests/unit/api_fastapi/core_api/routes/public/test_assets.py -q`
- `breeze --python 3.10 --backend postgres run pytest airflow-core/tests/unit/api_fastapi/core_api/routes/public/test_dag_run.py airflow-core/tests/unit/api_fastapi/execution_api/versions/head/test_asset_events.py -q`
- `breeze run --python 3.10 --backend sqlite pytest task-sdk/tests/task_sdk/api/test_client.py -q`
- `breeze --python 3.10 --backend sqlite run pytest airflow-ctl/tests/airflow_ctl/api/test_operations.py::TestAssetsOperations::test_create_event -q`
- `prek run --from-ref main --stage pre-commit --skip generate-openapi-spec --skip generate-tasksdk-datamodels --skip generate-airflowctl-datamodels`
---
##### Was generative AI tooling used to co-author this PR?
- [X] Yes — Codex (GPT-5)
Generated-by: Codex (GPT-5) following [the guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions)
---
Drafted-by: Codex (GPT-5) (no human review before posting)
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] API: Return asset events for Dag Runs without a start date [airflow]
Posted by "bbovenzi (via GitHub)" <gi...@apache.org>.
bbovenzi merged PR #71379:
URL: https://github.com/apache/airflow/pull/71379
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] API: Return asset events for Dag Runs without a start date [airflow]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #71379:
URL: https://github.com/apache/airflow/pull/71379#issuecomment-5332466020
### Backport failed to create: airflow-ctl/v0-1-test. View the failure log <a href='https://github.com/apache/airflow/actions/runs/32171665871'> Run details </a>
Note: As of [Merging PRs targeted for Airflow 3.X](https://github.com/apache/airflow/blob/main/dev/README_AIRFLOW3_DEV.md#merging-prs-targeted-for-airflow-3x)
the committer who merges the PR is responsible for backporting the PRs that are bug fixes (generally speaking) to the maintenance branches.
In matter of doubt please ask in [#release-management](https://apache-airflow.slack.com/archives/C03G9H97MM2) Slack channel.
<table>
<tr>
<th>Status</th>
<th>Branch</th>
<th>Result</th>
</tr>
<tr>
<td>❌</td>
<td>airflow-ctl/v0-1-test</td>
<td><a href="https://github.com/apache/airflow/commit/3dcdcb8002fb4babbaa161950d038480f9fcf97e"><img src='https://img.shields.io/badge/Commit-3dcdcb8-red' alt='Commit Link'></a></td>
</tr>
</table>
You can attempt to backport this manually by running:
```bash
cherry_picker 3dcdcb8 airflow-ctl/v0-1-test
```
This should apply the commit to the airflow-ctl/v0-1-test branch and leave the commit in conflict state marking
the files that need manual conflict resolution.
After you have resolved the conflicts, you can continue the backport process by running:
```bash
cherry_picker --continue
```
If you don't have cherry-picker installed, see the [installation guide](https://github.com/apache/airflow/blob/main/dev/README.md#how-to-backport-pr-with-cherry-picker-cli).
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] API: Return asset events for Dag Runs without a start date [airflow]
Posted by "rino0601 (via GitHub)" <gi...@apache.org>.
rino0601 commented on PR #71379:
URL: https://github.com/apache/airflow/pull/71379#issuecomment-5241781485
Hello, maintainers. Thank you, as always, for the project.
I saw that PR #71361 had been created for the issue I reported, but it felt like something was missing. So I checked out the project myself and gave it a try, taking care to follow the generative AI contribution guidelines.
Reading English is easy for me, but writing it is not, so I got some help from AI.
The changes allow `null` for the problematic part, and I also found all the parts with the same meaning and made them allow `null` as well. I passed all the static checks in the Breeze environment.
I wondered whether this might conflict with the original intent, so I used `git blame` on the places containing `start_date` and compared them with the intent of the previous PRs. At least, I found no intention in those PRs to make it required. That is why I opened this PR.
I live in the Asia/Seoul (+09:00) time zone, and I can contribute to open source every day between 22:00 and 00:00 in my local time. If I missed anything or if you need any help, please feel free to let me know :D
---
Drafted-by: Codex (GPT-5) (no human review before posting)
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] API: Return asset events for Dag Runs without a start date [airflow]
Posted by "bbovenzi (via GitHub)" <gi...@apache.org>.
bbovenzi commented on code in PR #71379:
URL: https://github.com/apache/airflow/pull/71379#discussion_r3761448369
##########
uv.lock:
##########
Review Comment:
Let's undo this change
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] API: Return asset events for Dag Runs without a start date [airflow]
Posted by "rino0601 (via GitHub)" <gi...@apache.org>.
rino0601 commented on code in PR #71379:
URL: https://github.com/apache/airflow/pull/71379#discussion_r3766723743
##########
uv.lock:
##########
Review Comment:
Thanks. I traced the `uv.lock` diff before reverting it: it is not an intentional part of the API change.
This PR triggers both [`generate-tasksdk-datamodels`](https://github.com/apache/airflow/blob/main/.pre-commit-config.yaml#L1399-L1404) and [`generate-airflowctl-datamodels`](https://github.com/apache/airflow/blob/main/.pre-commit-config.yaml#L1406-L1418). After rebasing onto the latest `main`, I ran each hook independently with the CI's `uv 0.11.29`; each reproduces the exact same `uv.lock` metadata and ordering diff.
Both hooks invoke `uv run` with a `--project` value that is not a project directory, while also supplying the correct `--directory`. uv 0.11.29 warns and continues, but uv 0.12 treats this as an error. I documented that compatibility problem in #71377.
To remove this `uv.lock` diff from the API-change commits, I would need to bypass or modify the relevant pre-commit hooks; otherwise, they recreate it deterministically. I do not think bypassing the hooks is the intended resolution here, so I have not pushed the local rebase/revert yet to avoid another CI run before confirming the preferred direction.
Would you prefer that I fix the hook behavior in this PR, or keep the lockfile revert here and address the hooks separately in #71377?
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] API: Return asset events for Dag Runs without a start date [airflow]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #71379:
URL: https://github.com/apache/airflow/pull/71379#issuecomment-5332455454
### Backport failed to create: v3-3-test. View the failure log <a href='https://github.com/apache/airflow/actions/runs/32171665871'> Run details </a>
Note: As of [Merging PRs targeted for Airflow 3.X](https://github.com/apache/airflow/blob/main/dev/README_AIRFLOW3_DEV.md#merging-prs-targeted-for-airflow-3x)
the committer who merges the PR is responsible for backporting the PRs that are bug fixes (generally speaking) to the maintenance branches.
In matter of doubt please ask in [#release-management](https://apache-airflow.slack.com/archives/C03G9H97MM2) Slack channel.
<table>
<tr>
<th>Status</th>
<th>Branch</th>
<th>Result</th>
</tr>
<tr>
<td>❌</td>
<td>v3-3-test</td>
<td><a href="https://github.com/apache/airflow/commit/3dcdcb8002fb4babbaa161950d038480f9fcf97e"><img src='https://img.shields.io/badge/Commit-3dcdcb8-red' alt='Commit Link'></a></td>
</tr>
</table>
You can attempt to backport this manually by running:
```bash
cherry_picker 3dcdcb8 v3-3-test
```
This should apply the commit to the v3-3-test branch and leave the commit in conflict state marking
the files that need manual conflict resolution.
After you have resolved the conflicts, you can continue the backport process by running:
```bash
cherry_picker --continue
```
If you don't have cherry-picker installed, see the [installation guide](https://github.com/apache/airflow/blob/main/dev/README.md#how-to-backport-pr-with-cherry-picker-cli).
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] API: Return asset events for Dag Runs without a start date [airflow]
Posted by "rino0601 (via GitHub)" <gi...@apache.org>.
rino0601 commented on code in PR #71379:
URL: https://github.com/apache/airflow/pull/71379#discussion_r3766723743
##########
uv.lock:
##########
Review Comment:
Thanks.
I traced the `uv.lock` diff before removing it: it is not an intentional part of the API change. It is reproduced by [the `generate-tasksdk-datamodels` hook](https://github.com/apache/airflow/blob/main/.pre-commit-config.yaml#L1399-L1404), which is triggered by changes under `airflow-core/src/airflow/api_fastapi/execution_api/`.
After rebasing onto the latest `main`, running that hook with the CI's `uv 0.11.29` reproduces the exact same `uv.lock` metadata and ordering diff. The hook invokes:
`uv run ... --project apache-airflow-task-sdk --directory task-sdk ...`
uv 0.11.29 warns that the `--project` directory does not exist but continues. uv 0.12 treats this as an error; I documented that separate compatibility issue in #71377.
Removing the lockfile diff from the source-changing commit would require skipping or changing this hook, since it deterministically recreates the diff. A separate revert commit is possible without `--no-verify`, but I have not pushed it yet to avoid another CI run before confirming the preferred resolution.
Would you prefer that we fix this hook in this PR, or handle the hook/lockfile behavior in a separate PR?
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] API: Return asset events for Dag Runs without a start date [airflow]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #71379:
URL: https://github.com/apache/airflow/pull/71379#issuecomment-5280219684
<!-- uv-lock-rebase-notice -->
`uv.lock` on `main` just moved via commit [`1e1dc10`](https://redirect.github.com/apache/airflow/commit/1e1dc10734d6f01ead1b1d16e7df2e3ac3f156bc) and this PR currently conflicts.
Quickest fix:
```bash
git fetch upstream main && git rebase upstream/main
rm uv.lock && uv lock
git add uv.lock && git rebase --continue
git push --force-with-lease
```
_Automated nudge — ignore if you're not ready to rebase. This comment is updated in place on future `uv.lock` bumps._
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] API: Return asset events for Dag Runs without a start date [airflow]
Posted by "rino0601 (via GitHub)" <gi...@apache.org>.
rino0601 commented on code in PR #71379:
URL: https://github.com/apache/airflow/pull/71379#discussion_r3776025628
##########
uv.lock:
##########
Review Comment:
Resolved by [c74cfcbae17aa4aa89e66afca8e92035f957aba5](https://github.com/apache/airflow/commit/c74cfcbae17aa4aa89e66afca8e92035f957aba5), which corrects the codegen hooks to use `--package` rather than `--project`.
After rebasing onto the latest `main`, I ran both datamodel-generation hooks explicitly. They now pass without creating a `uv.lock` diff. I then followed the rebase workflow from this comment and removed the now-obsolete lockfile revert. The PR has no `uv.lock` diff relative to `main` and is mergeable again.
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org