Fixing MissingPlusPrefixDeprecation for job_cluster_config in dbt_project.yml causes “Missing required field” errors

オープン
#1,301 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 6 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
50/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
静か
技術スタック
python
領域
cloud

調査の方向性

submission_method: job_cluster を指定した両方の dbt_project.yml 設定を再現し、MissingPlusPrefixDeprecation のパスと Databricks のジョブクラスター作成パスを比較します。plus が前置された job_cluster_config フィールドが adapter を通じてどのように渡されるかを追跡します。完了の条件は、Missing required field errors を発生させずに非推奨警告が解消されることです。

索引モデルが issue の本文から書いたものです。

説明

bug Stale
Describe the bug

Without + on job_cluster_config fields, dbt emits MissingPlusPrefixDeprecation warning(s).

After adding + to job_cluster_config fields to resolve the warning, Databricks job cluster creation fails with “Missing required field …” errors for all plus-prefixed fields.

Steps To Reproduce
  1. In dbt_project.yml, configure Databricks job submission using submission_method: job_cluster and a
    job_cluster_config like:

Version A (produces deprecation warning):

models:
  project_name:
    +submission_method: job_cluster
    +job_cluster_config:
      spark_version: "16.4.x-photon-scala2.13"
      node_type_id: "md-fleet.xlarge"
      autoscale: {"min_workers": 1, "max_workers": 8}
      data_security_mode: "USER_ISOLATION"
      policy_id: "{{ env_var('DBT_POLICY_ID') }}"
      aws_attributes:
        availability: "ON_DEMAND"
  1. Run dbt run -s model_name.
  2. Observe MissingPlusPrefixDeprecation warnings referencing job_cluster_config fields.
  3. Update dbt_project.yml to:

Version B (resolves deprecation warning, triggers runtime error):

models:
  project_name:
    +submission_method: job_cluster
    +job_cluster_config:
      +spark_version: "16.4.x-photon-scala2.13"
      +node_type_id: "md-fleet.xlarge"
      autoscale: {+"min_workers": 1, +"max_workers": 8}
      +data_security_mode: "USER_ISOLATION"
      +policy_id: "{{ env_var('DBT_POLICY_ID') }}"
      aws_attributes:
        +availability: "ON_DEMAND"
  1. Run dbt run -s model_name again.
  2. Observe the Databricks job cluster creation fails with errors like:
  • Missing required field 'spark_version'
  • Missing required field 'node_type_id'
  • Missing required field 'autoscale'
  • Missing required field 'data_security_mode'
  • etc. (applies to all fields that were plus-prefixed)
Expected behavior

Either:

  • job_cluster_config fields in dbt_project.yml do not require + prefixes (and do not trigger MissingPlusPrefixDeprecation), or
  • if + prefixes are required to satisfy deprecation behavior, the resulting configuration should allow successful Databricks job cluster creation without the "Missing required field..." errors.
Screenshots and log output
  • MissingPlusPrefixDeprecation warning screenshot/log excerpt:
Image
  • Error output showing “Missing required field …” after plus-prefixing:
Image
System information

The output of dbt --version:
Image

主要言語
Python
スター
391
フォーク
231
平均マージ
9日 7時間
マージ済み PR(30日)
29

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

databricks/dbt-databricks のほかの issue

databricks/dbt-databricks の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。