[ENH]: Allow for matching on the full path #299
Merged
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.
This adds a parameter to
Storage.walk
, allowing users to specif whether thematches
applies just to the filename or to the full path, including the filename.The same keyword is added to the task and task input, to let this be set in the datasset.yaml.
Recent changes to the data published in the ecmwf container requires a new feature in pctasks' create-chunks: the ability to match on a full path rather than just a filename.
Data are being published under both the
We list both sets of data, but our stactools package can't handle the aifs data properly yet. So we want to filter it out.
Previously,
matches
could only target the filename being listed. We need that to filter to specific products. We want to extend that match expression to include the prefix, so that we can filter out theaifs
data.How Has This Been Tested?
In addition to the unit tests, some manual tests to mimic what will run on the server:
The first run (
match_full_path=True
) outputs files, and we can confirm that there aren't anyaifs
files:The second one (with
match_full_path
unset, equal toFalse
the old behavior) it doesn't match anything.Checklist:
Please delete options that are not relevant.