Skip to content

air: explain root_path and default retries in convert-to-dabs - #7579

Merged
dimk0 merged 3 commits into
mainfrom
air-convert-to-dabs-root-path-retries
Nov 14, 2026
Merged

dimk0 merged 3 commits into
mainfrom
air-convert-to-dabs-root-path-retries

Conversation

@dimk0

@dimk0 dimk0 commented Nov 12, 2026 •

Copy link
Copy Markdown
Member

Changes

  • air convert-to-dabs: when code_source.root_path resolves to the bundle root, the error now says how to proceed: move the code into a subdirectory (for example ./src). For working-tree snapshots it also offers --output-dir with a dedicated parent directory. That option is not offered for git snapshots, because the archive runs from the bundle root and a parent directory would sit outside the repository.
  • When the input YAML does not set max_retries, the command prints a note after the next steps saying the generated job carries the air run default (max_retries: 3, retry_on_timeout: true).
  • Two code comments that the new error made stale are updated.

Why

Converting a workload that uses root_path: . (a common starter layout) fails with an error that only says to point root_path at a subdirectory, with no mention of --output-dir. After a successful conversion, databricks.yml contains max_retries: 3 and retry_on_timeout: true that are not in the source YAML, which reads as if the conversion invented them. The values are correct (they are what air run submits when the field is unset), so the emitted bundle is unchanged; this only makes the behavior visible.

Tests

  • TestConvertToDabsDotRootPathRejected now covers plain, include and git snapshots, and asserts the --output-dir hint is present for the first two and absent for git.
  • TestConvertToDabsDotRootPathWithParentOutputDir converts with the bundle rooted at the parent and checks the emitted artifact path and include.
  • TestConvertToDabsCommandPrintsRetryNoteOnlyWhenUnset runs the command and checks the note appears only when max_retries is unset; TestRetryDefaultsNote covers the helper.
  • go test ./cmd/air and go test ./acceptance -run TestAccept/air/convert-to-dabs pass on this branch. acceptance/air/convert-to-dabs/output.txt was edited by hand rather than with -update; the acceptance run confirms it matches.

This pull request and its description were written by Isaac.

dimk0 and others added 2 commits November 12, 2026 22:09
convert-to-dabs rejects a code_source root_path that resolves to the
bundle root without saying how to proceed, and writes the air run default
max_retries into the bundle without mentioning it. Point at the
subdirectory and --output-dir fixes in the error, and print a note when
the generated job carries the default retry settings.

Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
@github-actions github-actions Bot added the AIR Databricks AI Runtime CLI label Nov 12, 2026
@github-actions

github-actions Bot commented Nov 12, 2026 •

Copy link
Copy Markdown
Contributor

Commit: b58c19e17 | Workflow run

Regression test report

Selected 1 changed tests (limit=20, 0 not selected)

1 tests: regression=1 unreleased=0 coverage=0 failing=0
test branch main (db52460) latest (v1.26.0)
TestAccept/air/convert-to-dabs ✅ ❌ ❌
TestAccept/air/convert-to-dabs: branch ✅ | main (db52460) ❌ | latest (v1.26.0) ❌

main (db52460):

acceptance_test.go:1374: Diff:
        --- air/convert-to-dabs/output.txt
        +++ /tmp/TestAcceptairconvert-to-dabs2295338873/002/output.txt
        @@ -20,9 +20,6 @@
         job and its uploaded files with:
           [CLI] bundle destroy
         
        -Note: the YAML does not set max_retries, so the job uses the `air run` default
        -(max_retries: 3, retry_on_timeout: true). Edit databricks.yml to change it.
        -
         === emitted databricks.yml (code_source packaged as a tgz artifact; no code is copied)
         
         >>> cat databricks.yml
        @@ -114,9 +111,6 @@
         job and its uploaded files with:
           [CLI] bundle destroy
         
        -Note: the YAML does not set max_retries, so the job uses the `air run` default
        -(max_retries: 3, retry_on_timeout: true). Edit databricks.yml to change it.
        -
         === convert a B300 run using the current SDK
         
         >>> [CLI] air convert-to-dabs b300.yaml --output-dir generated-b300
        @@ -139,9 +133,6 @@
         job and its uploaded files with:
           [CLI] bundle destroy
         
        -Note: the YAML does not set max_retries, so the job uses the `air run` default
        -(max_retries: 3, retry_on_timeout: true). Edit databricks.yml to change it.
        -
         === the B300 bundle preserves its accelerator and AI Runtime version
         
         >>> cat generated-b300/databricks.yml
        @@ -207,9 +198,6 @@
         job and its uploaded files with:
           [CLI] bundle destroy
         
        -Note: the YAML does not set max_retries, so the job uses the `air run` default
        -(max_retries: 3, retry_on_timeout: true). Edit databricks.yml to change it.
        -
         >>> grep -E environment_version|base_environment databricks.yml
                     base_environment: workspace-base-environments/databricks_ai_v5
         
        
