Hi experts! I'm new to meltano world and need some...
# getting-started
m
Hi experts! I'm new to meltano world and need some help with configuration validation. I have a requirement to compare two dates that come through the config.json file. My understanding is variable
config_jsonschema
is used to validate required fields and data types but couldn't figure out a way to compare values in the config file. Does anybody know if it is possible to validate schema this way?
r
Hi @mohammed_khan, I think this half answers your question: https://meltano.slack.com/archives/C01TCRBBJD7/p1654682119454859?thread_ts=1654675427.159589&cid=C01TCRBBJD7 What do you mean by "compare values in the config file"?
e
There’s nothing built-in in the SDK to help with other than overriding the tap’s
__init__
and running the comparison on
self.config
after calling
super().__init__
. I logged https://github.com/meltano/sdk/issues/1309 to track this.
m
Thanks, @edgar_ramirez_mondragon for the clarification, and appreciate logging the feature request👍 @Reuben (Matatika) by "compare values in the config file" I meant if the configuration file has different parameters that contain different values. For example, if we have
start_date
and
end_date
in our config file and we need to validate a condition of
start_date
should always be less than
end_date
and so on.