Specifying optional outputs #378
-
I'm running a dofile which outputs graphs if some conditions are met (in this instance, frequency in the smallest histogram bin is >5). This happens to never be the case in the dummy data (and might never be the case in the real data), and therefore the outputs are not generated. This throws an error when running through the yaml as it cannot find any outputs matching the patterns I've specified. It makes sense that it cannot find it as they're not generated, but I'd like for the file to run irrespective of this, and for the outputs only to be saved when they are generated (i.e, they are not disclosive) Essentially I thought this was a quicker way than manually checking the files and choosing to only release those meeting redaction criteria. Is there a way around this? The closest idea I have so far is just outputting a blank image with the same name, but that seems a bit awkward. Link to repo and branch, it's the last action that's problematic. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Outputting extra files is a sensible and simple workaround. And I don't know of anything else you could do. But as you're using very permissive globs to specify the outputs of the action ( |
Beta Was this translation helpful? Give feedback.
Outputting extra files is a sensible and simple workaround. And I don't know of anything else you could do. But as you're using very permissive globs to specify the outputs of the action (
plots_S1: output/plots/S1*
,plots_S2: output/plots/S2*
) you don't have to necessarily create a blank image. It could just be two blank text filesoutput/plots/S1.txt
andoutput/plots/S2.txt
. Or maybe include info on which graphs met the condition or not, so at least it doesn't feel like a workaround!