File tree 1 file changed +5
-1
lines changed
1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -335,7 +335,9 @@ def _cachecheck(self, item_transformed):
335
335
raise e
336
336
337
337
_item_transformed = self ._pre_transform (deepcopy (item_transformed )) # keep the original hashed
338
- if hashfile is not None :
338
+ if hashfile is None :
339
+ return _item_transformed
340
+ try :
339
341
# NOTE: Writing to a temporary directory and then using a nearly atomic rename operation
340
342
# to make the cache more robust to manual killing of parent process
341
343
# which may leave partially written cache files in an incomplete state
@@ -354,6 +356,8 @@ def _cachecheck(self, item_transformed):
354
356
shutil .move (temp_hash_file , hashfile )
355
357
except FileExistsError :
356
358
pass
359
+ except PermissionError : # project-monai/monai issue #3613
360
+ pass
357
361
return _item_transformed
358
362
359
363
def _transform (self , index : int ):
You can’t perform that action at this time.
0 commit comments