Trouble dividing fmriprep by task

I have a two session fMRI study that I’ve had to divide due to virtual memory maxing out (based on previous posts this seems to be a problem with singularity). The first task ran fine, but I can’t get the second task to run without a surface_recon error with the midthickness file not being found (full error pasted below). I’ve tried deleting the surface recon workflow from /work and double check that the file is present with appropriate permissions, but I get the error no matter what. The only thing that has worked so far is deleting the entire anat preproc wf and letting that run again. But this is time consuming and I’d rather not have to re-run it for all of my participants. Is this a possible bug?

“Missing file”:
[joseph.orr@login01 fmriprep$ ls -l /fdata/scratch/joseph.orr/t3/fmriprep/freesurfer/sub-1016/surf/lh.midthickness
lrwxrwxrwx 1 joseph.orr psyc 193 Jun 11 12:20 /fdata/scratch/joseph.orr/t3/fmriprep/freesurfer/sub-1016/surf/lh.midthickness -> …/…/…/…/…/…/…/scratch/joseph.orr/t3/fmriprep/work/fmriprep_wf/single_subject_1016_wf/anat_preproc_wf/surface_recon_wf/gifti_surface_wf/midthickness/mapflow/_midthickness1/lh.midthickness

Traceback (most recent call last):
File “/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/plugins/”, line 69, in run_node
result[‘result’] =
File “/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/”, line 472, in run
result = self._run_interface(execute=True)
File “/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/”, line 563, in _run_interface
return self._run_command(execute)
File “/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/”, line 643, in _run_command
result =
File “/usr/local/miniconda/lib/python3.7/site-packages/nipype/interfaces/base/”, line 377, in run
outputs = self.aggregate_outputs(runtime)
File “/usr/local/miniconda/lib/python3.7/site-packages/nipype/interfaces/base/”, line 478, in aggregate_outputs
raise error
File “/usr/local/miniconda/lib/python3.7/site-packages/nipype/interfaces/base/”, line 471, in aggregate_outputs
setattr(outputs, key, val)
File “/usr/local/miniconda/lib/python3.7/site-packages/nipype/interfaces/base/”, line 341, in validate
value = super(MultiObject, self).validate(object, name, newvalue)
File “/usr/local/miniconda/lib/python3.7/site-packages/traits/”, line 2336, in validate
return TraitListObject( self, object, name, value )
File “/usr/local/miniconda/lib/python3.7/site-packages/traits/”, line 2313, in init
raise excp
File “/usr/local/miniconda/lib/python3.7/site-packages/traits/”, line 2305, in init
value = [ validate( object, name, val ) for val in value ]
File “/usr/local/miniconda/lib/python3.7/site-packages/traits/”, line 2305, in
value = [ validate( object, name, val ) for val in value ]
File “/usr/local/miniconda/lib/python3.7/site-packages/nipype/interfaces/base/”, line 112, in validate
self.info_text, value))
traits.trait_errors.TraitError: The trait ‘graymid’ of a ReconAllOutputSpec instance is an existing file name, but the path ‘/fdata/scratch/joseph.orr/t3/fmriprep/freesurfer/sub-1016/surf/lh.midthickness’ does not exist.