input
directive of the rule are downloaded in the task.
A typical example is if the index files for biological data are not explicitly specified as a Snakefile input, the generated job for that rule will fail due to the missing index files.
delly_s
: The rule runs Delly to call SVs and outputs an unfiltered BCF file, followed by quality filtering using bcftools
filter to retain only the SV calls that pass certain filters. Finally, it indexes the BCF file.delly_merge
: This rule merges or concatenates BCF files containing SV calls from the delly_s rule, producing a single VCF file. The rule requires the index file to be available for each corresponding BAM file.bcf.csi
) are produced by the delly_s
rule but is not explicitly specified as input to the delly_merge
rule. Hence, the index files are not downloaded into the task that executes the delly_merge
rule.
To resolve the error, we need to add the index files as the output of the delly_s
rule and the input of the delly_merge
rule:
Path("inputs").glob(...)
call is not under any rule, it runs in all tasks. Because the fastqc
rule does not specify input_dir
as an input
, it will not be downloaded and the code will throw an error.
input
, output
, params
, and other declarations with static strings for the runtime workflow so any function calls within them will be replaced with pre-computed strings and the Snakefile will not attempt to read the files again.
Same example at runtime: