Skip to content

Added dagrun delete command to airflowctl - #68046

Merged
henry3260 merged 2 commits into
apache:mainfrom
justinpakzad:feature/delete-dagrun-ctl
Jul 2, 2026
Merged

henry3260 merged 2 commits into
apache:mainfrom
justinpakzad:feature/delete-dagrun-ctl

Conversation

@justinpakzad

Copy link
Copy Markdown
Contributor

Added dagrun delete command to airflowctl. Updated the DagRunOperations class with a new delete() method. Corresponding unit test was added. Updated the integration tests with the new command as well. I placed the delete after the xcom commands run in the test since they rely on a dag run.

Was generative AI tooling used to co-author this PR?
  • Yes (please specify the tool below)

  • Read the Pull Request Guidelines for more information. Note: commit author/co-author name and email in commits become permanently public when merged.
  • For fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
  • When adding dependency, check compliance with the ASF 3rd Party License Policy.
  • For significant user-facing changes create newsfragment: {pr_number}.significant.rst, in airflow-core/newsfragments. You can add this file in a follow-up commit after the PR is created so you know the PR number.

@potiuk potiuk left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Clean, well-scoped addition — delete() follows the existing get/list operation pattern, the generated help artifacts are properly regenerated (not hand-edited), and the unit test covers the 204 path. Correctly no newsfragment for airflow-ctl.

The CI failure was just main-branch drift (Static checks / end-of-file-fixer on generated/provider_dependencies.json.sha256sum, which isn't part of this PR). I've rebased the branch onto latest main to clear it — once CI re-runs green, this looks good to merge.


This review was drafted by an AI-assisted tool and confirmed by an Apache Airflow maintainer. The findings below are observations, not blockers; an Apache Airflow maintainer — a real person — will take the next look at the PR. If you think a finding is mis-applied, please reply on the PR and a maintainer will weigh in.

More on how Apache Airflow handles maintainer review: contributing-docs/05_pull_requests.rst.


Drafted-by: Claude Code (Opus 4.8); reviewed by @potiuk before posting

@justinpakzad
justinpakzad force-pushed the feature/delete-dagrun-ctl branch from 81db712 to 447e86d Compare June 5, 2026 11:36
@potiuk potiuk added the ready for maintainer review Set by triage when all criteria pass, or by the fork CI reconciler when fork CI is green. label Jun 8, 2026
@justinpakzad
justinpakzad requested a review from potiuk June 11, 2026 19:28
@justinpakzad

Copy link
Copy Markdown
Contributor Author

Would appreciate a review on this. Thanks.

@justinpakzad
justinpakzad force-pushed the feature/delete-dagrun-ctl branch from 447e86d to d84837b Compare June 17, 2026 21:03
@justinpakzad

Copy link
Copy Markdown
Contributor Author

Would appreciate a review on this.

@justinpakzad
justinpakzad force-pushed the feature/delete-dagrun-ctl branch 2 times, most recently from 4acaa2f to 296a5a4 Compare July 1, 2026 21:05
@justinpakzad
justinpakzad requested a review from henry3260 as a code owner July 1, 2026 21:05

@henry3260 henry3260 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks good, just one nit

@justinpakzad
justinpakzad force-pushed the feature/delete-dagrun-ctl branch from 296a5a4 to 641a66f Compare July 2, 2026 12:29
@henry3260

Copy link
Copy Markdown
Member

Thank justin :)

@henry3260
henry3260 merged commit 3570a75 into apache:main Jul 2, 2026
93 checks passed
@github-actions

github-actions Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Backport failed to create: airflow-ctl/v0-1-test. View the failure log Run details

Note: As of Merging PRs targeted for Airflow 3.X
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 Slack channel.

Status Branch Result
❌ airflow-ctl/v0-1-test Commit Link

You can attempt to backport this manually by running:

cherry_picker 3570a75 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:

cherry_picker --continue

If you don't have cherry-picker installed, see the installation guide.

@henry3260

Copy link
Copy Markdown
Member

backport in #69263

henry3260 pushed a commit to henry3260/airflow that referenced this pull request Jul 2, 2026
…ache#68046)

* Add dagrun delete command to airflowctl

* Adjust docstring to Dag

(cherry picked from commit 3570a75)

Co-authored-by: Justin Pakzad <[email protected]>
henry3260 added a commit that referenced this pull request Jul 2, 2026
…8046) (#69263)

* Add dagrun delete command to airflowctl

* Adjust docstring to Dag

(cherry picked from commit 3570a75)

Co-authored-by: Justin Pakzad <[email protected]>
shahar1 pushed a commit that referenced this pull request Nov 19, 2026
…8046) (#69263)

* Add dagrun delete command to airflowctl

* Adjust docstring to Dag

(cherry picked from commit 3570a75)

Co-authored-by: Justin Pakzad <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:airflow-ctl backport-to-airflow-ctl/v0-1-test kind:documentation ready for maintainer review Set by triage when all criteria pass, or by the fork CI reconciler when fork CI is green.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants