I'm attempting to run `select --list --all <ext...
# announcements
a
I'm attempting to run
select --list --all <extractor>
but getting what looks like a JSON validation error
Any idea what might cause this?
Copy code
meltano select --list --all tap-packet-db
[2020-06-18 07:38:55,192|I|MainThread|root] Catalog not found, trying to run the tap with --discover.
[2020-06-18 07:41:56,009|E|MainThread|root] Schema discovery failed: invalid catalog output by --discovery.
Traceback (most recent call last):
  File "/home/adam/dev/pkt-pipeline/venv/meltano/lib/python3.8/site-packages/meltano/core/plugin/singer/tap.py", line 86, in run_discovery
    schema_valid = Draft4Validator.check_schema(json.load(catalog))
  File "/usr/lib/python3.8/json/__init__.py", line 293, in load
    return loads(fp.read(),
  File "/usr/lib/python3.8/json/__init__.py", line 357, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python3.8/json/decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python3.8/json/decoder.py", line 355, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
The output of
meltano config <extractor>
is valid JSON
meltano invoke <extractor> --discover
times out, which most likely means it is not pulling in the settings the way I expect it to. Are there any verbosity flags so I can see a log of what is happening?
Ah it looks like the generated config in
.meltano/run/<extractor>/tap.config.json
creates all properties as strings. So there is a boolean "true" instead of true. I think I can handle that in the tap source code. Is there some way to force casting of boolean or int config values?
d
@adam_roderick Yes, add a
kind: boolean
to your setting definition! See https://meltano.com/docs/contributor-guide.html#connector-settings
Ah it looks like the generated config in 
.meltano/run/<extractor>/tap.config.json
 creates all properties as strings.
You would have seen this in the
meltano config <extractor>
output as well, right?
@adam_roderick Did that work? 🙂
a
That's right
It worked
And using the settings "kind" property ensured it was a boolean
d
Perfect!