biosimspace icon indicating copy to clipboard operation
biosimspace copied to clipboard

Fix for issue #397

Open mb2055 opened this issue 10 months ago • 1 comments

Fix for issue #397 .

This fix ensures that each node input file has a unique identifier, preventing conflicts when multiple node instances are running simultaneously.

Fix for the output file is not ideal but I can't think of a better way to do it since we need to read the file_prefix from the args dictionary without knowing which of the arguments (if any) will be used to set the file_prefix when validate is called. The solution here is simply to assume that this will be set using an argument called file_prefix and that if this argument does not exist then the default name of output.yaml is used. It does not account for any situation in which the file_prefix is set using a value that is not the file_prefix argument.

Also adds a getNodeDirectory utility function that returns the current value of _node_dir .

mb2055 avatar Mar 21 '25 14:03 mb2055

Sorry for the delay with this, have been trying to think of a cleaner solution. Two options that I can think of:

  1. Allow the user to pass an ID or input file name to the run function.
  2. Run the process within a temporary workspace, allowing the user to specify a work_dir option as a kwarg to run. This would necessitate the use of absolute paths for inputs, though, but this could be documented.

lohedges avatar May 14 '25 14:05 lohedges