Skip to content

Fix unstage controls in command.run when using storeDir#6364

Merged
pditommaso merged 6 commits intomasterfrom
fix_unstage_controls_error_log_with_storedir
Sep 24, 2025
Merged

Fix unstage controls in command.run when using storeDir#6364
pditommaso merged 6 commits intomasterfrom
fix_unstage_controls_error_log_with_storedir

Conversation

@jorgee
Copy link
Contributor

@jorgee jorgee commented Aug 26, 2025

close #6311

unstage_controls was set in .command.run using the same condition as in unstage_outputs. It was producing an "are the same file" error message in .command.log when using the storeDir.
By default targetDir is set to the working directory, but when user defines a storeDir , the targetDir is set to storeDir. The condition shouldUnstageOutputs checks if targetDir is different from the working directory, and the fucntion to generate the unstage_outputs create the commands to copy the outputs to targetDir. However, control logs (.command.err, .command.out, .command.trace and .command.env) are always copied to the working directory using the function copyFileToWorkDir. For this reason, the same condition cannot be applied.

This PR changes the condition when the unstage_controls is set. A new method shouldUnstageControls is created to differentiate the condition when checking the outputs or controls. By default, it is set to false, the unstage controls will be applied if scratch is defined. There is a special case for Azure, where both controls and outputs are forced to be unstaged

Signed-off-by: jorgee <jorge.ejarque@seqera.io>
@netlify
Copy link

netlify bot commented Aug 26, 2025

Deploy Preview for nextflow-docs-staging canceled.

Name Link
🔨 Latest commit c0c13bc
🔍 Latest deploy log https://app.netlify.com/projects/nextflow-docs-staging/deploys/68d40a5b70f574000870dcd0

Signed-off-by: jorgee <jorge.ejarque@seqera.io>
@jorgee jorgee requested a review from bentsherman August 26, 2025 12:25
@jorgee jorgee requested a review from pditommaso September 22, 2025 10:59
@pditommaso pditommaso merged commit a5756da into master Sep 24, 2025
7 checks passed
@pditommaso pditommaso deleted the fix_unstage_controls_error_log_with_storedir branch September 24, 2025 15:17
emmarogge pushed a commit to dglazer/nextflow that referenced this pull request Sep 29, 2025
…6364)

Signed-off-by: jorgee <jorge.ejarque@seqera.io>
Signed-off-by: Paolo Di Tommaso <paolo.ditommaso@gmail.com>
Co-authored-by: Paolo Di Tommaso <paolo.ditommaso@gmail.com>
Signed-off-by: Emma Rogge <emmarogge@verily.health>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

storeDir : .command.out' are the same file

3 participants