Open effigies opened 2 years ago
This error is becoming increasingly annoying. Almost every single processing error is now primarily reported as a failure to populate an output spec. See, for yet another example, https://github.com/nipreps/fmriprep/issues/3006.
Summary
If an
output_spec
contains a traitFile(exists=True)
, and that output field is not passed as an input to another node, then the file will get cleaned up byremove_unnecessary_outputs
but still be set in the traits. When re-loading a node working directory, this then causes a trait failure:I can see a few solutions:
1) Purge
exists=True
fromoutput_spec
s. 2) Monkey-patchFile(exists=True)
in output specs to be simplyFile()
3) Catch the error and replace thestr
value withUndefined
4) If a file is going to be removed byremove_unnecessary_outputs
, then set its value toUndefined
before saving it.Platform details:
Execution environment
Choose one
nipreps/nibabies:22.1.0rc1