我正在尝试在snakemake中运行一些picard工具指标集合。 A --dryrun工作正常,没有错误。当我实际运行snake文件时,由于我不理解的原因,我收到了MissingOutputException。
首先是我的规则
rule CollectAlignmentSummaryMetrics:
input:
"bam_input/final/{sample}/{sample}.ready.bam"
output:
"bam_input/final/{sample}/metrics/{reference}/alignment_summary.metrics"
params:
reference=config['reference']['file'],
memory="10240m"
run:
"java -Xmx{params.memory} -jar $HOME/software/picard/build/libs/picard.jar CollectAlignmentSummaryMetrics R={params.reference} I={input} O={output}"
现在错误。
snakemake --latency-wait 120 -s metrics.snake -p
Provided cores: 1
Rules claiming more threads will be scaled down.
Job counts:
count jobs
38 CollectAlignmentSummaryMetrics
1 all
39
rule CollectAlignmentSummaryMetrics:
input: bam_input/final/TB5173-T14/TB5173-T14.ready.bam
output: bam_input/final/TB5173-T14/metrics/GRCh37/alignment_summary.metrics
jobid: 7
wildcards: reference=GRCh37, sample=TB5173-T14
Error in job CollectAlignmentSummaryMetrics while creating output file bam_input/final/TB5173-T14/metrics/GRCh37/alignment_summary.metrics.
MissingOutputException in line 21 of/home/bwubb/projects/PD1WES/metrics.snake:
Missing files after 5 seconds:
bam_input/final/TB5173-T14/metrics/GRCh37/alignment_summary.metrics
This might be due to filesystem latency. If that is the case, consider to increase the wait time with --latency-wait.
Exiting because a job execution failed. Look above for error message
Will exit after finishing currently running jobs.
Exiting because a job execution failed. Look above for error message
--latency-wait完全被忽略。我甚至尝试将它提升到84600.如果我要运行预期的picard java命令,它执行没有问题。我已经制作了几条没有任何神秘问题的蛇形管道,所以这让我非常生气。感谢您的任何见解!
答案 0 :(得分:1)
感谢报道。
run
指令时,不会传播延迟等待的错误。我已在主分支中修复了这个问题。run
指令。在run
之后,Snakemake期望普通的Python代码。你只需提供一个字符串。这意味着Python将简单地初始化String然后退出。你真正想要的是使用shell
指令。见here。通过使用shell
指令,您当前的问题将得到修复,您不应该受到该错误的影响。也没有必要修改延迟等待。无论如何,延迟等待错误的修复将在Snakemake的下一个版本中发生。