Skip to content

Prevent Databricks task failure after successful repair - #76904

Merged
amoghrajesh merged 3 commits into
apache:mainfrom
astronomer:fix-databricks-inline-repair-success
Nov 12, 2026
Merged

amoghrajesh merged 3 commits into
apache:mainfrom
astronomer:fix-databricks-inline-repair-success

Conversation

@amoghrajesh

Copy link
Copy Markdown
Contributor

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

With repair_run=True, DatabricksRunNowOperator repairs a run that fails while the task is watching it, rerunning only the failed tasks. When that repair succeeded, the task still raised the original failure, so Airflow marked it failed even though the Databricks run finished successfully. A retry would then start the whole job again.

This affects only the non-deferrable mode. In deferrable mode the repaired run goes back to the triggerer, so that path already works.

The existing repair test only covered a run that stays failed after the repair, so this case had no test.

Testing

Ran against a real Databricks job (retries=0, repair_run=True), where the first run fails in its report task and the repair succeeds.

Before: the repair succeeds, but the task fails.

before_logs

After: the repair succeeds, and the task succeeds.

after_logs
  • 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.

@amoghrajesh
amoghrajesh enabled auto-merge (squash) November 12, 2026 04:04
@amoghrajesh
amoghrajesh merged commit 4263570 into apache:main Nov 12, 2026
76 checks passed
@amoghrajesh
amoghrajesh deleted the fix-databricks-inline-repair-success branch November 12, 2026 05:30
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.

2 participants