gunnar
07/28/2021, 6:02 PMmeltano | Running transformation...
dbt | Running with dbt=0.16.1
dbt | Checking ../.meltano/transformers/dbt/target/*
dbt | ERROR: not cleaning ../.meltano/transformers/dbt/target/* because it is protected
dbt | Checking dbt_modules/*
dbt | Cleaned dbt_modules/*
dbt | Checking logs/*
dbt | Cleaned logs/*
dbt | Finished cleaning all paths.
dbt | Running with dbt=0.16.1
dbt | Encountered an error:
dbt | Compilation Error
dbt | Env var required but not provided: 'MELTANO_LOAD_SCHEMA'
meltano | Transformation failed (2): Env var required but not provided: 'MELTANO_LOAD_SCHEMA'
meltano | ELT could not be completed: `dbt deps` failed
dan_ladd
07/28/2021, 6:47 PMIf any environment variables are not set, then dbt will raise a compilation error.
douwe_maan
07/28/2021, 7:13 PMgunnar
07/28/2021, 7:31 PMloaders:
- name: target-redshift
namespace: target_redshift
pip_url: target-redshift
executable: target-redshift
settings:
- name: redshift_host
- name: redshift_port
- name: redshift_database
- name: redshift_username
- name: redshift_password
- name: redshift_schema
- name: default_column_length
- name: target_s3.aws_access_key_id
- name: target_s3.aws_secret_access_key
- name: target_s3.bucket
- name: target_s3.key_prefix
- name: tap-shopify
variant: singer-io
pip_url: tap-shopify
transforms:
- name: tap-shopify
variant: meltano
pip_url: <https://gitlab.com/meltano/dbt-tap-shopify.git@config-version-2>
transformers:
- name: dbt
pip_url: dbt==0.16.1
files:
- name: dbt
pip_url: git+<https://gitlab.com/meltano/files-dbt.git>
douwe_maan
07/28/2021, 7:48 PMgunnar
07/28/2021, 8:33 PMtarget_redshift__shopify:
type: redshift
threads: 2
database: xxx
schema: xxx
host: xxx
user: xxx
password: xxx
port: xxx
gunnar
07/28/2021, 8:35 PMconfig:
send_anonymous_usage_stats: False
use_colors: True
meltano:
target: "{{ env_var('DBT_TARGET') }}"
outputs:
gunnar
07/28/2021, 8:46 PM'profiles (dbt).yml'
filedouwe_maan
07/28/2021, 11:20 PMgunnar
07/29/2021, 5:15 PMdouwe_maan
07/29/2021, 5:18 PMMELTANO_LOAD__TARGET_SCHEMA
, but it seems to use MELTANO_LOAD_SCHEMA
directly, which is specific to the “schema” setting. Can you find where it uses that env var? That’s what I’d suggest changinggunnar
07/29/2021, 5:18 PMgunnar
07/29/2021, 5:32 PMmodels:
my_meltano_project: null
tap_shopify:
vars:
schema: '{{ env_var(''DBT_SOURCE_SCHEMA'') }}'
I am using this Meltano provided transform (tap-shopify): https://gitlab.com/meltano/dbt-tap-shopify/-/tree/master/models
The above I assume is related to the schema specification here in the screenshot?
The models folder in /transform/models
is empty which has me thinking that Meltano generates it on each run?douwe_maan
07/29/2021, 5:33 PMschema: '{{ env_var(''DBT_SOURCE_SCHEMA'') }}'
definition in your dbt_project.yml
douwe_maan
07/29/2021, 5:34 PMgunnar
07/29/2021, 5:37 PMdouwe_maan
07/29/2021, 5:41 PMgunnar
07/29/2021, 5:44 PMmeltano add
command, does the upgrade need to be done in any specific way? Like changing the reference in meltano.yml file?
Or would simply running pip install --upgrade dbt
work?
transformers:
- name: dbt
pip_url: dbt==0.16.1
files:
- name: dbt
pip_url: git+<https://gitlab.com/meltano/files-dbt.git>
douwe_maan
07/29/2021, 5:44 PMpip_url
for dbt
in meltano.yml
, and then run meltano install transformer dbt
douwe_maan
07/29/2021, 5:45 PMgunnar
07/29/2021, 5:45 PMgunnar
07/29/2021, 6:18 PMgunnar
07/29/2021, 6:18 PMdbt | Running with dbt=0.19.1
dbt | Checking ../.meltano/transformers/dbt/target/*
dbt | ERROR: not cleaning ../.meltano/transformers/dbt/target/* because it is protected
dbt | Checking dbt_modules/*
dbt | Cleaned dbt_modules/*
dbt | Checking logs/*
dbt | Cleaned logs/*
dbt | Finished cleaning all paths.
dbt | Running with dbt=0.19.1
dbt | Installing <https://gitlab.com/meltano/dbt-tap-shopify.git@config-version-2>
dbt | Installed from revision config-version-2
dbt |
dbt | Installing <https://gitlab.com/meltano/dbt-tap-zendesk.git@config-version-2>
dbt | Installed from revision config-version-2
dbt |
dbt | Running with dbt=0.19.1
dbt | [WARNING]: Configuration paths exist in your dbt_project.yml file which do not apply to any resources.
dbt | There are 2 unused configuration paths:
dbt | - models.tap_zendesk.vars
dbt | - models.tap_shopify.vars
dbt |
dbt | Found 26 models, 15 tests, 0 snapshots, 0 analyses, 163 macros, 0 operations, 0 seed files, 0 sources, 0 exposures
dbt | The selector '' does not match any nodes and will be ignored
dbt | The selector 'tap_shopify__products' does not match any nodes and will be ignored
dbt | The selector 'my_meltano_project' does not match any nodes and will be ignored
dbt | WARNING: Nothing to do. Try checking your model configs and model specification args
meltano | Transformation complete!
douwe_maan
07/29/2021, 6:19 PMdbt deps
which looks at the packages in transform/packages.yml
. I think it installs it into transforms/dbt_modules
douwe_maan
07/29/2021, 6:21 PMtap-shopify
, it isn’t matching the transform
tap-shopify
when running meltano elt
with --transform run
gunnar
07/29/2021, 6:21 PMdouwe_maan
07/29/2021, 6:22 PMmodels
setting to $MELTANO_EXTRACT__MODEL_NAME
, and then adding model_name: tap_shopify
to your tap-shopify--products
definitiondouwe_maan
07/29/2021, 6:22 PMdouwe_maan
07/29/2021, 6:23 PMdouwe_maan
07/29/2021, 6:23 PMgunnar
07/29/2021, 7:34 PMmeltano | Extract & load skipped.
meltano | Running transformation...
dbt | Running with dbt=0.19.1
dbt | Checking ../.meltano/transformers/dbt/target/*
dbt | ERROR: not cleaning ../.meltano/transformers/dbt/target/* because it is protected
dbt | Checking dbt_modules/*
dbt | Cleaned dbt_modules/*
dbt | Checking logs/*
dbt | Cleaned logs/*
dbt | Finished cleaning all paths.
dbt | Running with dbt=0.19.1
dbt | Installing <https://gitlab.com/meltano/dbt-tap-shopify.git@config-version-2>
dbt | Installed from revision config-version-2
dbt |
dbt | Installing <https://gitlab.com/meltano/dbt-tap-zendesk.git@config-version-2>
dbt | Installed from revision config-version-2
dbt |
dbt | Running with dbt=0.19.1
dbt | [WARNING]: Configuration paths exist in your dbt_project.yml file which do not apply to any resources.
dbt | There are 2 unused configuration paths:
dbt | - models.tap_shopify.vars
dbt | - models.tap_zendesk.vars
dbt |
dbt | Found 26 models, 15 tests, 0 snapshots, 0 analyses, 163 macros, 0 operations, 0 seed files, 0 sources, 0 exposures
dbt | The selector 'tap-shopify' does not match any nodes and will be ignored
dbt | WARNING: Nothing to do. Try checking your model configs and model specification args
meltano | Transformation complete!
I appreciate all the help @douwe_maan, I think these last steps just need configuration/updated references (If I'm not mistaken). I'm new to DBT so I'm just figuring some of this out as I go hahadouwe_maan
07/29/2021, 7:34 PMgunnar
07/29/2021, 7:35 PMedward_ryan
07/29/2021, 7:38 PM