Skip to content

[3.0] Turn off serverless auto-optimization retries for Run File as Workflow - #2358

Merged
louis-johnston-db merged 1 commit into
release/3.xfrom
louis/3x-workflow-no-auto-retry
Nov 27, 2026
Merged

louis-johnston-db merged 1 commit into
release/3.xfrom
louis/3x-workflow-no-auto-retry

Conversation

@louis-johnston-db

Copy link
Copy Markdown
Contributor

Changes

Fixes #2357 for 3.x. 2.x (main) is unchanged.

When a "Run File as Workflow" run on serverless compute failed, Databricks retried it, possibly more than once, before the extension showed the failure. Ordinary task retries are already off (max_retries defaults to 0), but serverless auto-optimization is on by default on serverless, one-time runs included, and it retries failed tasks. The extension waits for the whole run to end, so the user saw no failure until every attempt had ended. The retries also cost compute, and a script that isn't safe to repeat ran more than once.

Now both one-time runs on serverless, a notebook's and a Python file's, set disable_auto_optimization: true on their task. Runs on a cluster are unchanged: auto-optimization is a serverless feature.

The trade-off: auto-optimization also retries failures that come from the compute rather than the script. Those now end the run at once too, as they do on a cluster, and the user runs it again.

There's no setting to turn the retries back on: a run from the editor is a development run, and the user can run it again.

Tests

  • WorkflowRunner.test.ts: the serverless Python file's payload and the serverless notebook's task carry disable_auto_optimization: true; the cluster payloads stay exactly as before.
  • Removing the flag from either serverless run fails its test, and adding it to a cluster notebook run fails that run's payload test (3 mutations, all caught).
  • yarn check and yarn test pass.
  • Not run against a real workspace.

This pull request and its description were written by Isaac.

…orkflow

A failed serverless run was retried by auto-optimization before the
extension showed the failure. Both serverless one-time runs, notebook and
Python file, now set disable_auto_optimization on their task.

Co-authored-by: Isaac <no-reply@databricks.com>
@louis-johnston-db
louis-johnston-db marked this pull request as ready for review November 27, 2026 16:03
@louis-johnston-db
louis-johnston-db merged commit 8f98398 into release/3.x Nov 27, 2026
12 checks passed
@louis-johnston-db
louis-johnston-db deleted the louis/3x-workflow-no-auto-retry branch November 27, 2026 16:12

This branch was successfully deployed

1 active deployment
test-trigger-is — 0d04d06f Deployed Nov 27, 2026 by louis-johnston-db via Trigger Tests #2630
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants