Nextflow recursively creates working directory in work folder

start_nextflow.nf (476 Bytes)

Hi,
I attended a nextflow training and I was trying to run a simple script in our HPC. what i found was that the working folder was being recursively copied in the work folder. i have attached the script as well as screenshots of the output. please help

Hi,
Nextflow creates a recursive directory structure inside the work folder for each process. This ensures that every process runs in an isolated and containerised environment. It also helps prevent unnecessary re-execution of the same process. If the inputs, outputs, and process script remain unchanged, Nextflow can reuse the previously cached results when you run the workflow with the -resume option.
Fury

Hi @Fury_Gaming , Thanks a lot! I did not realize that it keeps creating a recursive directory structure. :slightly_smiling_face:

Hi! Sorry for the lag, I just noticed this question. The recursive folder structure is not expected from normal Nextflow operation – the caching system should link to the original successful execution but would not explain what you’re seeing. Was this from the training you attended?

Our official training explains how Nextflow nromally operates, as seen here: Part 1: Hello World - training.nextflow.io