TheRoddyWMS / Roddy

The Roddy workflow development and management system.
http://roddy-documentation.readthedocs.io
MIT License
8 stars 3 forks source link

allow optional tool inputs #298

Open GWarsow opened 6 years ago

GWarsow commented 6 years ago

for noControl workflows, it should be possible to provide e.g. null BamFiles (as controlBamFile). Up to now, a further tool would have to be defined for these cases. It would be better to have only one single tool definition with parameters taht can be set to be optional.

Otherwise, the following error would occur: The workflow setup is not correct. SEVERE: Not all input parameters were set for cnvSnpGeneration. Expected 3. Breaking loop and trying to go on.

vinjana commented 6 years ago

The code in de.dkfz.roddy.knowledge.methods.GenericMethod#assembleInputFilesAndParameters is responsible to for handling the input parameters. Instead of simply counting the expected number of input parameters -- what number to expect with one or multiple optional parameters? -- types should be checked individually. Optional parameters may be modelled as Java Optionals instead of null.