Direct engine: bundle deployment bind fails when experimental.immutable_folder is true
メンテナーはふだん 1 日以内に返信
評価
この issue はまだ評価されていません。
説明
Describe the issue
bundle deployment bind fails on the direct engine when experimental.immutable_folder: true is set. Bind calculates a plan on a configuration that does not hold resources.internal_immutable_snapshots.immutable. So every resource that references ${workspace.file_path} cannot resolve, and the plan fails. This blocks moving an existing resource into a bundle with bind.
Configuration
bundle:
name: example-bundle
engine: direct
experimental:
immutable_folder: true
resources:
jobs:
example_job:
name: example-job
tasks:
- task_key: main
environment_key: default
spark_python_task:
python_file: ./main.py
parameters:
- --input
- ${workspace.file_path}/input.json
environments:
- environment_key: default
spec:
environment_version: "5"
schemas:
example_schema:
catalog_name: main
name: example_schema
Steps to reproduce the behavior
- Create a job and a schema in the workspace, outside the bundle.
- Use a target that has never deployed, so the deployment state is empty.
- Run
databricks bundle deployment bind example_job <job id> --auto-approve. - Run
databricks bundle deploy --select jobs.example_job. This writes the snapshot resource into the state. Then run step 3 again.
Expected Behavior
Bind writes the job ID into the state. The next bundle plan shows the job as update, with its paths in the snapshot folder.
Actual Behavior
Step 3 fails for every resource key, a schema key included:
Error: invalid dependency "${resources.internal_immutable_snapshots.immutable.full_path}", no such node "resources.internal_immutable_snapshots.immutable"
After step 4, bind plans the snapshot as delete and fails:
Error: cannot plan resources.jobs.example_job: cannot resolve "${resources.internal_immutable_snapshots.immutable.full_path}": internal error: resources.internal_immutable_snapshots.immutable: action is "delete" missing new_state
Error: planning failed
Workaround: set immutable_folder: false for the bind only, then set it back to true. The next plan shows skip for a bound schema and update for a bound job, with snapshot paths.
A variable reference in experimental.immutable_folder is not a workaround. With ${var.immutable_folder}, the string parameter ${workspace.file_path}/input.json keeps the plain files/ path, but python_file moves to the snapshot path.
OS and CLI version
macOS, Databricks CLI v1.21.0. The bind flow in bundle/direct/bind.go is the same at v1.22.1, and v1.23.0 does not change that file.
Is this a regression?
Unknown.
Detailed plan
Not attached. Bind fails before it prints a plan.
Debug Logs
Not attached.
- 主要言語
- Go
- スター
- 424
- フォーク
- 261
- 平均マージ
- 1日 19時間
- マージ済み PR(30日)
- 218
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートあり
- コントリビューションガイドなし
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
databricks/cli のほかの issue
-
Apps commands only accept relative path to app.yml対応中かも @yuri-rod が 31 日前に担当しました。 オープンCLI
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
databricks/cli#6910 ·
メンテナーはふだん 1 日以内に返信
-
DABs
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
databricks/cli#6670 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
DABs
難易度 3/5 1〜2日 初心者へのやさしさ 65/100
databricks/cli#7359 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
DABs Enhancement
難易度 4/5 3〜5日 初心者へのやさしさ 55/100
databricks/cli#7256 ·
メンテナーはふだん 1 日以内に返信
-
bundle validate does not catch missing trigger.table_update.condition with multiple tables対応中かも @yuri-rod が 16 日前に担当しました。 オープンDABs Enhancement
難易度 3/5 1〜2日 初心者へのやさしさ 72/100
databricks/cli#7101 ·
メンテナーはふだん 1 日以内に返信
似ている issue
-
needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信
-
WriterSetTimes: the UTIME_NOW check fails when the kernel uses its coarse clock対応中かも @JakeChampion が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
JakeChampion/lang#14224 ·
メンテナーはふだん 1 日以内に返信
-
agent-butler-finding bug
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
jordansmall/spindrift#6391 ·
メンテナーはふだん 1 日以内に返信
-
common.Retry: data race on the shared response/err variables when the request context ends mid-attempt (v65.127.0, v65.128.0)対応中かも @kmohit00 が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
oracle/oci-go-sdk#676 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
SAP/crossplane-provider-btp#1175 ·
メンテナーはふだん 1 日以内に返信