FAIL

latest (v1.26.0): same output as main (db52460)

A git snapshot is archived from the bundle root, so rooting the bundle at
a parent directory fails at deploy. Offer --output-dir only when there is
no git ref, derive retry_on_timeout in the retry note, fix comments the
new error made stale, and cover the plain-snapshot rejection, the parent
output-dir conversion, and note suppression at the command level.

Co-authored-by: Isaac <no-reply@databricks.com>
@eng-dev-ecosystem-bot

Copy link
Copy Markdown
Collaborator

✅ Integration test report

Commit: b58c19e

Run: 43322535022

Env 🔄​flaky 💚​RECOVERED ✅​pass 🙈​skip Time
💚​ aws linux-2core-8gb 1 270 16 14:41
🔄​ aws-windows-latest-4core-16gb 2 1 270 14 13:11
🔄​ azure linux-2core-8gb 1 1 268 16 12:52
🔄​ azure-windows-latest-4core-16gb 6 1 265 14 11:05
🔄​ gcp linux-2core-8gb 2 1 268 16 15:48
💚​ gcp-windows-latest-4core-16gb 1 272 14 8:41
10 interesting tests: 9 flaky, 1 RECOVERED
Test Name aws linux-2core-8gb aws-windows-latest-4core-16gb azure linux-2core-8gb azure-windows-latest-4core-16gb gcp linux-2core-8gb gcp-windows-latest-4core-16gb
💚​ TestAccept 💚​R 💚​R 💚​R 💚​R 💚​R 💚​R
🔄​ TestFsCpDirToDirWithOverwriteFlag ✅​p ✅​p ✅​p 🔄​f ✅​p ✅​p
🔄​ TestFsCpDirToDirWithOverwriteFlag/dbfs_to_dbfs ✅​p ✅​p ✅​p 🔄​f ✅​p ✅​p
🔄​ TestFsCpFileToFileFileNotOverwritten ✅​p ✅​p ✅​p 🔄​f ✅​p ✅​p
🔄​ TestFsCpFileToFileFileNotOverwritten/dbfs_to_uc-volumes ✅​p ✅​p ✅​p 🔄​f ✅​p ✅​p
🔄​ TestSyncIncrementalFileOverwritesFolder ✅​p 🔄​f ✅​p ✅​p ✅​p ✅​p
🔄​ TestSyncIncrementalFileSync ✅​p 🔄​f ✅​p 🔄​f 🔄​f ✅​p
🔄​ TestSyncIncrementalSyncFileToPythonNotebook ✅​p ✅​p ✅​p 🔄​f ✅​p ✅​p
🔄​ TestSyncNestedFolderDoesntFailOnNonEmptyDirectory ✅​p ✅​p ✅​p ✅​p 🔄​f ✅​p
🔄​ TestSyncNestedSpacePlusAndHashAreEscapedSync ✅​p ✅​p 🔄​f ✅​p ✅​p ✅​p
Top 30 slowest tests (at least 2 minutes):
duration env testname
4:43 gcp-windows-latest-4core-16gb TestFilerWorkspaceFilesExtensionsReadDir
4:10 aws linux-2core-8gb TestFilerWorkspaceFilesExtensionsStat
4:02 aws linux-2core-8gb TestAccept
3:58 gcp linux-2core-8gb TestAccept
3:54 aws-windows-latest-4core-16gb TestAccept
3:50 azure linux-2core-8gb TestAccept
3:40 azure-windows-latest-4core-16gb TestFilerWorkspaceFilesExtensionsReadDir
3:35 azure-windows-latest-4core-16gb TestAccept
3:34 aws-windows-latest-4core-16gb TestFilerWorkspaceFilesExtensionsStat
3:25 azure linux-2core-8gb TestFilerWorkspaceFilesExtensionsReadDir
3:21 gcp-windows-latest-4core-16gb TestAccept
3:18 azure linux-2core-8gb TestImportDirDoesNotOverwrite
3:02 gcp linux-2core-8gb TestFilerRecursiveDelete/workspace_files
3:00 aws-windows-latest-4core-16gb TestFilerWorkspaceFilesExtensionsRead
2:58 aws-windows-latest-4core-16gb TestImportDirWithOverwriteFlag
2:43 azure-windows-latest-4core-16gb TestFilerRecursiveDelete/workspace_files
2:42 aws linux-2core-8gb TestImportDir
2:32 gcp linux-2core-8gb TestFilerReadWrite/workspace_files
2:19 azure-windows-latest-4core-16gb TestFilerWorkspaceFilesExtensionsRead
2:18 gcp linux-2core-8gb TestLock
2:16 azure-windows-latest-4core-16gb TestExportDir
2:16 gcp linux-2core-8gb TestFilerWorkspaceFilesExtensionsDelete
2:16 aws-windows-latest-4core-16gb TestFilerWorkspaceFilesExtensionsReadDir
2:14 aws linux-2core-8gb TestFilerRecursiveDelete/workspace_files
2:11 azure-windows-latest-4core-16gb TestImportDirWithOverwriteFlag
2:10 aws linux-2core-8gb TestLock
2:08 azure linux-2core-8gb TestFilerReadWrite/workspace_files
2:04 gcp-windows-latest-4core-16gb TestFilerWorkspaceFilesExtensionsStat
2:00 aws-windows-latest-4core-16gb TestExportDir
2:00 aws linux-2core-8gb TestFilerWorkspaceFilesExtensionsRead

