Skip to content

Commit e53fa06

Browse files
committed
add the possibly new code using portalocker in comment
1 parent 769dece commit e53fa06

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

nipype/algorithms/misc.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -894,6 +894,13 @@ def _run_interface(self, runtime):
894894
if self._have_lock:
895895
self._lock.release()
896896

897+
# Using nipype.external.portalocker this might be something like:
898+
# with pl.Lock(self.inputs.in_file, timeout=1) as fh:
899+
# if op.exists(fh):
900+
# formerdf = pd.read_csv(fh, index_col=0)
901+
# df = pd.concat([formerdf, df], ignore_index=True)
902+
# df.to_csv(fh)
903+
897904
return runtime
898905

899906
def _list_outputs(self):

0 commit comments

Comments
 (0)