-
Notifications
You must be signed in to change notification settings - Fork 307
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
map contains_key() function #305
Comments
@TedBrookings This has come up a few times in the past. If it is something you'd like to see I'd encourage a PR against the spec |
I had the same issue when writing my WDL and, while I also think a
Notice though that |
There is actually a better way to imitate an
To imitate a |
Proposed signatures:
|
As mentioned in #596, I'd like to consider adding the following signature:
|
This is related to issue #174 and is a solution suggested in that thread.
It would empower terser more maintainable WDLs if we could check if a map has a certain key. In my use case the map would USUALLY be totally empty, but has a very large number of possible keys.
The use case is that the SV team is building a big pipeline that calls a lot of complex 3rd-party code. It is inevitable that a few difficult samples will cause some tasks to crash due to e.g. out of memory error. To enable pushing these difficult samples through the pipeline, we pass structures with optional overrides to the task, allowing us to bump up memory, increase disk size, etc. However this induces a scaling problem that the overrides for EVERY relevant task must be passed through sub-workflows, making our WDLs look mainly like a long list of optional overrides. The present alternative would be to create an enormous struct of overrides, which could at least hide some of the mess, but still presents an annoying maintenance problem: if someone renames tasks, adds them, removes them then the struct file needs to be changed too.
Draft implementation: https://github.com/openwdl/wdl/tree/305-contains-key
The text was updated successfully, but these errors were encountered: