I am trying to write a tool where a record describes one of the inputs and the input itself is optional but if it is there then all parts of the input (all fields in the record) must be there. Here is a non-working example:
This example does not work because one.one and one.two are required arguments. What I intend to express is that one is optional but if it is there then one.one and one.two are required. If I make the fields optional (i.e. type string?) then each of them can be provided or not, independently. That is also not correct.
This sounds like a hole in the spec/implementation. As a developer I would interpret this code exactly as your use case. I would request you open an issue on the CWL website. Currently we have different websites for different versions: the best would likely be open it on the main one (https://github.com/common-workflow-language/common-workflow-language)