Allow passing a list of filenames eumetsat
readers
#68
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
RE: #67
Working on allowing
eumetsat
readers to be passed a list of filenames. Current implementation idea is to stop overriding the_merge_data
method fromChronFiles
, but instead add amerge
method to each of the file classes (AscatL1bEpsFile
, etc) that the defaultChronFiles._merge_data
method already leverages.This just needs two modifications:
The file reader classes'
read
methods need to be able to accept a list of strings and handle the merging before returning the data if necessary.A modification to somehow allow the
merge
method to know what product type is being merged (previously, the_merge_data
method on theChronFiles
subclass could get this from itsself
attributes). At the moment I've modifiedread_eps_l1b
andread_eps_l2
to accept areturn_ptype
bool that would add a"product_type"
field to the returned metadata if true. This way amerge
method can get the product type of a dataset it's passed by inspecting its metadata. I'm not in love with this approach though and would appreciate other ideas.Eventually this would of course be applicable to BUFR and NC readers as well