I try to run prokka using snakemake and rule all. In the latter I define all output folders which will be produced by prokka to write the results. Prokka requires a folder to be supplied as an output rather than a file.
A simplified version of what I have is here:
PATIENTID_ls = range(2)
rule all:
input:
expand("results_{subjectID}_outputfolder",subjectID=PATIENTID_ls),
rule prokka:
input:
"contigs/subject_{subjectID}/contigs.fasta",
output:
"results/subject_{subjectID}_outputfolder",
shell:
"prokka --cpus 1 --proteins ../GCF_000009645.1_ASM964v1_genomic.gbff --outdir {output} --prefix contigs500_anno9ref {input} "
When running:
$snakemake -p
Building DAG of jobs...
MissingInputException in line 2 of Snakefile:
Missing input files for rule all:
results_1_outputfolder
results_0_outputfolder
It works however when specifying the output explicitly:
snakemake -p results/subject_1_outputfolder
I am sure that is noob mistake on my side, but after hours of playing around I could not solve the issue. Help is highly appreciated. Thank you