Andy Carter
07/12/2023, 11:31 AMpip_url
(eg running postgres wise for some taps, and meltanolabs version for others due to a few fixes still pending), then the variant doesn't seem to get installed correctly in docker image build.
If I follow the guidance here, it works fine locally issuing meltano commands in the console : https://docs.meltano.com/guide/plugin-management#multiple-variants
When I build the docker image for deployment, it no longer works. Dockerfile in thread above. Crucial log line below, the command was meltano run tap-spreadsheets-anywhere target-postgres--meltanolabs
2023-07-12T11:28:05.967818Z [info ] * Required key is missing from config: [dbname] cmd_type=elb consumer=True name=target-postgres--meltanolabs producer=False stdio=stderr string_id=target-postgres--meltanolabs
it looks like the variant is reusing the env of the original plugin (as in simple inheritance, assuming the same pip_url). For instance, the wise
variant uses dbname
but the meltanolabs
variant uses database
.
Edit: Also if I meltano install --clean
locally, then a local run now fails as above.janis_puris
07/12/2023, 1:35 PMmeltano.yml
? Then I can try to reproduce the issue 🤷Andy Carter
07/12/2023, 1:37 PMAndy Carter
07/12/2023, 1:38 PMAndy Carter
07/12/2023, 1:39 PMmeltano, version 2.19.0
taylor
07/12/2023, 2:02 PMtaylor
07/12/2023, 2:04 PMinherit_from
line and it’ll install the different plugins, or you drop the variant / pip_url from the meltanolabs one and it’ll use the transferwise variant and also combine the config (which may not be ideal)Andy Carter
07/12/2023, 2:11 PMmeltanolabs
variant. I guess the docs assumes the configs are identical
https://docs.meltano.com/guide/plugin-management#multiple-variantsedgar_ramirez_mondragon
07/12/2023, 2:18 PMplugins/loaders
?Andy Carter
07/12/2023, 2:24 PMmeltano lock --all
results in
(empiric-elt-py3.10) andycarter@DESKTOP-D6ERPSP:~/vscode_projects/empiric_elt/empiric_meltano/plugins/loaders$ ls
target-jsonl--andyh1203.lock target-postgres--transferwise.lock
With this meltano.yml:
loaders:
- name: target-jsonl
variant: andyh1203
pip_url: target-jsonl
- name: target-postgres
variant: transferwise
pip_url: pipelinewise-target-postgres
config:
host: ${SYSTEM_DB_IP}
port: 5432
user: ${SYSTEM_DB_USER}
password: ${SYSTEM_DB_PASS}
default_target_schema: raw__${MELTANO_EXTRACTOR_NAMESPACE}
dbname: dwh
primary_key_required: false
- name: target-postgres--meltanolabs
inherit_from: target-postgres
variant: meltanolabs
pip_url: git+<https://github.com/MeltanoLabs/target-postgres.git>
config:
host: ${SYSTEM_DB_IP}
port: 5432
user: ${SYSTEM_DB_USER}
password: ${SYSTEM_DB_PASS}
default_target_schema: raw__${MELTANO_EXTRACTOR_NAMESPACE}
database: dwh
edgar_ramirez_mondragon
07/12/2023, 2:25 PMAndy Carter
07/12/2023, 2:27 PMmeltano install --clean
(empiric-elt-py3.10) andycarter@DESKTOP-D6ERPSP:~/vscode_projects/empiric_elt/empiric_meltano/plugins/loaders$ meltano install --clean
Installing 9 plugins...
Skipped installing loader 'target-postgres--meltanolabs'...
Installing extractor 'tap-google-analytics'...
Installing extractor 'tap-mailchimp'...
Installing extractor 'tap-instagram'...
Installing extractor 'tap-facebook-pages'...
Installing extractor 'tap-freshdesk'...
Installing extractor 'tap-spreadsheets-anywhere'...
Installing loader 'target-jsonl'...
Installing loader 'target-postgres'...
Installed loader 'target-jsonl'
Installed loader 'target-postgres'
Installed extractor 'tap-instagram'
Installed extractor 'tap-freshdesk'
Installed extractor 'tap-mailchimp'
Installed extractor 'tap-spreadsheets-anywhere'
Installed extractor 'tap-google-analytics'
Installed extractor 'tap-facebook-pages'
Installed 8/9 plugins
Skipped installing 1/9 plugins
Andy Carter
07/12/2023, 2:29 PMinherit_from
in the - name: target-postgres--meltanolabs
loader section, then (predictably) I get this: Loader 'target-postgres--meltanolabs' is not known to Meltano. Run meltano discover loader to explore available plugins.
florian_ernst
08/16/2023, 10:15 AMAndy Carter
08/16/2023, 11:01 AMflorian_ernst
08/16/2023, 12:53 PMuser
08/16/2023, 2:07 PMflorian_ernst
08/16/2023, 2:09 PMbotocore
version, which tries to import from collections import Mapping
when the import moved to collections.abc
).
I also did not manage to install it on 3.9 (Macbook M1) because it throws an error related to the cryptography
module. In the end, I’m simply using transferwise’s variant.user
08/16/2023, 3:05 PMActually, it seems my issue arise from Metlano’s variant which is not compatible with Python 3.10 (it uses an outdatedHi, which version of the tap are you using? MeltanoLabs/target-postgres is tested in Python 3.7-3.11.version, which tries to importbotocore
when the import moved tofrom collections import Mapping
).collections.abc
florian_ernst
08/16/2023, 3:38 PMtarget-postgres
but target-snowflake
. I’m using meltano and the target’s latest versions.
The issue comes from snowflake.connector
(which in turn calls an outdated botocore).florian_ernst
08/16/2023, 3:46 PM.meltano
, cleaning my virtual environment and reinstalling everything did the trick 🎉