File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -389,17 +389,17 @@ def hash_exists(self, updatehash=False):
389389 return cached , self ._hashvalue , hashfile , self ._hashed_inputs
390390
391391 def run (self , updatehash = False ):
392- """Execute the node in its directory.
392+ """
393+ Execute the node in its directory.
393394
394395 Parameters
395396 ----------
396-
397397 updatehash: boolean
398398 When the hash stored in the output directory as a result of a previous run
399399 does not match that calculated for this execution, updatehash=True only
400400 updates the hash without re-running.
401- """
402401
402+ """
403403 if self .config is None :
404404 self .config = {}
405405 self .config = merge_dict (deepcopy (config ._sections ), self .config )
@@ -443,6 +443,10 @@ def run(self, updatehash=False):
443443 for outdatedhash in glob (op .join (self .output_dir (), '_0x*.json' )):
444444 os .remove (outdatedhash )
445445
446+ # _get_hashval needs to be called before running. When there is a valid (or seemingly
447+ # valid cache), the is_cached() member updates the hashval via _get_hashval.
448+ # However, if this node's folder doesn't exist or the result file is not found, then
449+ # the hashval needs to be generated here. See #3026 for a larger context.
446450 self ._get_hashval ()
447451 # Hashfile while running
448452 hashfile_unfinished = op .join (
You can’t perform that action at this time.
0 commit comments