@dimk0
dimk0 marked this pull request as ready for review November 12, 2026 23:19
@dimk0
dimk0 requested review from a team as code owners November 12, 2026 23:19
@dimk0
dimk0 requested a review from anton-107 November 12, 2026 23:19
@dimk0
dimk0 added this pull request to the merge queue Nov 14, 2026
Merged via the queue into main with commit bdb37ab Nov 14, 2026
28 checks passed
@dimk0
dimk0 deleted the air-convert-to-dabs-root-path-retries branch November 14, 2026 00:26
@eng-dev-ecosystem-bot

Copy link
Copy Markdown
Collaborator

❌ Integration test report

Commit: bdb37ab

Run: 43534285614

Env 🔄​flaky 💚​RECOVERED ✅​pass 🙈​skip Time
💚​ aws linux-2core-8gb 12 1623 1316 208:04
🔄​ azure linux-2core-8gb 2 10 1603 1324 198:28
🔄​ gcp linux-2core-8gb 4 10 1608 1322 213:54
14 interesting tests: 9 RECOVERED, 5 flaky
Test Name aws linux-2core-8gb azure linux-2core-8gb gcp linux-2core-8gb
💚​ TestAccept 💚​R 💚​R 💚​R
🔄​ TestAccept/bundle/deployment/bind/catalog ✅​p ✅​p 🔄​f
🔄​ TestAccept/bundle/deployment/bind/catalog/DMS= ✅​p ✅​p 🔄​f
🔄​ TestAccept/bundle/resources/apps/lifecycle-started 💚​R 💚​R 🔄​f
💚​ TestAccept/bundle/resources/apps/lifecycle-started-omitted 💚​R 💚​R 💚​R
💚​ TestAccept/bundle/resources/apps/lifecycle-started-omitted/DMS=true 💚​R 💚​R 💚​R
💚​ TestAccept/bundle/resources/apps/lifecycle-started-toggle 💚​R 💚​R 💚​R
💚​ TestAccept/bundle/resources/apps/lifecycle-started-toggle/DMS= 💚​R 💚​R 💚​R
💚​ TestAccept/bundle/resources/apps/lifecycle-started-toggle/DMS=true 💚​R 💚​R 💚​R
🔄​ TestAccept/bundle/resources/apps/lifecycle-started/DMS= 💚​R 🔄​f 💚​R
🔄​ TestAccept/bundle/resources/apps/lifecycle-started/DMS=true 💚​R 🔄​f 🔄​f
💚​ TestAccept/bundle/resources/postgres_synced_tables/recreate 💚​R 💚​R 💚​R
💚​ TestAccept/bundle/resources/postgres_synced_tables/recreate/DMS= 💚​R 💚​R 💚​R
💚​ TestAccept/bundle/resources/postgres_synced_tables/recreate/DMS=true 💚​R 💚​R 💚​R
Top 50 slowest tests (at least 2 minutes):
duration env testname
10:10 aws linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started/DMS=true
9:09 azure linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started/DMS=true
8:52 aws linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started/DMS=
8:34 gcp linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started/DMS=
8:32 azure linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started/DMS=
7:30 gcp linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started/DMS=true
7:14 gcp linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started/DMS=
7:08 gcp linux-2core-8gb TestAccept/bundle/resources/clusters/deploy/local_ssd_count/DMS=true
7:06 gcp linux-2core-8gb TestAccept/bundle/invariant/no_drift/DMS=/INPUT_CONFIG=cluster_libraries.yml.tmpl/READPLAN=
7:04 aws linux-2core-8gb TestAccept/bundle/resources/clusters/deploy/data_security_mode/DMS=
6:31 aws linux-2core-8gb TestAccept/bundle/config-remote-sync/multiple_resources/DMS=
6:25 aws linux-2core-8gb TestAccept/bundle/config-remote-sync/multiple_resources/DMS=true
6:25 aws linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started/DMS=true
6:18 gcp linux-2core-8gb TestAccept/bundle/resources/clusters/deploy/local_ssd_count/DMS=
6:08 gcp linux-2core-8gb TestAccept/bundle/config-remote-sync/multiple_resources/DMS=true
6:05 gcp linux-2core-8gb TestAccept/bundle/config-remote-sync/multiple_resources/DMS=
6:03 gcp linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started/DMS=true
5:56 aws linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started/DMS=
5:46 azure linux-2core-8gb TestAccept/bundle/config-remote-sync/multiple_resources/DMS=
5:24 aws linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started-toggle/DMS=
5:20 azure linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started/DMS=
5:09 azure linux-2core-8gb TestAccept/bundle/config-remote-sync/multiple_resources/DMS=true
5:07 gcp linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started-toggle/DMS=true
5:04 azure linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started/DMS=true
5:01 azure linux-2core-8gb TestAccept/pipelines/run/refresh-flags
4:56 aws linux-2core-8gb TestAccept/pipelines/run/refresh-flags
4:52 gcp linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started-toggle/DMS=
4:42 aws linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started-toggle/DMS=true
4:26 gcp linux-2core-8gb TestAccept/pipelines/run/refresh-flags
4:09 aws linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started-toggle/DMS=
4:07 azure linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started-toggle/DMS=true
4:04 azure linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started-toggle/DMS=true
4:02 gcp linux-2core-8gb TestAccept/bundle/resources/apps/inline_config/DMS=
3:50 aws linux-2core-8gb TestAccept/bundle/invariant/no_drift/DMS=/INPUT_CONFIG=cluster_libraries.yml.tmpl/READPLAN=
3:49 azure linux-2core-8gb TestAccept/bundle/resources/clusters/lifecycle-started-toggle/DMS=
3:43 gcp linux-2core-8gb TestAccept/bundle/deploy/spark-jar-task/DMS=true
3:36 gcp linux-2core-8gb TestAccept/bundle/deploy/spark-jar-task/DMS=
3:36 aws linux-2core-8gb TestAccept/bundle/invariant/destroy_idempotent/DMS=/INPUT_CONFIG=cluster_libraries.yml.tmpl/READPLAN=1
3:33 aws linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started-omitted/DMS=true
3:31 aws linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started-toggle/DMS=true
3:27 aws linux-2core-8gb TestAccept/bundle/invariant/delete_idempotent/DMS=/INPUT_CONFIG=cluster_libraries.yml.tmpl/READPLAN=1
3:18 azure linux-2core-8gb TestAccept/bundle/resources/schemas/rename_then_change/DMS=true
3:12 gcp linux-2core-8gb TestAccept/bundle/invariant/destroy_idempotent/DMS=/INPUT_CONFIG=cluster_libraries.yml.tmpl/READPLAN=1
3:12 azure linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started-omitted/DMS=true
3:11 gcp linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started-toggle/DMS=true
3:09 aws linux-2core-8gb TestAccept/bundle/resources/apps/inline_config/DMS=true
3:09 aws linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started-omitted/DMS=
3:07 gcp linux-2core-8gb TestAccept/bundle/resources/apps/lifecycle-started-omitted/DMS=true
3:05 aws linux-2core-8gb TestAccept/bundle/deploy/spark-jar-task/DMS=true
3:02 aws linux-2core-8gb TestAccept/bundle/deploy/spark-jar-task/DMS=

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AIR Databricks AI Runtime CLI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants