marda-alliance / metadata_extractors_schema

Archive of MaRDA Metadata Extractors Schema. See datatractor/schema for the current repository.
https://github.com/datatractor/schema
MIT License
6 stars 1 forks source link

`Extractor` output specification #25

Closed PeterKraus closed 10 months ago

PeterKraus commented 1 year ago

As of #22, we have designed the schema to allow for usage types using cli (expecting to write a file to disk) and python (expecting to either return an object or write a file to disk). For Extractors where the output is a file, we provide the {{ output_path }} templating string. However, there is currently no way of specifying what the default is. This might be important for Extractors that do not allow customisation of the output path.

An option would be to add additional attribute, usage:output:, which would let the writer of the Extractor to describe this behaviour. For instance, if yadg is invoked without providing the optional outfile argument:

yadg extract {{ input_type }} {{ input_path }}

the output file will be the root of the {{ input_path }} with a .nc suffix. Currently, there is no way to describe this behaviour.

ml-evs commented 10 months ago

This was closed by #37