Hiya, I’m having some issues with `meltano add &lt...
# troubleshooting
r
Hiya, I’m having some issues with
meltano add <type> <name> --include-related
. We have a custom file bundle
files-google-analytics
set to the same namespace as the
tap-google-analytics
extractor (
tap_google_analytics
), which is defined in a custom `discovery.yml`:
Copy code
files:
name: files-google-analytics
  namespace: tap_google_analytics
  repo: <repo-url>
  pip_url: <pip-url>
When invoking
meltano add extractor tap-google-analytics --include-related
, the file bundle
files-google-analytics
is added twice, resulting in duplicated files. If I provde the
update
field with some arbitrary path (doesn’t even have to exist), then the command works as expected:
Copy code
files:
name: files-google-analytics
  namespace: tap_google_analytics
  update:
    <path>: true
  repo: <repo-url>
  pip_url: <pip-url>
After some reading, I found that update will default to an empty object (
{}
) if not given. Setting
update: {}
manually also causes the file bundle to add twice when adding
tap-google-analytics
with
--include-related
. This may indicate that there is some issue when a file bundle sharing a
namespace
with the plugin being added, is itself added via
--include-related
with
update
set as an empty object (manually or by default). ...or am I missing something important here?
d
If you drop
--include-related
, does it work as expected then? Matching file bundles are always installed, even when related plugins aren’t explicitly requested
Either way, this is a bug, Meltano should never try to add a plugin twice 🙂 Does the
meltano add
log output also list
files-google-analytics
twice?
I don’t think you’re missing something; I suggest filing an issue with exact steps to reproduce
r
If you drop 
--include-related
, does it work as expected then?
Yes -
--include-related
here installs the file bundle only once, as you say. We still need the
dbt
transformer plugin and file bundle however, which we get by using
--include-related
.
Does the 
meltano add
 log output also list 
files-google-analytics
 twice?
Yes - the following log output line appears twice:
Copy code
Adding related file bundle 'files-google-analytics' to your Meltano project...
Good to know I’m not going crazy. I’ll create an issue tomorrow morning. 🙂 Thanks for the info!