Skip to content

fix: Sort dependsOn to avoid diff - #4363

Closed
orslow wants to merge 1 commit into
databricks:mainfrom
orslow:fix/job-depends-on-diff
Closed

fix: Sort dependsOn to avoid diff#4363
orslow wants to merge 1 commit into
databricks:mainfrom
orslow:fix/job-depends-on-diff

Conversation

@orslow

Copy link
Copy Markdown

Changes

Sort depends_on array within each job task by task_key to ensure consistent ordering.

Why

The Databricks API returns depends_on sorted by task_key. When the local configuration has depends_on not sorted alphabetically, Terraform detects a diff even though there are no actual changes. This causes unnecessary "change" actions in bundle plan output.

Tests

Built the CLI locally and compared bundle plan output before and after the change, verified that jobs with depends_on in non-alphabetical order no longer show false diffs.

@github-actions

Copy link
Copy Markdown
Contributor

An authorized user can trigger integration tests manually by following the instructions below:

Trigger:
go/deco-tests-run/cli

Inputs:

  • PR number: 4363
  • Commit SHA: 49cc5634d875f5c720e52afdeca65b59c5e94612

Checks will be approved automatically on success.

@wannte

Copy link
Copy Markdown

I love it

@andrewnester

Copy link
Copy Markdown
Contributor

Thanks for raising the PR! For contributing to Databricks CLI we require users to sign CLA, if that's something you are willing to do, please drop an email with a request to dabs-feedback@databricks.com

@github-actions

Copy link
Copy Markdown
Contributor

This PR has not received an update in a while. If you want to keep this PR open, please leave a comment below or push a new commit and auto-close will be canceled.

@denik

Copy link
Copy Markdown
Contributor

FYI, there is fix for this for direct engine: #4990

@orsloworslow closed this May 11, 2026
Sign up for freeto 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.

4 participants

@orslow@wannte@andrewnester@denik